]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
ide: add 'config' field to hw_regs_t
authorBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Wed, 23 Jul 2008 17:55:56 +0000 (19:55 +0200)
committerBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Wed, 23 Jul 2008 17:55:56 +0000 (19:55 +0200)
Add 'config' field to hw_regs_t and use it to set hwif->config_data in
ide_init_port_hw(), then convert ide_legacy_init_one() to use hw->config.

There should be no functional changes caused by this patch.

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

index 21cea45e9f21e9250bf1941ddfd50ed377f511a8..3cc8ade2cc4fe7a80eb65a3060d96e82a9d98e44 100644 (file)
@@ -1689,14 +1689,12 @@ static void ide_legacy_init_one(u8 *idx, hw_regs_t **hws, hw_regs_t *hw,
        ide_std_init_ports(hw, base, ctl);
        hw->irq = irq;
        hw->chipset = d->chipset;
+       hw->config = config;
 
        hwif = ide_find_port_slot(d);
        if (hwif) {
                hwif->chipset = hw->chipset;
 
-               if (config)
-                       hwif->config_data = config;
-
                hws[port_no] = hw;
                idx[port_no] = hwif->index;
        }
index 434dd02a4bdce1f719ebec2c5bfec6f597d8a85e..961f31c648c99e008179fcb7e7299818bc6da7db 100644 (file)
@@ -286,6 +286,7 @@ void ide_init_port_hw(ide_hwif_t *hwif, hw_regs_t *hw)
        hwif->dev = hw->dev;
        hwif->gendev.parent = hw->parent ? hw->parent : hw->dev;
        hwif->ack_intr = hw->ack_intr;
+       hwif->config_data = hw->config;
 }
 
 /*
index 260e871ae880aef320595cf79f15fdca4e368fb9..e340218b2a5f286a94acea78b4bcdcd3b2dd3882 100644 (file)
@@ -178,6 +178,7 @@ typedef struct hw_regs_s {
        ide_ack_intr_t  *ack_intr;              /* acknowledge interrupt */
        hwif_chipset_t  chipset;
        struct device   *dev, *parent;
+       unsigned long   config;
 } hw_regs_t;
 
 void ide_init_port_data(struct hwif_s *, unsigned int);