]> Gentwo Git Trees - linux/.git/commitdiff
ide: remove redundant hwif->present check from ide_register_hw()
authorBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Sat, 2 Feb 2008 18:56:38 +0000 (19:56 +0100)
committerBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Sat, 2 Feb 2008 18:56:38 +0000 (19:56 +0100)
We check earlier for hwif->present and call ide_unregister() if necessary
(after ide_unregister() hwif->present will be always cleared).

Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
drivers/ide/ide.c

index eeb0e6a77f5b4c317a28d6b385a46422b9205641..a71591ab0c5f9cd152351993606a0dd3d1e8886b 100644 (file)
@@ -720,8 +720,6 @@ int ide_register_hw(hw_regs_t *hw, void (*quirkproc)(ide_drive_t *),
                ide_init_port_data(hwif, index);
                init_hwif_default(hwif, index);
        }
-       if (hwif->present)
-               return -1;
 
        ide_init_port_hw(hwif, hw);
        hwif->quirkproc = quirkproc;