Commit 6044f3c4 authored by Hannes Reinecke's avatar Hannes Reinecke Committed by Damien Le Moal

ata: libata: move ata_dump_id() to dynamic debugging

Use ata_dev_dbg() to print out the information in ata_dump_id()
and remove the ata_msg_probe() conditional.
Signed-off-by: default avatarHannes Reinecke <hare@suse.de>
Signed-off-by: default avatarDamien Le Moal <damien.lemoal@opensource.wdc.com>
parent 6c952a0d
...@@ -1341,6 +1341,7 @@ static int ata_hpa_resize(struct ata_device *dev) ...@@ -1341,6 +1341,7 @@ static int ata_hpa_resize(struct ata_device *dev)
/** /**
* ata_dump_id - IDENTIFY DEVICE info debugging output * ata_dump_id - IDENTIFY DEVICE info debugging output
* @dev: device from which the information is fetched
* @id: IDENTIFY DEVICE page to dump * @id: IDENTIFY DEVICE page to dump
* *
* Dump selected 16-bit words from the given IDENTIFY DEVICE * Dump selected 16-bit words from the given IDENTIFY DEVICE
...@@ -1350,32 +1351,14 @@ static int ata_hpa_resize(struct ata_device *dev) ...@@ -1350,32 +1351,14 @@ static int ata_hpa_resize(struct ata_device *dev)
* caller. * caller.
*/ */
static inline void ata_dump_id(const u16 *id) static inline void ata_dump_id(struct ata_device *dev, const u16 *id)
{ {
DPRINTK("49==0x%04x " ata_dev_dbg(dev,
"53==0x%04x " "49==0x%04x 53==0x%04x 63==0x%04x 64==0x%04x 75==0x%04x\n"
"63==0x%04x " "80==0x%04x 81==0x%04x 82==0x%04x 83==0x%04x 84==0x%04x\n"
"64==0x%04x " "88==0x%04x 93==0x%04x\n",
"75==0x%04x \n", id[49], id[53], id[63], id[64], id[75], id[80],
id[49], id[81], id[82], id[83], id[84], id[88], id[93]);
id[53],
id[63],
id[64],
id[75]);
DPRINTK("80==0x%04x "
"81==0x%04x "
"82==0x%04x "
"83==0x%04x "
"84==0x%04x \n",
id[80],
id[81],
id[82],
id[83],
id[84]);
DPRINTK("88==0x%04x "
"93==0x%04x\n",
id[88],
id[93]);
} }
/** /**
...@@ -2632,8 +2615,7 @@ int ata_dev_configure(struct ata_device *dev) ...@@ -2632,8 +2615,7 @@ int ata_dev_configure(struct ata_device *dev)
/* find max transfer mode; for printk only */ /* find max transfer mode; for printk only */
xfer_mask = ata_id_xfermask(id); xfer_mask = ata_id_xfermask(id);
if (ata_msg_probe(ap)) ata_dump_id(dev, id);
ata_dump_id(id);
/* SCSI only uses 4-char revisions, dump full 8 chars from ATA */ /* SCSI only uses 4-char revisions, dump full 8 chars from ATA */
ata_id_c_string(dev->id, fwrevbuf, ATA_ID_FW_REV, ata_id_c_string(dev->id, fwrevbuf, ATA_ID_FW_REV,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment