From d6276b5f5cc7508124de291f3ed59c6945c17ae7 Mon Sep 17 00:00:00 2001 From: Bartlomiej Zolnierkiewicz Date: Wed, 23 Jul 2008 19:55:56 +0200 Subject: ide: add 'config' field to hw_regs_t 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 --- drivers/ide/ide-probe.c | 4 +--- drivers/ide/ide.c | 1 + 2 files changed, 2 insertions(+), 3 deletions(-) (limited to 'drivers/ide') diff --git a/drivers/ide/ide-probe.c b/drivers/ide/ide-probe.c index 21cea45e9f21..3cc8ade2cc4f 100644 --- a/drivers/ide/ide-probe.c +++ b/drivers/ide/ide-probe.c @@ -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; } diff --git a/drivers/ide/ide.c b/drivers/ide/ide.c index 434dd02a4bdc..961f31c648c9 100644 --- a/drivers/ide/ide.c +++ b/drivers/ide/ide.c @@ -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; } /* -- cgit v1.2.1