diff options
author | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2008-04-17 18:46:34 -0400 |
---|---|---|
committer | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2008-04-17 18:46:34 -0400 |
commit | ffd4f6f0eed0423652826f3775077d11918b4180 (patch) | |
tree | f574449a3fa0da029d42b401336adefa42bca06b /drivers/ide/ide.c | |
parent | 26d799b729003220c0f3e5d9e046e1588c011897 (diff) |
ide: add ide-4drives host driver (take 3)
CONFIG_BLK_DEV_4DRIVES deserves its own host driver:
* Add drivers/ide/legacy/ide-4drives.c and move "4drives" support there.
* Add ide-4drives.o in the link order after all other legacy host
drivers enabled by "ide0=" options (they all are mutually exclusive).
* Make ide-4drives host driver probe itself for IDE devices instead of
indirectly depending on ide_generic host driver.
* Add "probe" module parameter to ide-4drives and update documentation.
v2:
* s/paramater/parameter/ in ide.txt. (Noticed by Randy Dunlap)
v3:
* s/ide_4drives.probe/ide-4drives.probe/ in help entry.
(Noticed by Sergei Shtylyov)
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/ide.c')
-rw-r--r-- | drivers/ide/ide.c | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/drivers/ide/ide.c b/drivers/ide/ide.c index adecf45a0849..690b5ff4d88f 100644 --- a/drivers/ide/ide.c +++ b/drivers/ide/ide.c | |||
@@ -976,6 +976,7 @@ extern int probe_dtc2278; | |||
976 | extern int probe_ht6560b; | 976 | extern int probe_ht6560b; |
977 | extern int probe_qd65xx; | 977 | extern int probe_qd65xx; |
978 | extern int cmd640_vlb; | 978 | extern int cmd640_vlb; |
979 | extern int probe_4drives; | ||
979 | 980 | ||
980 | static int __initdata is_chipset_set; | 981 | static int __initdata is_chipset_set; |
981 | 982 | ||
@@ -1187,19 +1188,9 @@ static int __init ide_setup(char *s) | |||
1187 | #endif | 1188 | #endif |
1188 | #ifdef CONFIG_BLK_DEV_4DRIVES | 1189 | #ifdef CONFIG_BLK_DEV_4DRIVES |
1189 | case -11: /* "four" drives on one set of ports */ | 1190 | case -11: /* "four" drives on one set of ports */ |
1190 | { | 1191 | probe_4drives = 1; |
1191 | ide_hwif_t *mate = &ide_hwifs[hw^1]; | ||
1192 | mate->drives[0].select.all ^= 0x20; | ||
1193 | mate->drives[1].select.all ^= 0x20; | ||
1194 | hwif->chipset = mate->chipset = ide_4drives; | ||
1195 | mate->irq = hwif->irq; | ||
1196 | memcpy(mate->io_ports, hwif->io_ports, sizeof(hwif->io_ports)); | ||
1197 | hwif->mate = mate; | ||
1198 | mate->mate = hwif; | ||
1199 | hwif->serialized = mate->serialized = 1; | ||
1200 | goto obsolete_option; | 1192 | goto obsolete_option; |
1201 | } | 1193 | #endif |
1202 | #endif /* CONFIG_BLK_DEV_4DRIVES */ | ||
1203 | case -10: /* minus10 */ | 1194 | case -10: /* minus10 */ |
1204 | case -9: /* minus9 */ | 1195 | case -9: /* minus9 */ |
1205 | case -8: /* minus8 */ | 1196 | case -8: /* minus8 */ |