ata_dev_read_id(9)

ata_dev_read_id9

Read id data from the specified device

Usage

int ata_dev_read_id(struct ata_device * dev, unsigned int * p_class, unsigned int flags, u16 * id);

Arguments

dev

target device

p_class

pointer to class of the target device (may be changed)

flags

ATA_READID_* flags

id

buffer to read IDENTIFY data into

Overview

Read ID data from the specified device. ATA_CMD_ID_ATA is performed on ATA devices and ATA_CMD_ID_ATAPI on ATAPI devices. This function also issues ATA_CMD_INIT_DEV_PARAMS for pre-ATA4 drives.

FIXME: ATA_CMD_ID_ATA is optional for early drives and right now we abort if we hit that case.

LOCKING: Kernel thread context (may sleep)

Return

0 on success, -errno otherwise.

Releases

6 releases since Debian 4.0 (Etch); the text changed 5 times.

  1. 4.0
  2. 5.0
  3. 6.0
  4. 7
  5. 8
  6. 9

Author

Jeff Garzik

Author.

From linux-manual-4.9 4.9.228-1 in Debian 9 (Stretch). Parsed by carta from the page's man source.