---
name: "ata_bus_reset"
section: "9"
platform: "linux"
package: "linux-manual-2.6.18"
version: "2.6.18.dfsg.1-26etch2"
release: "Debian 4.0 (Etch)"
platforms: ["linux"]
url: "https://new.carta.tech/ata_bus_reset"
---

# ata\_bus\_reset(9)

reset host port and associated ATA channel

## NAME

ata\_bus\_reset - reset host port and associated ATA channel

## SYNOPSIS

**void ata\_bus\_reset(struct ata\_port \*** *ap***);**

## ARGUMENTS

*ap*

port to reset

## DESCRIPTION

This is typically the first time we actually start issuing commands to the ATA channel. We wait for BSY to clear, then issue EXECUTE DEVICE DIAGNOSTIC command, polling for its result. Determine what devices, if any, are on the channel by looking at the device 0/1 error register. Look at the signature stored in each device's taskfile registers, to determine if the device is ATA or ATAPI.

## LOCKING

PCI/etc. bus probe sem. Obtains host\_set lock.

## SIDE EFFECTS

Sets ATA\_FLAG\_DISABLED if bus reset fails.

## AUTHOR

**Jeff Garzik**

-

  Author.

## COPYRIGHT
