Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2244e850 authored by Bartlomiej Zolnierkiewicz's avatar Bartlomiej Zolnierkiewicz
Browse files

ide: remove redundant hwif->present check from ide_register_hw()



We check earlier for hwif->present and call ide_unregister() if necessary
(after ide_unregister() hwif->present will be always cleared).

Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
parent 1bee4d1d
Loading
Loading
Loading
Loading
+0 −2
Original line number Original line Diff line number Diff line
@@ -720,8 +720,6 @@ int ide_register_hw(hw_regs_t *hw, void (*quirkproc)(ide_drive_t *),
		ide_init_port_data(hwif, index);
		ide_init_port_data(hwif, index);
		init_hwif_default(hwif, index);
		init_hwif_default(hwif, index);
	}
	}
	if (hwif->present)
		return -1;


	ide_init_port_hw(hwif, hw);
	ide_init_port_hw(hwif, hw);
	hwif->quirkproc = quirkproc;
	hwif->quirkproc = quirkproc;