diff options
author | Thiemo Seufer <ths@networkno.de> | 2005-07-03 15:12:05 -0400 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2005-10-29 14:31:35 -0400 |
commit | ec125c129e864390deef47f792e3174442e4099f (patch) | |
tree | d6a73b98d0f71e894ba792d6f66f4bab3d721917 /arch/mips | |
parent | a5fc9c0bbee8b91025993a49a9176a88380aef3c (diff) |
Code cleanup, thanks Brian Murphy.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Thiemo Seufer <ths@networkno.de>
Diffstat (limited to 'arch/mips')
-rw-r--r-- | arch/mips/pci/pci-lasat.c | 50 |
1 files changed, 24 insertions, 26 deletions
diff --git a/arch/mips/pci/pci-lasat.c b/arch/mips/pci/pci-lasat.c index 74943d685170..f20fde388083 100644 --- a/arch/mips/pci/pci-lasat.c +++ b/arch/mips/pci/pci-lasat.c | |||
@@ -7,10 +7,8 @@ | |||
7 | */ | 7 | */ |
8 | #include <linux/kernel.h> | 8 | #include <linux/kernel.h> |
9 | #include <linux/init.h> | 9 | #include <linux/init.h> |
10 | #include <linux/interrupt.h> | ||
11 | #include <linux/pci.h> | 10 | #include <linux/pci.h> |
12 | #include <linux/types.h> | 11 | #include <linux/types.h> |
13 | #include <linux/delay.h> | ||
14 | #include <asm/bootinfo.h> | 12 | #include <asm/bootinfo.h> |
15 | 13 | ||
16 | extern struct pci_ops nile4_pci_ops; | 14 | extern struct pci_ops nile4_pci_ops; |
@@ -18,14 +16,14 @@ extern struct pci_ops gt64120_pci_ops; | |||
18 | static struct resource lasat_pci_mem_resource = { | 16 | static struct resource lasat_pci_mem_resource = { |
19 | .name = "LASAT PCI MEM", | 17 | .name = "LASAT PCI MEM", |
20 | .start = 0x18000000, | 18 | .start = 0x18000000, |
21 | .end = 0x19FFFFFF, | 19 | .end = 0x19ffffff, |
22 | .flags = IORESOURCE_MEM, | 20 | .flags = IORESOURCE_MEM, |
23 | }; | 21 | }; |
24 | 22 | ||
25 | static struct resource lasat_pci_io_resource = { | 23 | static struct resource lasat_pci_io_resource = { |
26 | .name = "LASAT PCI IO", | 24 | .name = "LASAT PCI IO", |
27 | .start = 0x1a000000, | 25 | .start = 0x1a000000, |
28 | .end = 0x1bFFFFFF, | 26 | .end = 0x1bffffff, |
29 | .flags = IORESOURCE_IO, | 27 | .flags = IORESOURCE_IO, |
30 | }; | 28 | }; |
31 | 29 | ||
@@ -36,16 +34,16 @@ static struct pci_controller lasat_pci_controller = { | |||
36 | 34 | ||
37 | static int __init lasat_pci_setup(void) | 35 | static int __init lasat_pci_setup(void) |
38 | { | 36 | { |
39 | printk("PCI: starting\n"); | 37 | printk("PCI: starting\n"); |
40 | 38 | ||
41 | switch (mips_machtype) { | 39 | switch (mips_machtype) { |
42 | case MACH_LASAT_100: | 40 | case MACH_LASAT_100: |
43 | lasat_pci_controller.pci_ops = >64120_pci_ops; | 41 | lasat_pci_controller.pci_ops = >64120_pci_ops; |
44 | break; | 42 | break; |
45 | case MACH_LASAT_200: | 43 | case MACH_LASAT_200: |
46 | lasat_pci_controller.pci_ops = &nile4_pci_ops; | 44 | lasat_pci_controller.pci_ops = &nile4_pci_ops; |
47 | break; | 45 | break; |
48 | default: | 46 | default: |
49 | panic("pcibios_init: mips_machtype incorrect"); | 47 | panic("pcibios_init: mips_machtype incorrect"); |
50 | } | 48 | } |
51 | 49 | ||
@@ -68,24 +66,24 @@ arch_initcall(lasat_pci_setup); | |||
68 | 66 | ||
69 | int __init pcibios_map_irq(struct pci_dev *dev, u8 slot, u8 pin) | 67 | int __init pcibios_map_irq(struct pci_dev *dev, u8 slot, u8 pin) |
70 | { | 68 | { |
71 | switch (slot) { | 69 | switch (slot) { |
72 | case 1: | 70 | case 1: |
73 | return LASATINT_PCIA; /* Expansion Module 0 */ | 71 | return LASATINT_PCIA; |
74 | case 2: | 72 | case 2: |
75 | return LASATINT_PCIB; /* Expansion Module 1 */ | 73 | return LASATINT_PCIB; |
76 | case 3: | 74 | case 3: |
77 | return LASATINT_PCIC; /* Expansion Module 2 */ | 75 | return LASATINT_PCIC; |
78 | case 4: | 76 | case 4: |
79 | return LASATINT_ETH1; /* Ethernet 1 (LAN 2) */ | 77 | return LASATINT_ETH1; /* Ethernet 1 (LAN 2) */ |
80 | case 5: | 78 | case 5: |
81 | return LASATINT_ETH0; /* Ethernet 0 (LAN 1) */ | 79 | return LASATINT_ETH0; /* Ethernet 0 (LAN 1) */ |
82 | case 6: | 80 | case 6: |
83 | return LASATINT_HDC; /* IDE controller */ | 81 | return LASATINT_HDC; /* IDE controller */ |
84 | default: | 82 | default: |
85 | return 0xff; /* Illegal */ | 83 | return 0xff; /* Illegal */ |
86 | } | 84 | } |
87 | 85 | ||
88 | return -1; | 86 | return -1; |
89 | } | 87 | } |
90 | 88 | ||
91 | /* Do platform specific device initialization at pci_enable_device() time */ | 89 | /* Do platform specific device initialization at pci_enable_device() time */ |