diff options
Diffstat (limited to 'include/asm-mips/mach-generic/ide.h')
| -rw-r--r-- | include/asm-mips/mach-generic/ide.h | 48 |
1 files changed, 0 insertions, 48 deletions
diff --git a/include/asm-mips/mach-generic/ide.h b/include/asm-mips/mach-generic/ide.h index 0f6c251f5fec..73008f7bdc93 100644 --- a/include/asm-mips/mach-generic/ide.h +++ b/include/asm-mips/mach-generic/ide.h | |||
| @@ -19,14 +19,6 @@ | |||
| 19 | #include <linux/stddef.h> | 19 | #include <linux/stddef.h> |
| 20 | #include <asm/processor.h> | 20 | #include <asm/processor.h> |
| 21 | 21 | ||
| 22 | #ifndef MAX_HWIFS | ||
| 23 | # ifdef CONFIG_BLK_DEV_IDEPCI | ||
| 24 | #define MAX_HWIFS 10 | ||
| 25 | # else | ||
| 26 | #define MAX_HWIFS 6 | ||
| 27 | # endif | ||
| 28 | #endif | ||
| 29 | |||
| 30 | static __inline__ int ide_probe_legacy(void) | 22 | static __inline__ int ide_probe_legacy(void) |
| 31 | { | 23 | { |
| 32 | #ifdef CONFIG_PCI | 24 | #ifdef CONFIG_PCI |
| @@ -56,46 +48,6 @@ found: | |||
| 56 | #endif | 48 | #endif |
| 57 | } | 49 | } |
| 58 | 50 | ||
| 59 | static __inline__ int ide_default_irq(unsigned long base) | ||
| 60 | { | ||
| 61 | switch (base) { | ||
| 62 | case 0x1f0: return 14; | ||
| 63 | case 0x170: return 15; | ||
| 64 | case 0x1e8: return 11; | ||
| 65 | case 0x168: return 10; | ||
| 66 | case 0x1e0: return 8; | ||
| 67 | case 0x160: return 12; | ||
| 68 | default: | ||
| 69 | return 0; | ||
| 70 | } | ||
| 71 | } | ||
| 72 | |||
| 73 | static __inline__ unsigned long ide_default_io_base(int index) | ||
| 74 | { | ||
| 75 | if (!ide_probe_legacy()) | ||
| 76 | return 0; | ||
| 77 | /* | ||
| 78 | * If PCI is present then it is not safe to poke around | ||
| 79 | * the other legacy IDE ports. Only 0x1f0 and 0x170 are | ||
| 80 | * defined compatibility mode ports for PCI. A user can | ||
| 81 | * override this using ide= but we must default safe. | ||
| 82 | */ | ||
| 83 | if (no_pci_devices()) { | ||
| 84 | switch (index) { | ||
| 85 | case 2: return 0x1e8; | ||
| 86 | case 3: return 0x168; | ||
| 87 | case 4: return 0x1e0; | ||
| 88 | case 5: return 0x160; | ||
| 89 | } | ||
| 90 | } | ||
| 91 | switch (index) { | ||
| 92 | case 0: return 0x1f0; | ||
| 93 | case 1: return 0x170; | ||
| 94 | default: | ||
| 95 | return 0; | ||
| 96 | } | ||
| 97 | } | ||
| 98 | |||
| 99 | /* MIPS port and memory-mapped I/O string operations. */ | 51 | /* MIPS port and memory-mapped I/O string operations. */ |
| 100 | static inline void __ide_flush_prologue(void) | 52 | static inline void __ide_flush_prologue(void) |
| 101 | { | 53 | { |
