aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorThomas Bogendoerfer <tsbogend@alpha.franken.de>2008-07-14 10:58:47 -0400
committerRalf Baechle <ralf@linux-mips.org>2008-07-15 13:44:39 -0400
commitb27418aa551a153e8bf1bd16cf93e5786f9590a9 (patch)
tree568fdf598effa5fe58e10781595392f101198529 /arch
parent0b56fd8c7abbf85baeecb77be25c54d3c7d11587 (diff)
[MIPS] Remove mips_machtype for LASAT machines
This is the LASAT part of the mips_machtype removal. Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de> Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch')
-rw-r--r--arch/mips/lasat/interrupt.c21
-rw-r--r--arch/mips/lasat/lasat_board.c3
-rw-r--r--arch/mips/lasat/prom.c8
-rw-r--r--arch/mips/lasat/serial.c3
-rw-r--r--arch/mips/lasat/setup.c8
-rw-r--r--arch/mips/pci/pci-lasat.c14
6 files changed, 22 insertions, 35 deletions
diff --git a/arch/mips/lasat/interrupt.c b/arch/mips/lasat/interrupt.c
index a56c15026965..d1ac7a25c856 100644
--- a/arch/mips/lasat/interrupt.c
+++ b/arch/mips/lasat/interrupt.c
@@ -22,8 +22,8 @@
22#include <linux/interrupt.h> 22#include <linux/interrupt.h>
23#include <linux/irq.h> 23#include <linux/irq.h>
24 24
25#include <asm/bootinfo.h>
26#include <asm/irq_cpu.h> 25#include <asm/irq_cpu.h>
26#include <asm/lasat/lasat.h>
27#include <asm/lasat/lasatint.h> 27#include <asm/lasat/lasatint.h>
28 28
29#include <irq.h> 29#include <irq.h>
@@ -112,23 +112,18 @@ void __init arch_init_irq(void)
112{ 112{
113 int i; 113 int i;
114 114
115 switch (mips_machtype) { 115 if (IS_LASAT_200()) {
116 case MACH_LASAT_100:
117 lasat_int_status = (void *)LASAT_INT_STATUS_REG_100;
118 lasat_int_mask = (void *)LASAT_INT_MASK_REG_100;
119 lasat_int_mask_shift = LASATINT_MASK_SHIFT_100;
120 get_int_status = get_int_status_100;
121 *lasat_int_mask = 0;
122 break;
123 case MACH_LASAT_200:
124 lasat_int_status = (void *)LASAT_INT_STATUS_REG_200; 116 lasat_int_status = (void *)LASAT_INT_STATUS_REG_200;
125 lasat_int_mask = (void *)LASAT_INT_MASK_REG_200; 117 lasat_int_mask = (void *)LASAT_INT_MASK_REG_200;
126 lasat_int_mask_shift = LASATINT_MASK_SHIFT_200; 118 lasat_int_mask_shift = LASATINT_MASK_SHIFT_200;
127 get_int_status = get_int_status_200; 119 get_int_status = get_int_status_200;
128 *lasat_int_mask &= 0xffff; 120 *lasat_int_mask &= 0xffff;
129 break; 121 } else {
130 default: 122 lasat_int_status = (void *)LASAT_INT_STATUS_REG_100;
131 panic("arch_init_irq: mips_machtype incorrect"); 123 lasat_int_mask = (void *)LASAT_INT_MASK_REG_100;
124 lasat_int_mask_shift = LASATINT_MASK_SHIFT_100;
125 get_int_status = get_int_status_100;
126 *lasat_int_mask = 0;
132 } 127 }
133 128
134 mips_cpu_irq_init(); 129 mips_cpu_irq_init();
diff --git a/arch/mips/lasat/lasat_board.c b/arch/mips/lasat/lasat_board.c
index 31e328b3814d..577bb463a871 100644
--- a/arch/mips/lasat/lasat_board.c
+++ b/arch/mips/lasat/lasat_board.c
@@ -24,7 +24,6 @@
24#include <linux/string.h> 24#include <linux/string.h>
25#include <linux/ctype.h> 25#include <linux/ctype.h>
26#include <linux/mutex.h> 26#include <linux/mutex.h>
27#include <asm/bootinfo.h>
28#include <asm/addrspace.h> 27#include <asm/addrspace.h>
29#include "at93c.h" 28#include "at93c.h"
30/* New model description table */ 29/* New model description table */
@@ -66,7 +65,7 @@ static void init_flash_sizes(void)
66 ls[LASAT_MTD_SERVICE] = 0xC0000; 65 ls[LASAT_MTD_SERVICE] = 0xC0000;
67 ls[LASAT_MTD_NORMAL] = 0x100000; 66 ls[LASAT_MTD_NORMAL] = 0x100000;
68 67
69 if (mips_machtype == MACH_LASAT_100) { 68 if (!IS_LASAT_200()) {
70 lasat_board_info.li_flash_base = 0x1e000000; 69 lasat_board_info.li_flash_base = 0x1e000000;
71 70
72 lb[LASAT_MTD_BOOTLOADER] = 0x1e400000; 71 lb[LASAT_MTD_BOOTLOADER] = 0x1e400000;
diff --git a/arch/mips/lasat/prom.c b/arch/mips/lasat/prom.c
index 209edcc26f07..6acc6cb85f0a 100644
--- a/arch/mips/lasat/prom.c
+++ b/arch/mips/lasat/prom.c
@@ -86,18 +86,16 @@ void __init prom_init(void)
86 86
87 setup_prom_vectors(); 87 setup_prom_vectors();
88 88
89 if (current_cpu_data.cputype == CPU_R5000) { 89 if (IS_LASAT_200()) {
90 printk(KERN_INFO "LASAT 200 board\n"); 90 printk(KERN_INFO "LASAT 200 board\n");
91 mips_machtype = MACH_LASAT_200;
92 lasat_ndelay_divider = LASAT_200_DIVIDER; 91 lasat_ndelay_divider = LASAT_200_DIVIDER;
92 at93c = &at93c_defs[1];
93 } else { 93 } else {
94 printk(KERN_INFO "LASAT 100 board\n"); 94 printk(KERN_INFO "LASAT 100 board\n");
95 mips_machtype = MACH_LASAT_100;
96 lasat_ndelay_divider = LASAT_100_DIVIDER; 95 lasat_ndelay_divider = LASAT_100_DIVIDER;
96 at93c = &at93c_defs[0];
97 } 97 }
98 98
99 at93c = &at93c_defs[mips_machtype];
100
101 lasat_init_board_info(); /* Read info from EEPROM */ 99 lasat_init_board_info(); /* Read info from EEPROM */
102 100
103 /* Get the command line */ 101 /* Get the command line */
diff --git a/arch/mips/lasat/serial.c b/arch/mips/lasat/serial.c
index 205bd397d75b..5bcb6e89ab78 100644
--- a/arch/mips/lasat/serial.c
+++ b/arch/mips/lasat/serial.c
@@ -23,7 +23,6 @@
23#include <linux/platform_device.h> 23#include <linux/platform_device.h>
24#include <linux/serial_8250.h> 24#include <linux/serial_8250.h>
25 25
26#include <asm/bootinfo.h>
27#include <asm/lasat/lasat.h> 26#include <asm/lasat/lasat.h>
28#include <asm/lasat/serial.h> 27#include <asm/lasat/serial.h>
29 28
@@ -47,7 +46,7 @@ static __init int lasat_uart_add(void)
47 if (!pdev) 46 if (!pdev)
48 return -ENOMEM; 47 return -ENOMEM;
49 48
50 if (mips_machtype == MACH_LASAT_100) { 49 if (!IS_LASAT_200()) {
51 lasat_serial_res[0].start = KSEG1ADDR(LASAT_UART_REGS_BASE_100); 50 lasat_serial_res[0].start = KSEG1ADDR(LASAT_UART_REGS_BASE_100);
52 lasat_serial_res[0].end = lasat_serial_res[0].start + LASAT_UART_REGS_SHIFT_100 * 8 - 1; 51 lasat_serial_res[0].end = lasat_serial_res[0].start + LASAT_UART_REGS_SHIFT_100 * 8 - 1;
53 lasat_serial_res[0].flags = IORESOURCE_MEM; 52 lasat_serial_res[0].flags = IORESOURCE_MEM;
diff --git a/arch/mips/lasat/setup.c b/arch/mips/lasat/setup.c
index e072da4ff3b3..dbd3163a85c2 100644
--- a/arch/mips/lasat/setup.c
+++ b/arch/mips/lasat/setup.c
@@ -127,9 +127,11 @@ void __init plat_time_init(void)
127void __init plat_mem_setup(void) 127void __init plat_mem_setup(void)
128{ 128{
129 int i; 129 int i;
130 lasat_misc = &lasat_misc_info[mips_machtype]; 130 int lasat_type = IS_LASAT_200() ? 1 : 0;
131
132 lasat_misc = &lasat_misc_info[lasat_type];
131#ifdef CONFIG_PICVUE 133#ifdef CONFIG_PICVUE
132 picvue = &pvc_defs[mips_machtype]; 134 picvue = &pvc_defs[lasat_type];
133#endif 135#endif
134 136
135 /* Set up panic notifier */ 137 /* Set up panic notifier */
@@ -140,7 +142,7 @@ void __init plat_mem_setup(void)
140 lasat_reboot_setup(); 142 lasat_reboot_setup();
141 143
142#ifdef CONFIG_DS1603 144#ifdef CONFIG_DS1603
143 ds1603 = &ds_defs[mips_machtype]; 145 ds1603 = &ds_defs[lasat_type];
144#endif 146#endif
145 147
146#ifdef DYNAMIC_SERIAL_INIT 148#ifdef DYNAMIC_SERIAL_INIT
diff --git a/arch/mips/pci/pci-lasat.c b/arch/mips/pci/pci-lasat.c
index e70ae3236e0b..a98e543a514a 100644
--- a/arch/mips/pci/pci-lasat.c
+++ b/arch/mips/pci/pci-lasat.c
@@ -10,7 +10,7 @@
10#include <linux/pci.h> 10#include <linux/pci.h>
11#include <linux/types.h> 11#include <linux/types.h>
12 12
13#include <asm/bootinfo.h> 13#include <asm/lasat/lasat.h>
14 14
15#include <irq.h> 15#include <irq.h>
16 16
@@ -39,16 +39,10 @@ static int __init lasat_pci_setup(void)
39{ 39{
40 printk(KERN_DEBUG "PCI: starting\n"); 40 printk(KERN_DEBUG "PCI: starting\n");
41 41
42 switch (mips_machtype) { 42 if (IS_LASAT_200())
43 case MACH_LASAT_100:
44 lasat_pci_controller.pci_ops = &gt64xxx_pci0_ops;
45 break;
46 case MACH_LASAT_200:
47 lasat_pci_controller.pci_ops = &nile4_pci_ops; 43 lasat_pci_controller.pci_ops = &nile4_pci_ops;
48 break; 44 else
49 default: 45 lasat_pci_controller.pci_ops = &gt64xxx_pci0_ops;
50 panic("pcibios_init: mips_machtype incorrect");
51 }
52 46
53 register_pci_controller(&lasat_pci_controller); 47 register_pci_controller(&lasat_pci_controller);
54 48