AR7 2.6.24 patches
[openwrt.git] / target / linux / ar7 / patches-2.6.24 / 100-board_support.patch
1 Index: linux-2.6.23-rc6/arch/mips/Kconfig
2 ===================================================================
3 --- linux-2.6.23-rc6.orig/arch/mips/Kconfig 2007-09-21 16:23:51.000000000 +0800
4 +++ linux-2.6.23-rc6/arch/mips/Kconfig 2007-09-21 16:24:11.000000000 +0800
5 @@ -15,6 +15,22 @@
6 prompt "System type"
7 default SGI_IP22
8
9 +config AR7
10 + bool "Texas Instruments AR7"
11 + select BOOT_ELF32
12 + select DMA_NONCOHERENT
13 + select IRQ_CPU
14 + select NO_EXCEPT_FILL
15 + select SWAP_IO_SPACE
16 + select SYS_HAS_CPU_MIPS32_R1
17 + select SYS_HAS_EARLY_PRINTK
18 + select SYS_SUPPORTS_32BIT_KERNEL
19 + select SYS_SUPPORTS_KGDB
20 + select SYS_SUPPORTS_LITTLE_ENDIAN
21 + select SYS_SUPPORTS_BIG_ENDIAN
22 + select GENERIC_GPIO
23 + select GENERIC_HARDIRQS_NO__DO_IRQ
24 +
25 config MACH_ALCHEMY
26 bool "Alchemy processor based machines"
27
28 Index: linux-2.6.23-rc6/arch/mips/kernel/traps.c
29 ===================================================================
30 --- linux-2.6.23-rc6.orig/arch/mips/kernel/traps.c 2007-09-21 16:23:51.000000000 +0800
31 +++ linux-2.6.23-rc6/arch/mips/kernel/traps.c 2007-09-21 16:24:11.000000000 +0800
32 @@ -1093,9 +1093,22 @@ void *set_except_vector(int n, void *addr)
33
34 exception_handlers[n] = handler;
35 if (n == 0 && cpu_has_divec) {
36 - *(u32 *)(ebase + 0x200) = 0x08000000 |
37 - (0x03ffffff & (handler >> 2));
38 - flush_icache_range(ebase + 0x200, ebase + 0x204);
39 + if ((handler ^ (ebase + 4)) & 0xfc000000) {
40 + /* lui k0, 0x0000 */
41 + *(u32 *)(ebase + 0x200) = 0x3c1a0000 | (handler >> 16);
42 + /* ori k0, 0x0000 */
43 + *(u32 *)(ebase + 0x204) =
44 + 0x375a0000 | (handler & 0xffff);
45 + /* jr k0 */
46 + *(u32 *)(ebase + 0x208) = 0x03400008;
47 + /* nop */
48 + *(u32 *)(ebase + 0x20C) = 0x00000000;
49 + flush_icache_range(ebase + 0x200, ebase + 0x210);
50 + } else {
51 + *(volatile u32 *)(ebase + 0x200) =
52 + 0x08000000 | (0x03ffffff & (handler >> 2));
53 + flush_icache_range(ebase + 0x200, ebase + 0x204);
54 + }
55 }
56 return (void *)old_handler;
57 }
58 Index: linux-2.6.23-rc6/arch/mips/Makefile
59 ===================================================================
60 --- linux-2.6.23-rc6.orig/arch/mips/Makefile 2007-09-21 16:24:05.000000000 +0800
61 +++ linux-2.6.23-rc6/arch/mips/Makefile 2007-09-21 16:24:11.000000000 +0800
62 @@ -161,6 +161,13 @@
63 #
64
65 #
66 +# Texas Instruments AR7
67 +#
68 +core-$(CONFIG_AR7) += arch/mips/ar7/
69 +cflags-$(CONFIG_AR7) += -Iinclude/asm-mips/ar7
70 +load-$(CONFIG_AR7) += 0xffffffff94100000
71 +
72 +#
73 # Acer PICA 61, Mips Magnum 4000 and Olivetti M700.
74 #
75 core-$(CONFIG_MACH_JAZZ) += arch/mips/jazz/
76 Index: linux-2.6.23-rc6/include/asm-mips/page.h
77 ===================================================================
78 --- linux-2.6.23-rc6.orig/include/asm-mips/page.h 2007-09-21 16:23:51.000000000 +0800
79 +++ linux-2.6.23-rc6/include/asm-mips/page.h 2007-09-21 16:24:11.000000000 +0800
80 @@ -184,8 +184,10 @@
81 #define VM_DATA_DEFAULT_FLAGS (VM_READ | VM_WRITE | VM_EXEC | \
82 VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC)
83
84 -#define UNCAC_ADDR(addr) ((addr) - PAGE_OFFSET + UNCAC_BASE)
85 -#define CAC_ADDR(addr) ((addr) - UNCAC_BASE + PAGE_OFFSET)
86 +#define UNCAC_ADDR(addr) ((addr) - PAGE_OFFSET + UNCAC_BASE + \
87 + PHYS_OFFSET)
88 +#define CAC_ADDR(addr) ((addr) - UNCAC_BASE + PAGE_OFFSET - \
89 + PHYS_OFFSET)
90
91 #include <asm-generic/memory_model.h>
92 #include <asm-generic/page.h>
This page took 0.057285 seconds and 5 git commands to generate.