diff options
author | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2008-01-26 14:13:06 -0500 |
---|---|---|
committer | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2008-01-26 14:13:06 -0500 |
commit | cbb010c180294a5242a7681555c28737d9dd26ab (patch) | |
tree | 073883d1dc672bb38021563ca0d9cd762cd5abf2 /drivers/ide/legacy/gayle.c | |
parent | 57c802e84f9c759c3d1794a9dbe81bc10444df62 (diff) |
ide: drop 'initializing' argument from ide_register_hw()
* Rename init_hwif_data() to ide_init_port_data() and export it.
* For all users of ide_register_hw() with 'initializing' argument set
hwif->present and hwif->hold are always zero so convert these host
drivers to use ide_find_port()+ide_init_port_data()+ide_init_port_hw()
instead (also no need for init_hwif_default() call since the setup
done by it gets over-ridden by ide_init_port_hw() call).
* Drop 'initializing' argument from ide_register_hw().
Cc: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Roman Zippel <zippel@linux-m68k.org>
Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/legacy/gayle.c')
-rw-r--r-- | drivers/ide/legacy/gayle.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/drivers/ide/legacy/gayle.c b/drivers/ide/legacy/gayle.c index 53331ee1e957..705d0b8a3f5d 100644 --- a/drivers/ide/legacy/gayle.c +++ b/drivers/ide/legacy/gayle.c | |||
@@ -133,7 +133,6 @@ found: | |||
133 | ide_ack_intr_t *ack_intr; | 133 | ide_ack_intr_t *ack_intr; |
134 | hw_regs_t hw; | 134 | hw_regs_t hw; |
135 | ide_hwif_t *hwif; | 135 | ide_hwif_t *hwif; |
136 | int index; | ||
137 | unsigned long phys_base, res_start, res_n; | 136 | unsigned long phys_base, res_start, res_n; |
138 | 137 | ||
139 | if (a4000) { | 138 | if (a4000) { |
@@ -165,8 +164,13 @@ found: | |||
165 | // &gayle_iops, | 164 | // &gayle_iops, |
166 | IRQ_AMIGA_PORTS); | 165 | IRQ_AMIGA_PORTS); |
167 | 166 | ||
168 | index = ide_register_hw(&hw, NULL, 1, &hwif); | 167 | hwif = ide_find_port(base); |
169 | if (index != -1) { | 168 | if (hwif) { |
169 | u8 index = hwif->index; | ||
170 | |||
171 | ide_init_port_data(hwif, index); | ||
172 | ide_init_port_hw(hwif, &hw); | ||
173 | |||
170 | hwif->mmio = 1; | 174 | hwif->mmio = 1; |
171 | switch (i) { | 175 | switch (i) { |
172 | case 0: | 176 | case 0: |