some more mvswitch fixes:
[openwrt.git] / target / linux / brcm47xx / patches-2.6.23 / 100-board_support.patch
1 Index: linux-2.6.23.17/arch/mips/Kconfig
2 ===================================================================
3 --- linux-2.6.23.17.orig/arch/mips/Kconfig
4 +++ linux-2.6.23.17/arch/mips/Kconfig
5 @@ -4,6 +4,10 @@ config MIPS
6 # Horrible source of confusion. Die, die, die ...
7 select EMBEDDED
8
9 +config CFE
10 + bool
11 + # Common Firmware Environment
12 +
13 mainmenu "Linux/MIPS Kernel Configuration"
14
15 menu "Machine selection"
16 @@ -44,6 +48,23 @@ config BASLER_EXCITE_PROTOTYPE
17 note that a kernel built with this option selected will not be
18 able to run on normal units.
19
20 +config BCM947XX
21 + bool "Support for BCM947xx based boards"
22 + select DMA_NONCOHERENT
23 + select HW_HAS_PCI
24 + select IRQ_CPU
25 + select SYS_HAS_CPU_MIPS32_R1
26 + select SYS_SUPPORTS_32BIT_KERNEL
27 + select SYS_SUPPORTS_LITTLE_ENDIAN
28 + select SSB
29 + select SSB_SERIAL
30 + select SSB_DRIVER_PCICORE
31 + select SSB_PCICORE_HOSTMODE
32 + select CFE
33 + select GENERIC_GPIO
34 + help
35 + Support for BCM947xx based boards
36 +
37 config MIPS_COBALT
38 bool "Cobalt Server"
39 select DMA_NONCOHERENT
40 Index: linux-2.6.23.17/arch/mips/kernel/cpu-probe.c
41 ===================================================================
42 --- linux-2.6.23.17.orig/arch/mips/kernel/cpu-probe.c
43 +++ linux-2.6.23.17/arch/mips/kernel/cpu-probe.c
44 @@ -793,6 +793,28 @@ static inline void cpu_probe_philips(str
45 }
46
47
48 +static inline void cpu_probe_broadcom(struct cpuinfo_mips *c)
49 +{
50 + decode_config1(c);
51 + switch (c->processor_id & 0xff00) {
52 + case PRID_IMP_BCM3302:
53 + c->cputype = CPU_BCM3302;
54 + c->isa_level = MIPS_CPU_ISA_M32R1;
55 + c->options = MIPS_CPU_TLB | MIPS_CPU_4KEX |
56 + MIPS_CPU_4K_CACHE | MIPS_CPU_COUNTER;
57 + break;
58 + case PRID_IMP_BCM4710:
59 + c->cputype = CPU_BCM4710;
60 + c->isa_level = MIPS_CPU_ISA_M32R1;
61 + c->options = MIPS_CPU_TLB | MIPS_CPU_4KEX |
62 + MIPS_CPU_4K_CACHE | MIPS_CPU_COUNTER;
63 + break;
64 + default:
65 + c->cputype = CPU_UNKNOWN;
66 + break;
67 + }
68 +}
69 +
70 __init void cpu_probe(void)
71 {
72 struct cpuinfo_mips *c = &current_cpu_data;
73 @@ -815,6 +837,9 @@ __init void cpu_probe(void)
74 case PRID_COMP_SIBYTE:
75 cpu_probe_sibyte(c);
76 break;
77 + case PRID_COMP_BROADCOM:
78 + cpu_probe_broadcom(c);
79 + break;
80 case PRID_COMP_SANDCRAFT:
81 cpu_probe_sandcraft(c);
82 break;
83 Index: linux-2.6.23.17/arch/mips/kernel/proc.c
84 ===================================================================
85 --- linux-2.6.23.17.orig/arch/mips/kernel/proc.c
86 +++ linux-2.6.23.17/arch/mips/kernel/proc.c
87 @@ -82,6 +82,8 @@ static const char *cpu_name[] = {
88 [CPU_VR4181] = "NEC VR4181",
89 [CPU_VR4181A] = "NEC VR4181A",
90 [CPU_SR71000] = "Sandcraft SR71000",
91 + [CPU_BCM3302] = "Broadcom BCM3302",
92 + [CPU_BCM4710] = "Broadcom BCM4710",
93 [CPU_PR4450] = "Philips PR4450",
94 [CPU_LOONGSON2] = "ICT Loongson-2",
95 };
96 Index: linux-2.6.23.17/arch/mips/Makefile
97 ===================================================================
98 --- linux-2.6.23.17.orig/arch/mips/Makefile
99 +++ linux-2.6.23.17/arch/mips/Makefile
100 @@ -533,6 +533,18 @@ libs-$(CONFIG_SIBYTE_BIGSUR) += arch/mip
101 load-$(CONFIG_SIBYTE_BIGSUR) := 0xffffffff80100000
102
103 #
104 +# Broadcom BCM47XX boards
105 +#
106 +core-$(CONFIG_BCM947XX) += arch/mips/bcm947xx/
107 +cflags-$(CONFIG_BCM947XX) += -Iarch/mips/bcm947xx/include -Iinclude/asm-mips/mach-bcm947xx
108 +load-$(CONFIG_BCM947XX) := 0xffffffff80001000
109 +
110 +#
111 +# Common Firmware Environment
112 +#
113 +core-$(CONFIG_CFE) += arch/mips/cfe/
114 +
115 +#
116 # SNI RM
117 #
118 core-$(CONFIG_SNI_RM) += arch/mips/sni/
119 Index: linux-2.6.23.17/arch/mips/mm/tlbex.c
120 ===================================================================
121 --- linux-2.6.23.17.orig/arch/mips/mm/tlbex.c
122 +++ linux-2.6.23.17/arch/mips/mm/tlbex.c
123 @@ -895,6 +895,8 @@ static __init void build_tlb_write_entry
124 case CPU_AU1550:
125 case CPU_AU1200:
126 case CPU_PR4450:
127 + case CPU_BCM3302:
128 + case CPU_BCM4710:
129 i_nop(p);
130 tlbw(p);
131 break;
132 Index: linux-2.6.23.17/drivers/Kconfig
133 ===================================================================
134 --- linux-2.6.23.17.orig/drivers/Kconfig
135 +++ linux-2.6.23.17/drivers/Kconfig
136 @@ -60,6 +60,8 @@ source "drivers/power/Kconfig"
137
138 source "drivers/hwmon/Kconfig"
139
140 +source "drivers/ssb/Kconfig"
141 +
142 source "drivers/mfd/Kconfig"
143
144 source "drivers/media/Kconfig"
145 Index: linux-2.6.23.17/include/asm-mips/bootinfo.h
146 ===================================================================
147 --- linux-2.6.23.17.orig/include/asm-mips/bootinfo.h
148 +++ linux-2.6.23.17/include/asm-mips/bootinfo.h
149 @@ -208,6 +208,12 @@
150 #define MACH_GROUP_WINDRIVER 28 /* Windriver boards */
151 #define MACH_WRPPMC 1
152
153 +/*
154 + * Valid machtype for group Broadcom
155 + */
156 +#define MACH_GROUP_BRCM 23 /* Broadcom */
157 +#define MACH_BCM47XX 1 /* Broadcom BCM47xx */
158 +
159 #define CL_SIZE COMMAND_LINE_SIZE
160
161 const char *get_system_type(void);
162 Index: linux-2.6.23.17/include/asm-mips/cpu.h
163 ===================================================================
164 --- linux-2.6.23.17.orig/include/asm-mips/cpu.h
165 +++ linux-2.6.23.17/include/asm-mips/cpu.h
166 @@ -106,6 +106,13 @@
167 #define PRID_IMP_SR71000 0x0400
168
169 /*
170 + * These are the PRID's for when 23:16 == PRID_COMP_BROADCOM
171 + */
172 +
173 +#define PRID_IMP_BCM4710 0x4000
174 +#define PRID_IMP_BCM3302 0x9000
175 +
176 +/*
177 * Definitions for 7:0 on legacy processors
178 */
179
180 @@ -217,8 +224,10 @@
181 #define CPU_R14000 64
182 #define CPU_LOONGSON1 65
183 #define CPU_LOONGSON2 66
184 +#define CPU_BCM3302 67
185 +#define CPU_BCM4710 68
186
187 -#define CPU_LAST 66
188 +#define CPU_LAST 68
189
190 /*
191 * ISA Level encodings
192 Index: linux-2.6.23.17/drivers/Makefile
193 ===================================================================
194 --- linux-2.6.23.17.orig/drivers/Makefile
195 +++ linux-2.6.23.17/drivers/Makefile
196 @@ -90,3 +90,4 @@ obj-$(CONFIG_HID) += hid/
197 obj-$(CONFIG_PPC_PS3) += ps3/
198 obj-$(CONFIG_OF) += of/
199 obj-$(CONFIG_GPIO_DEVICE) += gpio/
200 +obj-$(CONFIG_SSB) += ssb/
201 Index: linux-2.6.23.17/include/linux/pci_ids.h
202 ===================================================================
203 --- linux-2.6.23.17.orig/include/linux/pci_ids.h
204 +++ linux-2.6.23.17/include/linux/pci_ids.h
205 @@ -1980,6 +1980,7 @@
206 #define PCI_DEVICE_ID_TIGON3_5906M 0x1713
207 #define PCI_DEVICE_ID_BCM4401 0x4401
208 #define PCI_DEVICE_ID_BCM4401B0 0x4402
209 +#define PCI_DEVICE_ID_BCM4713 0x4713
210
211 #define PCI_VENDOR_ID_TOPIC 0x151f
212 #define PCI_DEVICE_ID_TOPIC_TP560 0x0000
This page took 0.056961 seconds and 5 git commands to generate.