aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide/ide-probe.c
diff options
context:
space:
mode:
authorBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2008-02-02 13:56:43 -0500
committerBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2008-02-02 13:56:43 -0500
commit327617e1da15c3f04bfc50018b0319bd40849022 (patch)
treeadd2cecd9b29ecf4c592a2b0fe7a0496ee68663f /drivers/ide/ide-probe.c
parenteafd88a3b5d86ba2dd515d430b57a01349d0867b (diff)
ide: move hwif->present check out from ide_proc_register_port()
Move hwif->present check out from ide_proc_register_port() to ide_device_add_all(). There should be no functionality changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/ide-probe.c')
-rw-r--r--drivers/ide/ide-probe.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/drivers/ide/ide-probe.c b/drivers/ide/ide-probe.c
index abb695aa021d..1ef293757043 100644
--- a/drivers/ide/ide-probe.c
+++ b/drivers/ide/ide-probe.c
@@ -1448,8 +1448,13 @@ int ide_device_add_all(u8 *idx, const struct ide_port_info *d)
1448 } 1448 }
1449 1449
1450 for (i = 0; i < MAX_HWIFS; i++) { 1450 for (i = 0; i < MAX_HWIFS; i++) {
1451 if (idx[i] != 0xff) 1451 if (idx[i] == 0xff)
1452 ide_proc_register_port(&ide_hwifs[idx[i]]); 1452 continue;
1453
1454 hwif = &ide_hwifs[idx[i]];
1455
1456 if (hwif->present)
1457 ide_proc_register_port(hwif);
1453 } 1458 }
1454 1459
1455 return rc; 1460 return rc;