diff options
Diffstat (limited to 'drivers/ide/q40ide.c')
-rw-r--r-- | drivers/ide/q40ide.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/drivers/ide/q40ide.c b/drivers/ide/q40ide.c index c79346679244..ab49a97023d9 100644 --- a/drivers/ide/q40ide.c +++ b/drivers/ide/q40ide.c | |||
@@ -51,11 +51,11 @@ static int q40ide_default_irq(unsigned long base) | |||
51 | /* | 51 | /* |
52 | * Addresses are pretranslated for Q40 ISA access. | 52 | * Addresses are pretranslated for Q40 ISA access. |
53 | */ | 53 | */ |
54 | static void q40_ide_setup_ports(hw_regs_t *hw, unsigned long base, | 54 | static void q40_ide_setup_ports(struct ide_hw *hw, unsigned long base, |
55 | ide_ack_intr_t *ack_intr, | 55 | ide_ack_intr_t *ack_intr, |
56 | int irq) | 56 | int irq) |
57 | { | 57 | { |
58 | memset(hw, 0, sizeof(hw_regs_t)); | 58 | memset(hw, 0, sizeof(*hw)); |
59 | /* BIG FAT WARNING: | 59 | /* BIG FAT WARNING: |
60 | assumption: only DATA port is ever used in 16 bit mode */ | 60 | assumption: only DATA port is ever used in 16 bit mode */ |
61 | hw->io_ports.data_addr = Q40_ISA_IO_W(base); | 61 | hw->io_ports.data_addr = Q40_ISA_IO_W(base); |
@@ -70,8 +70,6 @@ static void q40_ide_setup_ports(hw_regs_t *hw, unsigned long base, | |||
70 | 70 | ||
71 | hw->irq = irq; | 71 | hw->irq = irq; |
72 | hw->ack_intr = ack_intr; | 72 | hw->ack_intr = ack_intr; |
73 | |||
74 | hw->chipset = ide_generic; | ||
75 | } | 73 | } |
76 | 74 | ||
77 | static void q40ide_input_data(ide_drive_t *drive, struct ide_cmd *cmd, | 75 | static void q40ide_input_data(ide_drive_t *drive, struct ide_cmd *cmd, |
@@ -119,6 +117,7 @@ static const struct ide_port_info q40ide_port_info = { | |||
119 | .tp_ops = &q40ide_tp_ops, | 117 | .tp_ops = &q40ide_tp_ops, |
120 | .host_flags = IDE_HFLAG_MMIO | IDE_HFLAG_NO_DMA, | 118 | .host_flags = IDE_HFLAG_MMIO | IDE_HFLAG_NO_DMA, |
121 | .irq_flags = IRQF_SHARED, | 119 | .irq_flags = IRQF_SHARED, |
120 | .chipset = ide_generic, | ||
122 | }; | 121 | }; |
123 | 122 | ||
124 | /* | 123 | /* |
@@ -136,7 +135,7 @@ static const char *q40_ide_names[Q40IDE_NUM_HWIFS]={ | |||
136 | static int __init q40ide_init(void) | 135 | static int __init q40ide_init(void) |
137 | { | 136 | { |
138 | int i; | 137 | int i; |
139 | hw_regs_t hw[Q40IDE_NUM_HWIFS], *hws[] = { NULL, NULL, NULL, NULL }; | 138 | struct ide_hw hw[Q40IDE_NUM_HWIFS], *hws[] = { NULL, NULL }; |
140 | 139 | ||
141 | if (!MACH_IS_Q40) | 140 | if (!MACH_IS_Q40) |
142 | return -ENODEV; | 141 | return -ENODEV; |
@@ -163,7 +162,7 @@ static int __init q40ide_init(void) | |||
163 | hws[i] = &hw[i]; | 162 | hws[i] = &hw[i]; |
164 | } | 163 | } |
165 | 164 | ||
166 | return ide_host_add(&q40ide_port_info, hws, NULL); | 165 | return ide_host_add(&q40ide_port_info, hws, Q40IDE_NUM_HWIFS, NULL); |
167 | } | 166 | } |
168 | 167 | ||
169 | module_init(q40ide_init); | 168 | module_init(q40ide_init); |