diff options
author | Linus Torvalds <torvalds@g5.osdl.org> | 2005-11-06 19:58:11 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-11-06 19:58:11 -0500 |
commit | b54a063df48cb1296f744b5ba456c45ce7efff35 (patch) | |
tree | 72e71bfb6008f460f887a208d046cd82e5545ff5 | |
parent | 085f20e481190cd0597d72ec49bffc07bda4c9be (diff) | |
parent | 1555972231f3202f00e04f7c42d2db858e11b874 (diff) |
Merge master.kernel.org:/home/rmk/linux-2.6-arm
-rw-r--r-- | Documentation/arm/README | 7 | ||||
-rw-r--r-- | MAINTAINERS | 5 | ||||
-rw-r--r-- | arch/arm/kernel/entry-armv.S | 15 | ||||
-rw-r--r-- | arch/arm/kernel/setup.c | 10 | ||||
-rw-r--r-- | arch/arm/mach-ixp2000/uengine.c | 11 | ||||
-rw-r--r-- | arch/arm/mach-ixp4xx/common-pci.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-pxa/Kconfig | 9 | ||||
-rw-r--r-- | arch/arm/mach-pxa/Makefile | 1 | ||||
-rw-r--r-- | arch/arm/mach-pxa/pm.c | 16 | ||||
-rw-r--r-- | arch/arm/mach-pxa/tosa.c | 162 | ||||
-rw-r--r-- | include/asm-arm/arch-iop3xx/iop331.h | 2 | ||||
-rw-r--r-- | include/asm-arm/arch-pxa/pm.h | 12 | ||||
-rw-r--r-- | include/asm-arm/arch-pxa/tosa.h | 166 | ||||
-rw-r--r-- | include/asm-arm/mmu_context.h | 1 |
14 files changed, 391 insertions, 28 deletions
diff --git a/Documentation/arm/README b/Documentation/arm/README index a6f718e90a86..5ed6f3530b86 100644 --- a/Documentation/arm/README +++ b/Documentation/arm/README | |||
@@ -8,10 +8,9 @@ Compilation of kernel | |||
8 | --------------------- | 8 | --------------------- |
9 | 9 | ||
10 | In order to compile ARM Linux, you will need a compiler capable of | 10 | In order to compile ARM Linux, you will need a compiler capable of |
11 | generating ARM ELF code with GNU extensions. GCC 2.95.1, EGCS | 11 | generating ARM ELF code with GNU extensions. GCC 3.3 is known to be |
12 | 1.1.2, and GCC 3.3 are known to be good compilers. Fortunately, you | 12 | a good compiler. Fortunately, you needn't guess. The kernel will report |
13 | needn't guess. The kernel will report an error if your compiler is | 13 | an error if your compiler is a recognized offender. |
14 | a recognized offender. | ||
15 | 14 | ||
16 | To build ARM Linux natively, you shouldn't have to alter the ARCH = line | 15 | To build ARM Linux natively, you shouldn't have to alter the ARCH = line |
17 | in the top level Makefile. However, if you don't have the ARM Linux ELF | 16 | in the top level Makefile. However, if you don't have the ARM Linux ELF |
diff --git a/MAINTAINERS b/MAINTAINERS index f08a1434b217..d57c491212b1 100644 --- a/MAINTAINERS +++ b/MAINTAINERS | |||
@@ -297,6 +297,11 @@ P: Richard Purdie | |||
297 | M: rpurdie@rpsys.net | 297 | M: rpurdie@rpsys.net |
298 | S: Maintained | 298 | S: Maintained |
299 | 299 | ||
300 | ARM/TOSA MACHINE SUPPORT | ||
301 | P: Dirk Opfer | ||
302 | M: dirk@opfer-online.de | ||
303 | S: Maintained | ||
304 | |||
300 | ARM/PLEB SUPPORT | 305 | ARM/PLEB SUPPORT |
301 | P: Peter Chubb | 306 | P: Peter Chubb |
302 | M: pleb@gelato.unsw.edu.au | 307 | M: pleb@gelato.unsw.edu.au |
diff --git a/arch/arm/kernel/entry-armv.S b/arch/arm/kernel/entry-armv.S index be439cab92c6..a511ec5b11a3 100644 --- a/arch/arm/kernel/entry-armv.S +++ b/arch/arm/kernel/entry-armv.S | |||
@@ -785,7 +785,7 @@ __kuser_helper_end: | |||
785 | * SP points to a minimal amount of processor-private memory, the address | 785 | * SP points to a minimal amount of processor-private memory, the address |
786 | * of which is copied into r0 for the mode specific abort handler. | 786 | * of which is copied into r0 for the mode specific abort handler. |
787 | */ | 787 | */ |
788 | .macro vector_stub, name, correction=0 | 788 | .macro vector_stub, name, mode, correction=0 |
789 | .align 5 | 789 | .align 5 |
790 | 790 | ||
791 | vector_\name: | 791 | vector_\name: |
@@ -805,15 +805,14 @@ vector_\name: | |||
805 | @ Prepare for SVC32 mode. IRQs remain disabled. | 805 | @ Prepare for SVC32 mode. IRQs remain disabled. |
806 | @ | 806 | @ |
807 | mrs r0, cpsr | 807 | mrs r0, cpsr |
808 | bic r0, r0, #MODE_MASK | 808 | eor r0, r0, #(\mode ^ SVC_MODE) |
809 | orr r0, r0, #SVC_MODE | ||
810 | msr spsr_cxsf, r0 | 809 | msr spsr_cxsf, r0 |
811 | 810 | ||
812 | @ | 811 | @ |
813 | @ the branch table must immediately follow this code | 812 | @ the branch table must immediately follow this code |
814 | @ | 813 | @ |
815 | mov r0, sp | ||
816 | and lr, lr, #0x0f | 814 | and lr, lr, #0x0f |
815 | mov r0, sp | ||
817 | ldr lr, [pc, lr, lsl #2] | 816 | ldr lr, [pc, lr, lsl #2] |
818 | movs pc, lr @ branch to handler in SVC mode | 817 | movs pc, lr @ branch to handler in SVC mode |
819 | .endm | 818 | .endm |
@@ -823,7 +822,7 @@ __stubs_start: | |||
823 | /* | 822 | /* |
824 | * Interrupt dispatcher | 823 | * Interrupt dispatcher |
825 | */ | 824 | */ |
826 | vector_stub irq, 4 | 825 | vector_stub irq, IRQ_MODE, 4 |
827 | 826 | ||
828 | .long __irq_usr @ 0 (USR_26 / USR_32) | 827 | .long __irq_usr @ 0 (USR_26 / USR_32) |
829 | .long __irq_invalid @ 1 (FIQ_26 / FIQ_32) | 828 | .long __irq_invalid @ 1 (FIQ_26 / FIQ_32) |
@@ -846,7 +845,7 @@ __stubs_start: | |||
846 | * Data abort dispatcher | 845 | * Data abort dispatcher |
847 | * Enter in ABT mode, spsr = USR CPSR, lr = USR PC | 846 | * Enter in ABT mode, spsr = USR CPSR, lr = USR PC |
848 | */ | 847 | */ |
849 | vector_stub dabt, 8 | 848 | vector_stub dabt, ABT_MODE, 8 |
850 | 849 | ||
851 | .long __dabt_usr @ 0 (USR_26 / USR_32) | 850 | .long __dabt_usr @ 0 (USR_26 / USR_32) |
852 | .long __dabt_invalid @ 1 (FIQ_26 / FIQ_32) | 851 | .long __dabt_invalid @ 1 (FIQ_26 / FIQ_32) |
@@ -869,7 +868,7 @@ __stubs_start: | |||
869 | * Prefetch abort dispatcher | 868 | * Prefetch abort dispatcher |
870 | * Enter in ABT mode, spsr = USR CPSR, lr = USR PC | 869 | * Enter in ABT mode, spsr = USR CPSR, lr = USR PC |
871 | */ | 870 | */ |
872 | vector_stub pabt, 4 | 871 | vector_stub pabt, ABT_MODE, 4 |
873 | 872 | ||
874 | .long __pabt_usr @ 0 (USR_26 / USR_32) | 873 | .long __pabt_usr @ 0 (USR_26 / USR_32) |
875 | .long __pabt_invalid @ 1 (FIQ_26 / FIQ_32) | 874 | .long __pabt_invalid @ 1 (FIQ_26 / FIQ_32) |
@@ -892,7 +891,7 @@ __stubs_start: | |||
892 | * Undef instr entry dispatcher | 891 | * Undef instr entry dispatcher |
893 | * Enter in UND mode, spsr = SVC/USR CPSR, lr = SVC/USR PC | 892 | * Enter in UND mode, spsr = SVC/USR CPSR, lr = SVC/USR PC |
894 | */ | 893 | */ |
895 | vector_stub und | 894 | vector_stub und, UND_MODE |
896 | 895 | ||
897 | .long __und_usr @ 0 (USR_26 / USR_32) | 896 | .long __und_usr @ 0 (USR_26 / USR_32) |
898 | .long __und_invalid @ 1 (FIQ_26 / FIQ_32) | 897 | .long __und_invalid @ 1 (FIQ_26 / FIQ_32) |
diff --git a/arch/arm/kernel/setup.c b/arch/arm/kernel/setup.c index c9b69771f92e..85774165e9fd 100644 --- a/arch/arm/kernel/setup.c +++ b/arch/arm/kernel/setup.c | |||
@@ -338,7 +338,8 @@ void cpu_init(void) | |||
338 | BUG(); | 338 | BUG(); |
339 | } | 339 | } |
340 | 340 | ||
341 | dump_cpu_info(cpu); | 341 | if (system_state == SYSTEM_BOOTING) |
342 | dump_cpu_info(cpu); | ||
342 | 343 | ||
343 | /* | 344 | /* |
344 | * setup stacks for re-entrant exception handlers | 345 | * setup stacks for re-entrant exception handlers |
@@ -838,7 +839,12 @@ static int c_show(struct seq_file *m, void *v) | |||
838 | 839 | ||
839 | #if defined(CONFIG_SMP) | 840 | #if defined(CONFIG_SMP) |
840 | for_each_online_cpu(i) { | 841 | for_each_online_cpu(i) { |
841 | seq_printf(m, "Processor\t: %d\n", i); | 842 | /* |
843 | * glibc reads /proc/cpuinfo to determine the number of | ||
844 | * online processors, looking for lines beginning with | ||
845 | * "processor". Give glibc what it expects. | ||
846 | */ | ||
847 | seq_printf(m, "processor\t: %d\n", i); | ||
842 | seq_printf(m, "BogoMIPS\t: %lu.%02lu\n\n", | 848 | seq_printf(m, "BogoMIPS\t: %lu.%02lu\n\n", |
843 | per_cpu(cpu_data, i).loops_per_jiffy / (500000UL/HZ), | 849 | per_cpu(cpu_data, i).loops_per_jiffy / (500000UL/HZ), |
844 | (per_cpu(cpu_data, i).loops_per_jiffy / (5000UL/HZ)) % 100); | 850 | (per_cpu(cpu_data, i).loops_per_jiffy / (5000UL/HZ)) % 100); |
diff --git a/arch/arm/mach-ixp2000/uengine.c b/arch/arm/mach-ixp2000/uengine.c index 43e234349d4a..ec4e007a22ef 100644 --- a/arch/arm/mach-ixp2000/uengine.c +++ b/arch/arm/mach-ixp2000/uengine.c | |||
@@ -91,8 +91,8 @@ EXPORT_SYMBOL(ixp2000_uengine_csr_write); | |||
91 | 91 | ||
92 | void ixp2000_uengine_reset(u32 uengine_mask) | 92 | void ixp2000_uengine_reset(u32 uengine_mask) |
93 | { | 93 | { |
94 | ixp2000_reg_write(IXP2000_RESET1, uengine_mask & ixp2000_uengine_mask); | 94 | ixp2000_reg_wrb(IXP2000_RESET1, uengine_mask & ixp2000_uengine_mask); |
95 | ixp2000_reg_write(IXP2000_RESET1, 0); | 95 | ixp2000_reg_wrb(IXP2000_RESET1, 0); |
96 | } | 96 | } |
97 | EXPORT_SYMBOL(ixp2000_uengine_reset); | 97 | EXPORT_SYMBOL(ixp2000_uengine_reset); |
98 | 98 | ||
@@ -452,21 +452,20 @@ static int __init ixp2000_uengine_init(void) | |||
452 | /* | 452 | /* |
453 | * Reset microengines. | 453 | * Reset microengines. |
454 | */ | 454 | */ |
455 | ixp2000_reg_write(IXP2000_RESET1, ixp2000_uengine_mask); | 455 | ixp2000_uengine_reset(ixp2000_uengine_mask); |
456 | ixp2000_reg_write(IXP2000_RESET1, 0); | ||
457 | 456 | ||
458 | /* | 457 | /* |
459 | * Synchronise timestamp counters across all microengines. | 458 | * Synchronise timestamp counters across all microengines. |
460 | */ | 459 | */ |
461 | value = ixp2000_reg_read(IXP2000_MISC_CONTROL); | 460 | value = ixp2000_reg_read(IXP2000_MISC_CONTROL); |
462 | ixp2000_reg_write(IXP2000_MISC_CONTROL, value & ~0x80); | 461 | ixp2000_reg_wrb(IXP2000_MISC_CONTROL, value & ~0x80); |
463 | for (uengine = 0; uengine < 32; uengine++) { | 462 | for (uengine = 0; uengine < 32; uengine++) { |
464 | if (ixp2000_uengine_mask & (1 << uengine)) { | 463 | if (ixp2000_uengine_mask & (1 << uengine)) { |
465 | ixp2000_uengine_csr_write(uengine, TIMESTAMP_LOW, 0); | 464 | ixp2000_uengine_csr_write(uengine, TIMESTAMP_LOW, 0); |
466 | ixp2000_uengine_csr_write(uengine, TIMESTAMP_HIGH, 0); | 465 | ixp2000_uengine_csr_write(uengine, TIMESTAMP_HIGH, 0); |
467 | } | 466 | } |
468 | } | 467 | } |
469 | ixp2000_reg_write(IXP2000_MISC_CONTROL, value | 0x80); | 468 | ixp2000_reg_wrb(IXP2000_MISC_CONTROL, value | 0x80); |
470 | 469 | ||
471 | return 0; | 470 | return 0; |
472 | } | 471 | } |
diff --git a/arch/arm/mach-ixp4xx/common-pci.c b/arch/arm/mach-ixp4xx/common-pci.c index 2b544363c078..9795da270e3a 100644 --- a/arch/arm/mach-ixp4xx/common-pci.c +++ b/arch/arm/mach-ixp4xx/common-pci.c | |||
@@ -427,7 +427,7 @@ void __init ixp4xx_pci_preinit(void) | |||
427 | #ifdef __ARMEB__ | 427 | #ifdef __ARMEB__ |
428 | *PCI_CSR = PCI_CSR_IC | PCI_CSR_ABE | PCI_CSR_PDS | PCI_CSR_ADS; | 428 | *PCI_CSR = PCI_CSR_IC | PCI_CSR_ABE | PCI_CSR_PDS | PCI_CSR_ADS; |
429 | #else | 429 | #else |
430 | *PCI_CSR = PCI_CSR_IC; | 430 | *PCI_CSR = PCI_CSR_IC | PCI_CSR_ABE; |
431 | #endif | 431 | #endif |
432 | 432 | ||
433 | pr_debug("DONE\n"); | 433 | pr_debug("DONE\n"); |
diff --git a/arch/arm/mach-pxa/Kconfig b/arch/arm/mach-pxa/Kconfig index 3e5f69bb5ac4..b380a438e68f 100644 --- a/arch/arm/mach-pxa/Kconfig +++ b/arch/arm/mach-pxa/Kconfig | |||
@@ -27,7 +27,8 @@ config PXA_SHARPSL | |||
27 | Say Y here if you intend to run this kernel on a | 27 | Say Y here if you intend to run this kernel on a |
28 | Sharp Zaurus SL-5600 (Poodle), SL-C700 (Corgi), | 28 | Sharp Zaurus SL-5600 (Poodle), SL-C700 (Corgi), |
29 | SL-C750 (Shepherd), SL-C760 (Husky), SL-C1000 (Akita), | 29 | SL-C750 (Shepherd), SL-C760 (Husky), SL-C1000 (Akita), |
30 | SL-C3000 (Spitz) or SL-C3100 (Borzoi) handheld computer. | 30 | SL-C3000 (Spitz), SL-C3100 (Borzoi) or SL-C6000x (Tosa) |
31 | handheld computer. | ||
31 | 32 | ||
32 | endchoice | 33 | endchoice |
33 | 34 | ||
@@ -37,7 +38,7 @@ choice | |||
37 | prompt "Select target Sharp Zaurus device range" | 38 | prompt "Select target Sharp Zaurus device range" |
38 | 39 | ||
39 | config PXA_SHARPSL_25x | 40 | config PXA_SHARPSL_25x |
40 | bool "Sharp PXA25x models (SL-5600 and SL-C7xx)" | 41 | bool "Sharp PXA25x models (SL-5600, SL-C7xx and SL-C6000x)" |
41 | select PXA25x | 42 | select PXA25x |
42 | 43 | ||
43 | config PXA_SHARPSL_27x | 44 | config PXA_SHARPSL_27x |
@@ -80,6 +81,10 @@ config MACH_BORZOI | |||
80 | depends PXA_SHARPSL_27x | 81 | depends PXA_SHARPSL_27x |
81 | select PXA_SHARP_Cxx00 | 82 | select PXA_SHARP_Cxx00 |
82 | 83 | ||
84 | config MACH_TOSA | ||
85 | bool "Enable Sharp SL-6000x (Tosa) Support" | ||
86 | depends PXA_SHARPSL | ||
87 | |||
83 | config PXA25x | 88 | config PXA25x |
84 | bool | 89 | bool |
85 | help | 90 | help |
diff --git a/arch/arm/mach-pxa/Makefile b/arch/arm/mach-pxa/Makefile index f609a0f232cb..8bc72d07cea8 100644 --- a/arch/arm/mach-pxa/Makefile +++ b/arch/arm/mach-pxa/Makefile | |||
@@ -14,6 +14,7 @@ obj-$(CONFIG_ARCH_PXA_IDP) += idp.o | |||
14 | obj-$(CONFIG_PXA_SHARP_C7xx) += corgi.o corgi_ssp.o corgi_lcd.o ssp.o | 14 | obj-$(CONFIG_PXA_SHARP_C7xx) += corgi.o corgi_ssp.o corgi_lcd.o ssp.o |
15 | obj-$(CONFIG_PXA_SHARP_Cxx00) += spitz.o corgi_ssp.o corgi_lcd.o ssp.o | 15 | obj-$(CONFIG_PXA_SHARP_Cxx00) += spitz.o corgi_ssp.o corgi_lcd.o ssp.o |
16 | obj-$(CONFIG_MACH_POODLE) += poodle.o | 16 | obj-$(CONFIG_MACH_POODLE) += poodle.o |
17 | obj-$(CONFIG_MACH_TOSA) += tosa.o | ||
17 | 18 | ||
18 | # Support for blinky lights | 19 | # Support for blinky lights |
19 | led-y := leds.o | 20 | led-y := leds.o |
diff --git a/arch/arm/mach-pxa/pm.c b/arch/arm/mach-pxa/pm.c index ac4dd4336160..f74b9af112dc 100644 --- a/arch/arm/mach-pxa/pm.c +++ b/arch/arm/mach-pxa/pm.c | |||
@@ -12,6 +12,7 @@ | |||
12 | */ | 12 | */ |
13 | #include <linux/config.h> | 13 | #include <linux/config.h> |
14 | #include <linux/init.h> | 14 | #include <linux/init.h> |
15 | #include <linux/module.h> | ||
15 | #include <linux/suspend.h> | 16 | #include <linux/suspend.h> |
16 | #include <linux/errno.h> | 17 | #include <linux/errno.h> |
17 | #include <linux/time.h> | 18 | #include <linux/time.h> |
@@ -19,6 +20,7 @@ | |||
19 | #include <asm/hardware.h> | 20 | #include <asm/hardware.h> |
20 | #include <asm/memory.h> | 21 | #include <asm/memory.h> |
21 | #include <asm/system.h> | 22 | #include <asm/system.h> |
23 | #include <asm/arch/pm.h> | ||
22 | #include <asm/arch/pxa-regs.h> | 24 | #include <asm/arch/pxa-regs.h> |
23 | #include <asm/arch/lubbock.h> | 25 | #include <asm/arch/lubbock.h> |
24 | #include <asm/mach/time.h> | 26 | #include <asm/mach/time.h> |
@@ -72,7 +74,7 @@ enum { SLEEP_SAVE_START = 0, | |||
72 | }; | 74 | }; |
73 | 75 | ||
74 | 76 | ||
75 | static int pxa_pm_enter(suspend_state_t state) | 77 | int pxa_pm_enter(suspend_state_t state) |
76 | { | 78 | { |
77 | unsigned long sleep_save[SLEEP_SAVE_SIZE]; | 79 | unsigned long sleep_save[SLEEP_SAVE_SIZE]; |
78 | unsigned long checksum = 0; | 80 | unsigned long checksum = 0; |
@@ -191,6 +193,8 @@ static int pxa_pm_enter(suspend_state_t state) | |||
191 | return 0; | 193 | return 0; |
192 | } | 194 | } |
193 | 195 | ||
196 | EXPORT_SYMBOL_GPL(pxa_pm_enter); | ||
197 | |||
194 | unsigned long sleep_phys_sp(void *sp) | 198 | unsigned long sleep_phys_sp(void *sp) |
195 | { | 199 | { |
196 | return virt_to_phys(sp); | 200 | return virt_to_phys(sp); |
@@ -199,21 +203,25 @@ unsigned long sleep_phys_sp(void *sp) | |||
199 | /* | 203 | /* |
200 | * Called after processes are frozen, but before we shut down devices. | 204 | * Called after processes are frozen, but before we shut down devices. |
201 | */ | 205 | */ |
202 | static int pxa_pm_prepare(suspend_state_t state) | 206 | int pxa_pm_prepare(suspend_state_t state) |
203 | { | 207 | { |
204 | extern int pxa_cpu_pm_prepare(suspend_state_t state); | 208 | extern int pxa_cpu_pm_prepare(suspend_state_t state); |
205 | 209 | ||
206 | return pxa_cpu_pm_prepare(state); | 210 | return pxa_cpu_pm_prepare(state); |
207 | } | 211 | } |
208 | 212 | ||
213 | EXPORT_SYMBOL_GPL(pxa_pm_prepare); | ||
214 | |||
209 | /* | 215 | /* |
210 | * Called after devices are re-setup, but before processes are thawed. | 216 | * Called after devices are re-setup, but before processes are thawed. |
211 | */ | 217 | */ |
212 | static int pxa_pm_finish(suspend_state_t state) | 218 | int pxa_pm_finish(suspend_state_t state) |
213 | { | 219 | { |
214 | return 0; | 220 | return 0; |
215 | } | 221 | } |
216 | 222 | ||
223 | EXPORT_SYMBOL_GPL(pxa_pm_finish); | ||
224 | |||
217 | /* | 225 | /* |
218 | * Set to PM_DISK_FIRMWARE so we can quickly veto suspend-to-disk. | 226 | * Set to PM_DISK_FIRMWARE so we can quickly veto suspend-to-disk. |
219 | */ | 227 | */ |
@@ -230,4 +238,4 @@ static int __init pxa_pm_init(void) | |||
230 | return 0; | 238 | return 0; |
231 | } | 239 | } |
232 | 240 | ||
233 | late_initcall(pxa_pm_init); | 241 | device_initcall(pxa_pm_init); |
diff --git a/arch/arm/mach-pxa/tosa.c b/arch/arm/mach-pxa/tosa.c new file mode 100644 index 000000000000..400609f8b6a8 --- /dev/null +++ b/arch/arm/mach-pxa/tosa.c | |||
@@ -0,0 +1,162 @@ | |||
1 | /* | ||
2 | * Support for Sharp SL-C6000x PDAs | ||
3 | * Model: (Tosa) | ||
4 | * | ||
5 | * Copyright (c) 2005 Dirk Opfer | ||
6 | * | ||
7 | * Based on code written by Sharp/Lineo for 2.4 kernels | ||
8 | * | ||
9 | * This program is free software; you can redistribute it and/or modify | ||
10 | * it under the terms of the GNU General Public License version 2 as | ||
11 | * published by the Free Software Foundation. | ||
12 | * | ||
13 | */ | ||
14 | |||
15 | #include <linux/kernel.h> | ||
16 | #include <linux/init.h> | ||
17 | #include <linux/device.h> | ||
18 | #include <linux/major.h> | ||
19 | #include <linux/fs.h> | ||
20 | #include <linux/interrupt.h> | ||
21 | #include <linux/mmc/host.h> | ||
22 | |||
23 | #include <asm/setup.h> | ||
24 | #include <asm/memory.h> | ||
25 | #include <asm/mach-types.h> | ||
26 | #include <asm/hardware.h> | ||
27 | #include <asm/irq.h> | ||
28 | #include <asm/arch/irda.h> | ||
29 | #include <asm/arch/mmc.h> | ||
30 | #include <asm/arch/udc.h> | ||
31 | |||
32 | #include <asm/mach/arch.h> | ||
33 | #include <asm/mach/map.h> | ||
34 | #include <asm/mach/irq.h> | ||
35 | |||
36 | #include <asm/arch/pxa-regs.h> | ||
37 | #include <asm/arch/irq.h> | ||
38 | #include <asm/arch/tosa.h> | ||
39 | |||
40 | #include <asm/hardware/scoop.h> | ||
41 | #include <asm/mach/sharpsl_param.h> | ||
42 | |||
43 | #include "generic.h" | ||
44 | |||
45 | |||
46 | /* | ||
47 | * SCOOP Device | ||
48 | */ | ||
49 | static struct resource tosa_scoop_resources[] = { | ||
50 | [0] = { | ||
51 | .start = TOSA_CF_PHYS, | ||
52 | .end = TOSA_CF_PHYS + 0xfff, | ||
53 | .flags = IORESOURCE_MEM, | ||
54 | }, | ||
55 | }; | ||
56 | |||
57 | static struct scoop_config tosa_scoop_setup = { | ||
58 | .io_dir = TOSA_SCOOP_IO_DIR, | ||
59 | .io_out = TOSA_SCOOP_IO_OUT, | ||
60 | |||
61 | }; | ||
62 | |||
63 | struct platform_device tosascoop_device = { | ||
64 | .name = "sharp-scoop", | ||
65 | .id = 0, | ||
66 | .dev = { | ||
67 | .platform_data = &tosa_scoop_setup, | ||
68 | }, | ||
69 | .num_resources = ARRAY_SIZE(tosa_scoop_resources), | ||
70 | .resource = tosa_scoop_resources, | ||
71 | }; | ||
72 | |||
73 | |||
74 | /* | ||
75 | * SCOOP Device Jacket | ||
76 | */ | ||
77 | static struct resource tosa_scoop_jc_resources[] = { | ||
78 | [0] = { | ||
79 | .start = TOSA_SCOOP_PHYS + 0x40, | ||
80 | .end = TOSA_SCOOP_PHYS + 0xfff, | ||
81 | .flags = IORESOURCE_MEM, | ||
82 | }, | ||
83 | }; | ||
84 | |||
85 | static struct scoop_config tosa_scoop_jc_setup = { | ||
86 | .io_dir = TOSA_SCOOP_JC_IO_DIR, | ||
87 | .io_out = TOSA_SCOOP_JC_IO_OUT, | ||
88 | }; | ||
89 | |||
90 | struct platform_device tosascoop_jc_device = { | ||
91 | .name = "sharp-scoop", | ||
92 | .id = 1, | ||
93 | .dev = { | ||
94 | .platform_data = &tosa_scoop_jc_setup, | ||
95 | .parent = &tosascoop_device.dev, | ||
96 | }, | ||
97 | .num_resources = ARRAY_SIZE(tosa_scoop_jc_resources), | ||
98 | .resource = tosa_scoop_jc_resources, | ||
99 | }; | ||
100 | |||
101 | static struct scoop_pcmcia_dev tosa_pcmcia_scoop[] = { | ||
102 | { | ||
103 | .dev = &tosascoop_device.dev, | ||
104 | .irq = TOSA_IRQ_GPIO_CF_IRQ, | ||
105 | .cd_irq = TOSA_IRQ_GPIO_CF_CD, | ||
106 | .cd_irq_str = "PCMCIA0 CD", | ||
107 | },{ | ||
108 | .dev = &tosascoop_jc_device.dev, | ||
109 | .irq = TOSA_IRQ_GPIO_JC_CF_IRQ, | ||
110 | .cd_irq = -1, | ||
111 | }, | ||
112 | }; | ||
113 | |||
114 | |||
115 | static struct platform_device *devices[] __initdata = { | ||
116 | &tosascoop_device, | ||
117 | &tosascoop_jc_device, | ||
118 | }; | ||
119 | |||
120 | static void __init tosa_init(void) | ||
121 | { | ||
122 | pxa_gpio_mode(TOSA_GPIO_ON_RESET | GPIO_IN); | ||
123 | pxa_gpio_mode(TOSA_GPIO_TC6393_INT | GPIO_IN); | ||
124 | |||
125 | /* setup sleep mode values */ | ||
126 | PWER = 0x00000002; | ||
127 | PFER = 0x00000000; | ||
128 | PRER = 0x00000002; | ||
129 | PGSR0 = 0x00000000; | ||
130 | PGSR1 = 0x00FF0002; | ||
131 | PGSR2 = 0x00014000; | ||
132 | PCFR |= PCFR_OPDE; | ||
133 | |||
134 | // enable batt_fault | ||
135 | PMCR = 0x01; | ||
136 | |||
137 | platform_add_devices(devices, ARRAY_SIZE(devices)); | ||
138 | |||
139 | scoop_num = 2; | ||
140 | scoop_devs = &tosa_pcmcia_scoop[0]; | ||
141 | } | ||
142 | |||
143 | static void __init fixup_tosa(struct machine_desc *desc, | ||
144 | struct tag *tags, char **cmdline, struct meminfo *mi) | ||
145 | { | ||
146 | sharpsl_save_param(); | ||
147 | mi->nr_banks=1; | ||
148 | mi->bank[0].start = 0xa0000000; | ||
149 | mi->bank[0].node = 0; | ||
150 | mi->bank[0].size = (64*1024*1024); | ||
151 | } | ||
152 | |||
153 | MACHINE_START(TOSA, "SHARP Tosa") | ||
154 | .phys_ram = 0xa0000000, | ||
155 | .phys_io = 0x40000000, | ||
156 | .io_pg_offst = (io_p2v(0x40000000) >> 18) & 0xfffc, | ||
157 | .fixup = fixup_tosa, | ||
158 | .map_io = pxa_map_io, | ||
159 | .init_irq = pxa_init_irq, | ||
160 | .init_machine = tosa_init, | ||
161 | .timer = &pxa_timer, | ||
162 | MACHINE_END | ||
diff --git a/include/asm-arm/arch-iop3xx/iop331.h b/include/asm-arm/arch-iop3xx/iop331.h index 96adffd8bad2..fbf0cc11bdd9 100644 --- a/include/asm-arm/arch-iop3xx/iop331.h +++ b/include/asm-arm/arch-iop3xx/iop331.h | |||
@@ -42,7 +42,7 @@ | |||
42 | 42 | ||
43 | /* this can be 128M if OMWTVR1 is set */ | 43 | /* this can be 128M if OMWTVR1 is set */ |
44 | #define IOP331_PCI_MEM_WINDOW_SIZE 0x04000000 /* 64M outbound window */ | 44 | #define IOP331_PCI_MEM_WINDOW_SIZE 0x04000000 /* 64M outbound window */ |
45 | //#define IOP331_PCI_MEM_WINDOW_SIZE (~*IOP331_IALR1 + 1) | 45 | /* #define IOP331_PCI_MEM_WINDOW_SIZE (~*IOP331_IALR1 + 1) */ |
46 | #define IOP331_PCI_LOWER_MEM_PA 0x80000000 | 46 | #define IOP331_PCI_LOWER_MEM_PA 0x80000000 |
47 | #define IOP331_PCI_LOWER_MEM_BA (*IOP331_OMWTVR0) | 47 | #define IOP331_PCI_LOWER_MEM_BA (*IOP331_OMWTVR0) |
48 | #define IOP331_PCI_UPPER_MEM_PA (IOP331_PCI_LOWER_MEM_PA + IOP331_PCI_MEM_WINDOW_SIZE - 1) | 48 | #define IOP331_PCI_UPPER_MEM_PA (IOP331_PCI_LOWER_MEM_PA + IOP331_PCI_MEM_WINDOW_SIZE - 1) |
diff --git a/include/asm-arm/arch-pxa/pm.h b/include/asm-arm/arch-pxa/pm.h new file mode 100644 index 000000000000..7a8a1cdf430d --- /dev/null +++ b/include/asm-arm/arch-pxa/pm.h | |||
@@ -0,0 +1,12 @@ | |||
1 | /* | ||
2 | * Copyright (c) 2005 Richard Purdie | ||
3 | * | ||
4 | * This program is free software; you can redistribute it and/or modify | ||
5 | * it under the terms of the GNU General Public License version 2 as | ||
6 | * published by the Free Software Foundation. | ||
7 | * | ||
8 | */ | ||
9 | |||
10 | extern int pxa_pm_prepare(suspend_state_t state); | ||
11 | extern int pxa_pm_enter(suspend_state_t state); | ||
12 | extern int pxa_pm_finish(suspend_state_t state); | ||
diff --git a/include/asm-arm/arch-pxa/tosa.h b/include/asm-arm/arch-pxa/tosa.h new file mode 100644 index 000000000000..c3364a2c4758 --- /dev/null +++ b/include/asm-arm/arch-pxa/tosa.h | |||
@@ -0,0 +1,166 @@ | |||
1 | /* | ||
2 | * Hardware specific definitions for Sharp SL-C6000x series of PDAs | ||
3 | * | ||
4 | * Copyright (c) 2005 Dirk Opfer | ||
5 | * | ||
6 | * Based on Sharp's 2.4 kernel patches | ||
7 | * | ||
8 | * This program is free software; you can redistribute it and/or modify | ||
9 | * it under the terms of the GNU General Public License version 2 as | ||
10 | * published by the Free Software Foundation. | ||
11 | * | ||
12 | */ | ||
13 | #ifndef _ASM_ARCH_TOSA_H_ | ||
14 | #define _ASM_ARCH_TOSA_H_ 1 | ||
15 | |||
16 | /* TOSA Chip selects */ | ||
17 | #define TOSA_LCDC_PHYS PXA_CS4_PHYS | ||
18 | /* Internel Scoop */ | ||
19 | #define TOSA_CF_PHYS (PXA_CS2_PHYS + 0x00800000) | ||
20 | /* Jacket Scoop */ | ||
21 | #define TOSA_SCOOP_PHYS (PXA_CS5_PHYS + 0x00800000) | ||
22 | |||
23 | /* | ||
24 | * SCOOP2 internal GPIOs | ||
25 | */ | ||
26 | #define TOSA_SCOOP_PXA_VCORE1 SCOOP_GPCR_PA11 | ||
27 | #define TOSA_SCOOP_TC6393_REST_IN SCOOP_GPCR_PA12 | ||
28 | #define TOSA_SCOOP_IR_POWERDWN SCOOP_GPCR_PA13 | ||
29 | #define TOSA_SCOOP_SD_WP SCOOP_GPCR_PA14 | ||
30 | #define TOSA_SCOOP_PWR_ON SCOOP_GPCR_PA15 | ||
31 | #define TOSA_SCOOP_AUD_PWR_ON SCOOP_GPCR_PA16 | ||
32 | #define TOSA_SCOOP_BT_RESET SCOOP_GPCR_PA17 | ||
33 | #define TOSA_SCOOP_BT_PWR_EN SCOOP_GPCR_PA18 | ||
34 | #define TOSA_SCOOP_AC_IN_OL SCOOP_GPCR_PA19 | ||
35 | |||
36 | /* GPIO Direction 1 : output mode / 0:input mode */ | ||
37 | #define TOSA_SCOOP_IO_DIR ( TOSA_SCOOP_PXA_VCORE1 | TOSA_SCOOP_TC6393_REST_IN | \ | ||
38 | TOSA_SCOOP_IR_POWERDWN | TOSA_SCOOP_PWR_ON | TOSA_SCOOP_AUD_PWR_ON |\ | ||
39 | TOSA_SCOOP_BT_RESET | TOSA_SCOOP_BT_PWR_EN ) | ||
40 | /* GPIO out put level when init 1: Hi */ | ||
41 | #define TOSA_SCOOP_IO_OUT ( TOSA_SCOOP_TC6393_REST_IN ) | ||
42 | |||
43 | /* | ||
44 | * SCOOP2 jacket GPIOs | ||
45 | */ | ||
46 | #define TOSA_SCOOP_JC_BT_LED SCOOP_GPCR_PA11 | ||
47 | #define TOSA_SCOOP_JC_NOTE_LED SCOOP_GPCR_PA12 | ||
48 | #define TOSA_SCOOP_JC_CHRG_ERR_LED SCOOP_GPCR_PA13 | ||
49 | #define TOSA_SCOOP_JC_USB_PULLUP SCOOP_GPCR_PA14 | ||
50 | #define TOSA_SCOOP_JC_TC6393_SUSPEND SCOOP_GPCR_PA15 | ||
51 | #define TOSA_SCOOP_JC_TC3693_L3V_ON SCOOP_GPCR_PA16 | ||
52 | #define TOSA_SCOOP_JC_WLAN_DETECT SCOOP_GPCR_PA17 | ||
53 | #define TOSA_SCOOP_JC_WLAN_LED SCOOP_GPCR_PA18 | ||
54 | #define TOSA_SCOOP_JC_CARD_LIMIT_SEL SCOOP_GPCR_PA19 | ||
55 | |||
56 | /* GPIO Direction 1 : output mode / 0:input mode */ | ||
57 | #define TOSA_SCOOP_JC_IO_DIR ( TOSA_SCOOP_JC_BT_LED | TOSA_SCOOP_JC_NOTE_LED | \ | ||
58 | TOSA_SCOOP_JC_CHRG_ERR_LED | TOSA_SCOOP_JC_USB_PULLUP | \ | ||
59 | TOSA_SCOOP_JC_TC6393_SUSPEND | TOSA_SCOOP_JC_TC3693_L3V_ON | \ | ||
60 | TOSA_SCOOP_JC_WLAN_LED | TOSA_SCOOP_JC_CARD_LIMIT_SEL ) | ||
61 | /* GPIO out put level when init 1: Hi */ | ||
62 | #define TOSA_SCOOP_JC_IO_OUT ( 0 ) | ||
63 | |||
64 | /* | ||
65 | * Timing Generator | ||
66 | */ | ||
67 | #define TG_PNLCTL 0x00 | ||
68 | #define TG_TPOSCTL 0x01 | ||
69 | #define TG_DUTYCTL 0x02 | ||
70 | #define TG_GPOSR 0x03 | ||
71 | #define TG_GPODR1 0x04 | ||
72 | #define TG_GPODR2 0x05 | ||
73 | #define TG_PINICTL 0x06 | ||
74 | #define TG_HPOSCTL 0x07 | ||
75 | |||
76 | /* | ||
77 | * LED | ||
78 | */ | ||
79 | #define TOSA_SCOOP_LED_BLUE TOSA_SCOOP_GPCR_PA11 | ||
80 | #define TOSA_SCOOP_LED_GREEN TOSA_SCOOP_GPCR_PA12 | ||
81 | #define TOSA_SCOOP_LED_ORANGE TOSA_SCOOP_GPCR_PA13 | ||
82 | #define TOSA_SCOOP_LED_WLAN TOSA_SCOOP_GPCR_PA18 | ||
83 | |||
84 | |||
85 | /* | ||
86 | * PXA GPIOs | ||
87 | */ | ||
88 | #define TOSA_GPIO_POWERON (0) | ||
89 | #define TOSA_GPIO_RESET (1) | ||
90 | #define TOSA_GPIO_AC_IN (2) | ||
91 | #define TOSA_GPIO_RECORD_BTN (3) | ||
92 | #define TOSA_GPIO_SYNC (4) /* Cradle SYNC Button */ | ||
93 | #define TOSA_GPIO_USB_IN (5) | ||
94 | #define TOSA_GPIO_JACKET_DETECT (7) | ||
95 | #define TOSA_GPIO_nSD_DETECT (9) | ||
96 | #define TOSA_GPIO_nSD_INT (10) | ||
97 | #define TOSA_GPIO_TC6393_CLK (11) | ||
98 | #define TOSA_GPIO_BAT1_CRG (12) | ||
99 | #define TOSA_GPIO_CF_CD (13) | ||
100 | #define TOSA_GPIO_BAT0_CRG (14) | ||
101 | #define TOSA_GPIO_TC6393_INT (15) | ||
102 | #define TOSA_GPIO_BAT0_LOW (17) | ||
103 | #define TOSA_GPIO_TC6393_RDY (18) | ||
104 | #define TOSA_GPIO_ON_RESET (19) | ||
105 | #define TOSA_GPIO_EAR_IN (20) | ||
106 | #define TOSA_GPIO_CF_IRQ (21) /* CF slot0 Ready */ | ||
107 | #define TOSA_GPIO_ON_KEY (22) | ||
108 | #define TOSA_GPIO_VGA_LINE (27) | ||
109 | #define TOSA_GPIO_TP_INT (32) /* Touch Panel pen down interrupt */ | ||
110 | #define TOSA_GPIO_JC_CF_IRQ (36) /* CF slot1 Ready */ | ||
111 | #define TOSA_GPIO_BAT_LOCKED (38) /* Battery locked */ | ||
112 | #define TOSA_GPIO_TG_SPI_SCLK (81) | ||
113 | #define TOSA_GPIO_TG_SPI_CS (82) | ||
114 | #define TOSA_GPIO_TG_SPI_MOSI (83) | ||
115 | #define TOSA_GPIO_BAT1_LOW (84) | ||
116 | |||
117 | #define TOSA_GPIO_HP_IN GPIO_EAR_IN | ||
118 | |||
119 | #define TOSA_GPIO_MAIN_BAT_LOW GPIO_BAT0_LOW | ||
120 | |||
121 | #define TOSA_KEY_STROBE_NUM (11) | ||
122 | #define TOSA_KEY_SENSE_NUM (7) | ||
123 | |||
124 | #define TOSA_GPIO_HIGH_STROBE_BIT (0xfc000000) | ||
125 | #define TOSA_GPIO_LOW_STROBE_BIT (0x0000001f) | ||
126 | #define TOSA_GPIO_ALL_SENSE_BIT (0x00000fe0) | ||
127 | #define TOSA_GPIO_ALL_SENSE_RSHIFT (5) | ||
128 | #define TOSA_GPIO_STROBE_BIT(a) GPIO_bit(58+(a)) | ||
129 | #define TOSA_GPIO_SENSE_BIT(a) GPIO_bit(69+(a)) | ||
130 | #define TOSA_GAFR_HIGH_STROBE_BIT (0xfff00000) | ||
131 | #define TOSA_GAFR_LOW_STROBE_BIT (0x000003ff) | ||
132 | #define TOSA_GAFR_ALL_SENSE_BIT (0x00fffc00) | ||
133 | #define TOSA_GPIO_KEY_SENSE(a) (69+(a)) | ||
134 | #define TOSA_GPIO_KEY_STROBE(a) (58+(a)) | ||
135 | |||
136 | /* | ||
137 | * Interrupts | ||
138 | */ | ||
139 | #define TOSA_IRQ_GPIO_WAKEUP IRQ_GPIO(TOSA_GPIO_WAKEUP) | ||
140 | #define TOSA_IRQ_GPIO_AC_IN IRQ_GPIO(TOSA_GPIO_AC_IN) | ||
141 | #define TOSA_IRQ_GPIO_RECORD_BTN IRQ_GPIO(TOSA_GPIO_RECORD_BTN) | ||
142 | #define TOSA_IRQ_GPIO_SYNC IRQ_GPIO(TOSA_GPIO_SYNC) | ||
143 | #define TOSA_IRQ_GPIO_USB_IN IRQ_GPIO(TOSA_GPIO_USB_IN) | ||
144 | #define TOSA_IRQ_GPIO_JACKET_DETECT IRQ_GPIO(TOSA_GPIO_JACKET_DETECT) | ||
145 | #define TOSA_IRQ_GPIO_nSD_INT IRQ_GPIO(TOSA_GPIO_nSD_INT) | ||
146 | #define TOSA_IRQ_GPIO_nSD_DETECT IRQ_GPIO(TOSA_GPIO_nSD_DETECT) | ||
147 | #define TOSA_IRQ_GPIO_BAT1_CRG IRQ_GPIO(TOSA_GPIO_BAT1_CRG) | ||
148 | #define TOSA_IRQ_GPIO_CF_CD IRQ_GPIO(TOSA_GPIO_CF_CD) | ||
149 | #define TOSA_IRQ_GPIO_BAT0_CRG IRQ_GPIO(TOSA_GPIO_BAT0_CRG) | ||
150 | #define TOSA_IRQ_GPIO_TC6393_INT IRQ_GPIO(TOSA_GPIO_TC6393_INT) | ||
151 | #define TOSA_IRQ_GPIO_BAT0_LOW IRQ_GPIO(TOSA_GPIO_BAT0_LOW) | ||
152 | #define TOSA_IRQ_GPIO_EAR_IN IRQ_GPIO(TOSA_GPIO_EAR_IN) | ||
153 | #define TOSA_IRQ_GPIO_CF_IRQ IRQ_GPIO(TOSA_GPIO_CF_IRQ) | ||
154 | #define TOSA_IRQ_GPIO_ON_KEY IRQ_GPIO(TOSA_GPIO_ON_KEY) | ||
155 | #define TOSA_IRQ_GPIO_VGA_LINE IRQ_GPIO(TOSA_GPIO_VGA_LINE) | ||
156 | #define TOSA_IRQ_GPIO_TP_INT IRQ_GPIO(TOSA_GPIO_TP_INT) | ||
157 | #define TOSA_IRQ_GPIO_JC_CF_IRQ IRQ_GPIO(TOSA_GPIO_JC_CF_IRQ) | ||
158 | #define TOSA_IRQ_GPIO_BAT_LOCKED IRQ_GPIO(TOSA_GPIO_BAT_LOCKED) | ||
159 | #define TOSA_IRQ_GPIO_BAT1_LOW IRQ_GPIO(TOSA_GPIO_BAT1_LOW) | ||
160 | #define TOSA_IRQ_GPIO_KEY_SENSE(a) IRQ_GPIO(69+(a)) | ||
161 | |||
162 | #define TOSA_IRQ_GPIO_MAIN_BAT_LOW IRQ_GPIO(TOSA_GPIO_MAIN_BAT_LOW) | ||
163 | |||
164 | extern struct platform_device tosascoop_jc_device; | ||
165 | extern struct platform_device tosascoop_device; | ||
166 | #endif /* _ASM_ARCH_TOSA_H_ */ | ||
diff --git a/include/asm-arm/mmu_context.h b/include/asm-arm/mmu_context.h index 57b8def83d41..3d4b810d8c38 100644 --- a/include/asm-arm/mmu_context.h +++ b/include/asm-arm/mmu_context.h | |||
@@ -13,6 +13,7 @@ | |||
13 | #ifndef __ASM_ARM_MMU_CONTEXT_H | 13 | #ifndef __ASM_ARM_MMU_CONTEXT_H |
14 | #define __ASM_ARM_MMU_CONTEXT_H | 14 | #define __ASM_ARM_MMU_CONTEXT_H |
15 | 15 | ||
16 | #include <asm/cacheflush.h> | ||
16 | #include <asm/proc-fns.h> | 17 | #include <asm/proc-fns.h> |
17 | 18 | ||
18 | #if __LINUX_ARM_ARCH__ >= 6 | 19 | #if __LINUX_ARM_ARCH__ >= 6 |