cleanup (use dma API, use accessors, debugging/printk cleanup)
[openwrt.git] / target / linux / brcm47xx / patches-2.6.22 / 100-board_support.patch
1 Index: linux-2.6.22-rc4/arch/mips/Kconfig
2 ===================================================================
3 --- linux-2.6.22-rc4.orig/arch/mips/Kconfig 2007-06-10 21:32:36.000000000 +0100
4 +++ linux-2.6.22-rc4/arch/mips/Kconfig 2007-06-10 21:33:12.000000000 +0100
5 @@ -4,6 +4,10 @@
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 @@ -126,6 +130,23 @@
17 Members include the Acer PICA, MIPS Magnum 4000, MIPS Millenium and
18 Olivetti M700-10 workstations.
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 LASAT
38 bool "LASAT Networks platforms"
39 select DMA_NONCOHERENT
40 Index: linux-2.6.22-rc4/arch/mips/kernel/cpu-probe.c
41 ===================================================================
42 --- linux-2.6.22-rc4.orig/arch/mips/kernel/cpu-probe.c 2007-06-10 21:32:13.000000000 +0100
43 +++ linux-2.6.22-rc4/arch/mips/kernel/cpu-probe.c 2007-06-10 21:33:12.000000000 +0100
44 @@ -711,6 +711,28 @@
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 @@ -733,6 +755,9 @@
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.22-rc4/arch/mips/kernel/proc.c
84 ===================================================================
85 --- linux-2.6.22-rc4.orig/arch/mips/kernel/proc.c 2007-06-10 21:32:13.000000000 +0100
86 +++ linux-2.6.22-rc4/arch/mips/kernel/proc.c 2007-06-10 21:33:12.000000000 +0100
87 @@ -83,6 +83,8 @@
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 };
95
96 Index: linux-2.6.22-rc4/arch/mips/Makefile
97 ===================================================================
98 --- linux-2.6.22-rc4.orig/arch/mips/Makefile 2007-06-10 21:32:56.000000000 +0100
99 +++ linux-2.6.22-rc4/arch/mips/Makefile 2007-06-10 21:33:12.000000000 +0100
100 @@ -560,6 +560,18 @@
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.22-rc4/arch/mips/mm/tlbex.c
120 ===================================================================
121 --- linux-2.6.22-rc4.orig/arch/mips/mm/tlbex.c 2007-06-10 21:32:35.000000000 +0100
122 +++ linux-2.6.22-rc4/arch/mips/mm/tlbex.c 2007-06-10 21:33:12.000000000 +0100
123 @@ -892,6 +892,8 @@
124 case CPU_4KSC:
125 case CPU_20KC:
126 case CPU_25KF:
127 + case CPU_BCM3302:
128 + case CPU_BCM4710:
129 tlbw(p);
130 break;
131
132 Index: linux-2.6.22-rc4/drivers/Kconfig
133 ===================================================================
134 --- linux-2.6.22-rc4.orig/drivers/Kconfig 2007-06-10 21:32:13.000000000 +0100
135 +++ linux-2.6.22-rc4/drivers/Kconfig 2007-06-10 21:33:12.000000000 +0100
136 @@ -56,6 +56,8 @@
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.22-rc4/drivers/Makefile
146 ===================================================================
147 --- linux-2.6.22-rc4.orig/drivers/Makefile 2007-06-10 21:32:14.000000000 +0100
148 +++ linux-2.6.22-rc4/drivers/Makefile 2007-06-10 21:33:12.000000000 +0100
149 @@ -81,3 +81,4 @@
150 obj-$(CONFIG_DMA_ENGINE) += dma/
151 obj-$(CONFIG_HID) += hid/
152 obj-$(CONFIG_PPC_PS3) += ps3/
153 +obj-$(CONFIG_SSB) += ssb/
154 Index: linux-2.6.22-rc4/include/asm-mips/bootinfo.h
155 ===================================================================
156 --- linux-2.6.22-rc4.orig/include/asm-mips/bootinfo.h 2007-06-10 21:32:14.000000000 +0100
157 +++ linux-2.6.22-rc4/include/asm-mips/bootinfo.h 2007-06-10 21:33:12.000000000 +0100
158 @@ -213,6 +213,12 @@
159 #define MACH_GROUP_NEC_EMMA2RH 25 /* NEC EMMA2RH (was 23) */
160 #define MACH_NEC_MARKEINS 0 /* NEC EMMA2RH Mark-eins */
161
162 +/*
163 + * Valid machtype for group Broadcom
164 + */
165 +#define MACH_GROUP_BRCM 23 /* Broadcom */
166 +#define MACH_BCM47XX 1 /* Broadcom BCM47xx */
167 +
168 #define CL_SIZE COMMAND_LINE_SIZE
169
170 const char *get_system_type(void);
171 Index: linux-2.6.22-rc4/include/asm-mips/cpu.h
172 ===================================================================
173 --- linux-2.6.22-rc4.orig/include/asm-mips/cpu.h 2007-06-10 21:32:14.000000000 +0100
174 +++ linux-2.6.22-rc4/include/asm-mips/cpu.h 2007-06-10 21:33:12.000000000 +0100
175 @@ -104,6 +104,13 @@
176 #define PRID_IMP_SR71000 0x0400
177
178 /*
179 + * These are the PRID's for when 23:16 == PRID_COMP_BROADCOM
180 + */
181 +
182 +#define PRID_IMP_BCM4710 0x4000
183 +#define PRID_IMP_BCM3302 0x9000
184 +
185 +/*
186 * Definitions for 7:0 on legacy processors
187 */
188
189 @@ -200,7 +207,9 @@
190 #define CPU_SB1A 62
191 #define CPU_74K 63
192 #define CPU_R14000 64
193 -#define CPU_LAST 64
194 +#define CPU_BCM3302 65
195 +#define CPU_BCM4710 66
196 +#define CPU_LAST 66
197
198 /*
199 * ISA Level encodings
200 Index: linux-2.6.22-rc4/include/linux/pci_ids.h
201 ===================================================================
202 --- linux-2.6.22-rc4.orig/include/linux/pci_ids.h 2007-06-10 21:32:14.000000000 +0100
203 +++ linux-2.6.22-rc4/include/linux/pci_ids.h 2007-06-10 21:33:12.000000000 +0100
204 @@ -1991,6 +1991,7 @@
205 #define PCI_DEVICE_ID_TIGON3_5906M 0x1713
206 #define PCI_DEVICE_ID_BCM4401 0x4401
207 #define PCI_DEVICE_ID_BCM4401B0 0x4402
208 +#define PCI_DEVICE_ID_BCM4713 0x4713
209
210 #define PCI_VENDOR_ID_TOPIC 0x151f
211 #define PCI_DEVICE_ID_TOPIC_TP560 0x0000
This page took 0.073659 seconds and 5 git commands to generate.