From e4fac92ae744cd5d5c3c1774825788e6b91a5965 Mon Sep 17 00:00:00 2001 From: Tejun Heo Date: Mon, 15 May 2006 20:57:25 +0900 Subject: [PATCH] [PATCH] ahci: hardreset classification fix AHCI calls ata_dev_classify() even when no device is attached which results in false class code. Fix it. Signed-off-by: Tejun Heo --- drivers/scsi/ahci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/scsi/ahci.c b/drivers/scsi/ahci.c index d23f00230a76..c33255404ee5 100644 --- a/drivers/scsi/ahci.c +++ b/drivers/scsi/ahci.c @@ -670,7 +670,7 @@ static int ahci_hardreset(struct ata_port *ap, unsigned int *class) rc = sata_std_hardreset(ap, class); ahci_start_engine(ap); - if (rc == 0) + if (rc == 0 && sata_dev_present(ap)) *class = ahci_dev_classify(ap); if (*class == ATA_DEV_UNKNOWN) *class = ATA_DEV_NONE; -- 2.39.5