Name

ata_dev_identify — obtain IDENTIFY x DEVICE page

Synopsis

void ata_dev_identify (struct ata_port * ap, unsigned int device);

Arguments

ap

port on which device we wish to probe resides

device

device bus address, starting at zero

Description

Following bus reset, we issue the IDENTIFY [PACKET] DEVICE command, and read back the 512-byte device information page. The device information page is fed to us via the standard PIO-IN protocol, but we hand-code it here. (TODO: investigate using standard PIO-IN paths)

After reading the device information page, we use several bits of information from it to initialize data structures that will be used during the lifetime of the ata_device. Other data from the info page is used to disqualify certain older ATA devices we do not wish to support.

LOCKING

Inherited from caller. Some functions called by this function obtain the host_set lock.