From 1f2cf8b0014fdfa3141449b508aca25e78c078a7 Mon Sep 17 00:00:00 2001 From: Bartlomiej Zolnierkiewicz Date: Sat, 2 Feb 2008 19:56:40 +0100 Subject: ide: add ->port_init_devs method to ide_hwif_t * Add ->port_init_devs method to ide_hwif_t for a host specific initialization of devices on a port. Call the new method from ide_port_init_devices(). * Convert ht6560b, qd65xx and opti621 host drivers to use the new ->port_init_devs method. There should be no functionality changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz --- drivers/ide/pci/opti621.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'drivers/ide/pci/opti621.c') diff --git a/drivers/ide/pci/opti621.c b/drivers/ide/pci/opti621.c index 1e532c9a97f..46e8748f507 100644 --- a/drivers/ide/pci/opti621.c +++ b/drivers/ide/pci/opti621.c @@ -315,14 +315,18 @@ static void opti621_set_pio_mode(ide_drive_t *drive, const u8 pio) spin_unlock_irqrestore(&opti621_lock, flags); } +static void __devinit opti621_port_init_devs(ide_hwif_t *hwif) +{ + hwif->drives[0].drive_data = PIO_DONT_KNOW; + hwif->drives[1].drive_data = PIO_DONT_KNOW; +} + /* * init_hwif_opti621() is called once for each hwif found at boot. */ static void __devinit init_hwif_opti621 (ide_hwif_t *hwif) { - hwif->drives[0].drive_data = PIO_DONT_KNOW; - hwif->drives[1].drive_data = PIO_DONT_KNOW; - + hwif->port_init_devs = opti621_port_init_devs; hwif->set_pio_mode = &opti621_set_pio_mode; } -- cgit v1.2.3