---
name: "mpt_diag_reset"
section: "9"
platform: "linux"
package: "linux-manual-3.16"
version: "3.16.56-1+deb8u1"
release: "Debian 8 (Jessie)"
platforms: ["linux"]
url: "https://new.carta.tech/mpt_diag_reset"
---

# mpt\_diag\_reset(9)

Perform hard reset of the adapter.

## NAME

mpt\_diag\_reset - Perform hard reset of the adapter.

## SYNOPSIS

**int mpt\_diag\_reset(MPT\_ADAPTER \*** *ioc***, int** *ignore***, int** *sleepFlag***);**

## ARGUMENTS

*ioc*

Pointer to MPT\_ADAPTER structure

*ignore*

Set if to honor and clear to ignore the reset history bit

*sleepFlag*

CAN\_SLEEP if called in a non-interrupt thread, else set to NO\_SLEEP (use mdelay instead)

## DESCRIPTION

This routine places the adapter in diagnostic mode via the WriteSequence register and then performs a hard reset of adapter via the Diagnostic register. Adapter should be in ready state upon successful completion.

## RETURNS

1 hard reset successful 0 no reset performed because reset history bit set -2 enabling diagnostic mode failed -3 diagnostic reset failed

## COPYRIGHT
