From 51713d359ae274fa4dd4b199ba3a6b0c21ef99e0 Mon Sep 17 00:00:00 2001 From: Tejun Heo Date: Tue, 11 Apr 2006 22:26:29 +0900 Subject: [PATCH] [PATCH] libata: cosmetic update to ata_bus_probe() Move ata_set_mode() failure handling outside of ap->ops->set_mode if clause such that it can handle ap->ops->set_mode failures after it's updated. Signed-off-by: Tejun Heo Signed-off-by: Jeff Garzik --- drivers/scsi/libata-core.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/scsi/libata-core.c b/drivers/scsi/libata-core.c index 9194e4a6a55a..588578dc6caf 100644 --- a/drivers/scsi/libata-core.c +++ b/drivers/scsi/libata-core.c @@ -1441,12 +1441,12 @@ static int ata_bus_probe(struct ata_port *ap) break; } rc = 0; - } else { + } else rc = ata_set_mode(ap, &dev); - if (rc) { - down_xfermask = 1; - goto fail; - } + + if (rc) { + down_xfermask = 1; + goto fail; } for (i = 0; i < ATA_MAX_DEVICES; i++) -- 2.20.1