diff options
author | Linus Torvalds <torvalds@woody.osdl.org> | 2006-12-12 11:14:46 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.osdl.org> | 2006-12-12 11:14:46 -0500 |
commit | d224a93d91610fc641fbc5b234b32fcb84045a30 (patch) | |
tree | f908bcf0c0c1c73dabfd00a134895cfb33aa9a5d | |
parent | b57bd06655a028aba7b92e1c19c2093e7fcfb341 (diff) | |
parent | e9cfc147df99790a7d260e9d20b865fa31ec56da (diff) |
Merge master.kernel.org:/pub/scm/linux/kernel/git/lethal/sh-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/lethal/sh-2.6: (29 commits)
sh: Fixup SH-2 BUG() trap handling.
sh: Use early_param() for earlyprintk parsing.
sh: Fix .empty_zero_page alignment for PAGE_SIZE > 4096.
sh: Fixup .data.page_aligned.
sh: Hook up SH7722 scif ipr interrupts.
sh: Fixup sh_bios() trap handling.
sh: SH-MobileR SH7722 CPU support.
sh: Fixup dma_cache_sync() callers.
sh: Convert remaining remap_area_pages() users to ioremap_page_range().
sh: Fixup kernel_execve() for syscall cleanups.
sh: Fix get_wchan().
sh: BUG() handling through trapa vector.
rtc: rtc-sh: alarm support.
rtc: rtc-sh: fix rtc for out-by-one for the month.
sh: Kill off unused SE7619 I/O ops.
serial: sh-sci: Shut up various sci_rxd_in() gcc4 warnings.
sh: Split out atomic ops logically.
sh: Fix Solution Engine 7619 build.
sh: Trivial build fixes for SH-2 support.
sh: IPR IRQ updates for SH7619/SH7206.
...
63 files changed, 2038 insertions, 557 deletions
diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig index 8e24c40662e3..3aa3b885ab36 100644 --- a/arch/sh/Kconfig +++ b/arch/sh/Kconfig | |||
@@ -479,7 +479,7 @@ config SH_CLK_MD | |||
479 | int "CPU Mode Pin Setting" | 479 | int "CPU Mode Pin Setting" |
480 | depends on CPU_SUBTYPE_SH7619 || CPU_SUBTYPE_SH7206 | 480 | depends on CPU_SUBTYPE_SH7619 || CPU_SUBTYPE_SH7206 |
481 | help | 481 | help |
482 | MD2 - MD0 Setting. | 482 | MD2 - MD0 pin setting. |
483 | 483 | ||
484 | menu "CPU Frequency scaling" | 484 | menu "CPU Frequency scaling" |
485 | 485 | ||
@@ -580,18 +580,6 @@ config NR_CPUS | |||
580 | 580 | ||
581 | source "kernel/Kconfig.preempt" | 581 | source "kernel/Kconfig.preempt" |
582 | 582 | ||
583 | config CPU_HAS_SR_RB | ||
584 | bool "CPU has SR.RB" | ||
585 | depends on CPU_SH3 || CPU_SH4 | ||
586 | default y | ||
587 | help | ||
588 | This will enable the use of SR.RB register bank usage. Processors | ||
589 | that are lacking this bit must have another method in place for | ||
590 | accomplishing what is taken care of by the banked registers. | ||
591 | |||
592 | See <file:Documentation/sh/register-banks.txt> for further | ||
593 | information on SR.RB and register banking in the kernel in general. | ||
594 | |||
595 | config NODES_SHIFT | 583 | config NODES_SHIFT |
596 | int | 584 | int |
597 | default "1" | 585 | default "1" |
diff --git a/arch/sh/Kconfig.debug b/arch/sh/Kconfig.debug index 66a25ef4ef1b..87902e0298e2 100644 --- a/arch/sh/Kconfig.debug +++ b/arch/sh/Kconfig.debug | |||
@@ -31,7 +31,8 @@ config EARLY_SCIF_CONSOLE_PORT | |||
31 | hex "SCIF port for early console" | 31 | hex "SCIF port for early console" |
32 | depends on EARLY_SCIF_CONSOLE | 32 | depends on EARLY_SCIF_CONSOLE |
33 | default "0xffe00000" if CPU_SUBTYPE_SH7780 | 33 | default "0xffe00000" if CPU_SUBTYPE_SH7780 |
34 | default "0xfffe9800" if CPU_SUBTYPE_SH72060 | 34 | default "0xfffe9800" if CPU_SUBTYPE_SH7206 |
35 | default "0xf8420000" if CPU_SUBTYPE_SH7619 | ||
35 | default "0xffe80000" if CPU_SH4 | 36 | default "0xffe80000" if CPU_SH4 |
36 | 37 | ||
37 | config EARLY_PRINTK | 38 | config EARLY_PRINTK |
diff --git a/arch/sh/Makefile b/arch/sh/Makefile index d10bba5e1074..c1dbef212634 100644 --- a/arch/sh/Makefile +++ b/arch/sh/Makefile | |||
@@ -179,7 +179,7 @@ maketools: include/linux/version.h FORCE | |||
179 | 179 | ||
180 | all: zImage | 180 | all: zImage |
181 | 181 | ||
182 | zImage: vmlinux | 182 | zImage uImage uImage.srec vmlinux.srec: vmlinux |
183 | $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ | 183 | $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ |
184 | 184 | ||
185 | compressed: zImage | 185 | compressed: zImage |
@@ -190,5 +190,8 @@ archclean: | |||
190 | CLEAN_FILES += include/asm-sh/machtypes.h | 190 | CLEAN_FILES += include/asm-sh/machtypes.h |
191 | 191 | ||
192 | define archhelp | 192 | define archhelp |
193 | @echo ' zImage - Compressed kernel image (arch/sh/boot/zImage)' | 193 | @echo '* zImage - Compressed kernel image' |
194 | @echo ' vmlinux.srec - Create an ELF S-record' | ||
195 | @echo ' uImage - Create a bootable image for U-Boot' | ||
196 | @echo ' uImage.srec - Create an S-record for U-Boot' | ||
194 | endef | 197 | endef |
diff --git a/arch/sh/boards/landisk/irq.c b/arch/sh/boards/landisk/irq.c index 8f2e1c68b90f..3eba6d086d7f 100644 --- a/arch/sh/boards/landisk/irq.c +++ b/arch/sh/boards/landisk/irq.c | |||
@@ -16,8 +16,8 @@ | |||
16 | */ | 16 | */ |
17 | #include <linux/init.h> | 17 | #include <linux/init.h> |
18 | #include <linux/irq.h> | 18 | #include <linux/irq.h> |
19 | #include <asm/io.h> | 19 | #include <linux/interrupt.h> |
20 | #include <asm/irq.h> | 20 | #include <linux/io.h> |
21 | #include <asm/landisk/iodata_landisk.h> | 21 | #include <asm/landisk/iodata_landisk.h> |
22 | 22 | ||
23 | static void enable_landisk_irq(unsigned int irq); | 23 | static void enable_landisk_irq(unsigned int irq); |
diff --git a/arch/sh/boards/se/7206/irq.c b/arch/sh/boards/se/7206/irq.c index 3fb0c5f5b23a..27da88486f73 100644 --- a/arch/sh/boards/se/7206/irq.c +++ b/arch/sh/boards/se/7206/irq.c | |||
@@ -10,6 +10,7 @@ | |||
10 | #include <linux/irq.h> | 10 | #include <linux/irq.h> |
11 | #include <linux/io.h> | 11 | #include <linux/io.h> |
12 | #include <linux/irq.h> | 12 | #include <linux/irq.h> |
13 | #include <linux/interrupt.h> | ||
13 | #include <asm/se7206.h> | 14 | #include <asm/se7206.h> |
14 | 15 | ||
15 | #define INTSTS0 0x31800000 | 16 | #define INTSTS0 0x31800000 |
@@ -18,6 +19,13 @@ | |||
18 | #define INTMSK1 0x31800006 | 19 | #define INTMSK1 0x31800006 |
19 | #define INTSEL 0x31800008 | 20 | #define INTSEL 0x31800008 |
20 | 21 | ||
22 | #define IRQ0_IRQ 64 | ||
23 | #define IRQ1_IRQ 65 | ||
24 | #define IRQ3_IRQ 67 | ||
25 | |||
26 | #define INTC_IPR01 0xfffe0818 | ||
27 | #define INTC_ICR1 0xfffe0802 | ||
28 | |||
21 | static void disable_se7206_irq(unsigned int irq) | 29 | static void disable_se7206_irq(unsigned int irq) |
22 | { | 30 | { |
23 | unsigned short val; | 31 | unsigned short val; |
@@ -39,7 +47,7 @@ static void disable_se7206_irq(unsigned int irq) | |||
39 | case IRQ1_IRQ: | 47 | case IRQ1_IRQ: |
40 | msk0 |= 0x000f; | 48 | msk0 |= 0x000f; |
41 | break; | 49 | break; |
42 | case IRQ2_IRQ: | 50 | case IRQ3_IRQ: |
43 | msk0 |= 0x0f00; | 51 | msk0 |= 0x0f00; |
44 | msk1 |= 0x00ff; | 52 | msk1 |= 0x00ff; |
45 | break; | 53 | break; |
@@ -70,7 +78,7 @@ static void enable_se7206_irq(unsigned int irq) | |||
70 | case IRQ1_IRQ: | 78 | case IRQ1_IRQ: |
71 | msk0 &= ~0x000f; | 79 | msk0 &= ~0x000f; |
72 | break; | 80 | break; |
73 | case IRQ2_IRQ: | 81 | case IRQ3_IRQ: |
74 | msk0 &= ~0x0f00; | 82 | msk0 &= ~0x0f00; |
75 | msk1 &= ~0x00ff; | 83 | msk1 &= ~0x00ff; |
76 | break; | 84 | break; |
@@ -96,7 +104,7 @@ static void eoi_se7206_irq(unsigned int irq) | |||
96 | case IRQ1_IRQ: | 104 | case IRQ1_IRQ: |
97 | sts0 &= ~0x000f; | 105 | sts0 &= ~0x000f; |
98 | break; | 106 | break; |
99 | case IRQ2_IRQ: | 107 | case IRQ3_IRQ: |
100 | sts0 &= ~0x0f00; | 108 | sts0 &= ~0x0f00; |
101 | sts1 &= ~0x00ff; | 109 | sts1 &= ~0x00ff; |
102 | break; | 110 | break; |
@@ -106,7 +114,7 @@ static void eoi_se7206_irq(unsigned int irq) | |||
106 | } | 114 | } |
107 | 115 | ||
108 | static struct irq_chip se7206_irq_chip __read_mostly = { | 116 | static struct irq_chip se7206_irq_chip __read_mostly = { |
109 | .name = "SE7206-FPGA-IRQ", | 117 | .name = "SE7206-FPGA", |
110 | .mask = disable_se7206_irq, | 118 | .mask = disable_se7206_irq, |
111 | .unmask = enable_se7206_irq, | 119 | .unmask = enable_se7206_irq, |
112 | .mask_ack = disable_se7206_irq, | 120 | .mask_ack = disable_se7206_irq, |
diff --git a/arch/sh/boards/se/7619/Makefile b/arch/sh/boards/se/7619/Makefile index 3666eca8a658..d21775c28cda 100644 --- a/arch/sh/boards/se/7619/Makefile +++ b/arch/sh/boards/se/7619/Makefile | |||
@@ -2,4 +2,4 @@ | |||
2 | # Makefile for the 7619 SolutionEngine specific parts of the kernel | 2 | # Makefile for the 7619 SolutionEngine specific parts of the kernel |
3 | # | 3 | # |
4 | 4 | ||
5 | obj-y := setup.o io.o | 5 | obj-y := setup.o |
diff --git a/arch/sh/boards/se/7619/io.c b/arch/sh/boards/se/7619/io.c deleted file mode 100644 index 176f1f39cd9d..000000000000 --- a/arch/sh/boards/se/7619/io.c +++ /dev/null | |||
@@ -1,102 +0,0 @@ | |||
1 | /* | ||
2 | * | ||
3 | * linux/arch/sh/boards/se/7619/io.c | ||
4 | * | ||
5 | * Copyright (C) 2006 Yoshinori Sato | ||
6 | * | ||
7 | * I/O routine for Hitachi 7619 SolutionEngine. | ||
8 | * | ||
9 | */ | ||
10 | |||
11 | #include <linux/kernel.h> | ||
12 | #include <linux/types.h> | ||
13 | #include <asm/io.h> | ||
14 | #include <asm/se7619.h> | ||
15 | #include <asm/irq.h> | ||
16 | |||
17 | /* FIXME: M3A-ZAB7 Compact Flash Slot support */ | ||
18 | |||
19 | static inline void delay(void) | ||
20 | { | ||
21 | ctrl_inw(0xa0000000); /* Uncached ROM area (P2) */ | ||
22 | } | ||
23 | |||
24 | #define badio(name,port) \ | ||
25 | printk("bad I/O operation (%s) for port 0x%lx at 0x%08x\n", \ | ||
26 | #name, (port), (__u32) __builtin_return_address(0)) | ||
27 | |||
28 | unsigned char se7619___inb(unsigned long port) | ||
29 | { | ||
30 | badio(inb, port); | ||
31 | return 0; | ||
32 | } | ||
33 | |||
34 | unsigned char se7619___inb_p(unsigned long port) | ||
35 | { | ||
36 | badio(inb_p, port); | ||
37 | delay(); | ||
38 | return 0; | ||
39 | } | ||
40 | |||
41 | unsigned short se7619___inw(unsigned long port) | ||
42 | { | ||
43 | badio(inw, port); | ||
44 | return 0; | ||
45 | } | ||
46 | |||
47 | unsigned int se7619___inl(unsigned long port) | ||
48 | { | ||
49 | badio(inl, port); | ||
50 | return 0; | ||
51 | } | ||
52 | |||
53 | void se7619___outb(unsigned char value, unsigned long port) | ||
54 | { | ||
55 | badio(outb, port); | ||
56 | } | ||
57 | |||
58 | void se7619___outb_p(unsigned char value, unsigned long port) | ||
59 | { | ||
60 | badio(outb_p, port); | ||
61 | delay(); | ||
62 | } | ||
63 | |||
64 | void se7619___outw(unsigned short value, unsigned long port) | ||
65 | { | ||
66 | badio(outw, port); | ||
67 | } | ||
68 | |||
69 | void se7619___outl(unsigned int value, unsigned long port) | ||
70 | { | ||
71 | badio(outl, port); | ||
72 | } | ||
73 | |||
74 | void se7619___insb(unsigned long port, void *addr, unsigned long count) | ||
75 | { | ||
76 | badio(inw, port); | ||
77 | } | ||
78 | |||
79 | void se7619___insw(unsigned long port, void *addr, unsigned long count) | ||
80 | { | ||
81 | badio(inw, port); | ||
82 | } | ||
83 | |||
84 | void se7619___insl(unsigned long port, void *addr, unsigned long count) | ||
85 | { | ||
86 | badio(insl, port); | ||
87 | } | ||
88 | |||
89 | void se7619___outsb(unsigned long port, const void *addr, unsigned long count) | ||
90 | { | ||
91 | badio(insl, port); | ||
92 | } | ||
93 | |||
94 | void se7619___outsw(unsigned long port, const void *addr, unsigned long count) | ||
95 | { | ||
96 | badio(insl, port); | ||
97 | } | ||
98 | |||
99 | void se7619___outsl(unsigned long port, const void *addr, unsigned long count) | ||
100 | { | ||
101 | badio(outsw, port); | ||
102 | } | ||
diff --git a/arch/sh/boards/se/7619/setup.c b/arch/sh/boards/se/7619/setup.c index e627b26de0d0..52d2c4d5d2fa 100644 --- a/arch/sh/boards/se/7619/setup.c +++ b/arch/sh/boards/se/7619/setup.c | |||
@@ -9,7 +9,6 @@ | |||
9 | #include <linux/init.h> | 9 | #include <linux/init.h> |
10 | #include <linux/platform_device.h> | 10 | #include <linux/platform_device.h> |
11 | #include <asm/io.h> | 11 | #include <asm/io.h> |
12 | #include <asm/se7619.h> | ||
13 | #include <asm/machvec.h> | 12 | #include <asm/machvec.h> |
14 | 13 | ||
15 | /* | 14 | /* |
@@ -19,25 +18,5 @@ | |||
19 | struct sh_machine_vector mv_se __initmv = { | 18 | struct sh_machine_vector mv_se __initmv = { |
20 | .mv_name = "SolutionEngine", | 19 | .mv_name = "SolutionEngine", |
21 | .mv_nr_irqs = 108, | 20 | .mv_nr_irqs = 108, |
22 | .mv_inb = se7619___inb, | ||
23 | .mv_inw = se7619___inw, | ||
24 | .mv_inl = se7619___inl, | ||
25 | .mv_outb = se7619___outb, | ||
26 | .mv_outw = se7619___outw, | ||
27 | .mv_outl = se7619___outl, | ||
28 | |||
29 | .mv_inb_p = se7619___inb_p, | ||
30 | .mv_inw_p = se7619___inw, | ||
31 | .mv_inl_p = se7619___inl, | ||
32 | .mv_outb_p = se7619___outb_p, | ||
33 | .mv_outw_p = se7619___outw, | ||
34 | .mv_outl_p = se7619___outl, | ||
35 | |||
36 | .mv_insb = se7619___insb, | ||
37 | .mv_insw = se7619___insw, | ||
38 | .mv_insl = se7619___insl, | ||
39 | .mv_outsb = se7619___outsb, | ||
40 | .mv_outsw = se7619___outsw, | ||
41 | .mv_outsl = se7619___outsl, | ||
42 | }; | 21 | }; |
43 | ALIAS_MV(se) | 22 | ALIAS_MV(se) |
diff --git a/arch/sh/boot/Makefile b/arch/sh/boot/Makefile index 60797b31089c..11dc272c618e 100644 --- a/arch/sh/boot/Makefile +++ b/arch/sh/boot/Makefile | |||
@@ -8,13 +8,49 @@ | |||
8 | # Copyright (C) 1999 Stuart Menefy | 8 | # Copyright (C) 1999 Stuart Menefy |
9 | # | 9 | # |
10 | 10 | ||
11 | targets := zImage | 11 | MKIMAGE := $(srctree)/scripts/mkuboot.sh |
12 | |||
13 | # | ||
14 | # Assign safe dummy values if these variables are not defined, | ||
15 | # in order to suppress error message. | ||
16 | # | ||
17 | CONFIG_PAGE_OFFSET ?= 0x80000000 | ||
18 | CONFIG_MEMORY_START ?= 0x0c000000 | ||
19 | CONFIG_BOOT_LINK_OFFSET ?= 0x00800000 | ||
20 | CONFIG_ZERO_PAGE_OFFSET ?= 0x00001000 | ||
21 | |||
22 | export CONFIG_PAGE_OFFSET CONFIG_MEMORY_START CONFIG_BOOT_LINK_OFFSET \ | ||
23 | CONFIG_ZERO_PAGE_OFFSET | ||
24 | |||
25 | targets := zImage vmlinux.srec uImage uImage.srec | ||
12 | subdir- := compressed | 26 | subdir- := compressed |
13 | 27 | ||
14 | $(obj)/zImage: $(obj)/compressed/vmlinux FORCE | 28 | $(obj)/zImage: $(obj)/compressed/vmlinux FORCE |
15 | $(call if_changed,objcopy) | 29 | $(call if_changed,objcopy) |
16 | @echo 'Kernel: $@ is ready' | 30 | @echo ' Kernel: $@ is ready' |
17 | 31 | ||
18 | $(obj)/compressed/vmlinux: FORCE | 32 | $(obj)/compressed/vmlinux: FORCE |
19 | $(Q)$(MAKE) $(build)=$(obj)/compressed $@ | 33 | $(Q)$(MAKE) $(build)=$(obj)/compressed $@ |
20 | 34 | ||
35 | KERNEL_LOAD := $(shell printf "0x%8x" $$[$(CONFIG_PAGE_OFFSET) + \ | ||
36 | $(CONFIG_MEMORY_START) + \ | ||
37 | $(CONFIG_ZERO_PAGE_OFFSET)+0x1000]) | ||
38 | |||
39 | quiet_cmd_uimage = UIMAGE $@ | ||
40 | cmd_uimage = $(CONFIG_SHELL) $(MKIMAGE) -A sh -O linux -T kernel \ | ||
41 | -C gzip -a $(KERNEL_LOAD) -e $(KERNEL_LOAD) \ | ||
42 | -n 'Linux-$(KERNELRELEASE)' -d $< $@ | ||
43 | |||
44 | $(obj)/uImage: $(obj)/zImage FORCE | ||
45 | $(call if_changed,uimage) | ||
46 | @echo ' Image $@ is ready' | ||
47 | |||
48 | OBJCOPYFLAGS_vmlinux.srec := -I binary -O srec | ||
49 | $(obj)/vmlinux.srec: $(obj)/compressed/vmlinux | ||
50 | $(call if_changed,objcopy) | ||
51 | |||
52 | OBJCOPYFLAGS_uImage.srec := -I binary -O srec | ||
53 | $(obj)/uImage.srec: $(obj)/uImage | ||
54 | $(call if_changed,objcopy) | ||
55 | |||
56 | clean-files += uImage uImage.srec vmlinux.srec | ||
diff --git a/arch/sh/boot/compressed/Makefile b/arch/sh/boot/compressed/Makefile index e5f443790079..d9512416f885 100644 --- a/arch/sh/boot/compressed/Makefile +++ b/arch/sh/boot/compressed/Makefile | |||
@@ -15,13 +15,7 @@ endif | |||
15 | 15 | ||
16 | # | 16 | # |
17 | # IMAGE_OFFSET is the load offset of the compression loader | 17 | # IMAGE_OFFSET is the load offset of the compression loader |
18 | # Assign dummy values if these 2 variables are not defined, | ||
19 | # in order to suppress error message. | ||
20 | # | 18 | # |
21 | CONFIG_PAGE_OFFSET ?= 0x80000000 | ||
22 | CONFIG_MEMORY_START ?= 0x0c000000 | ||
23 | CONFIG_BOOT_LINK_OFFSET ?= 0x00800000 | ||
24 | |||
25 | IMAGE_OFFSET := $(shell printf "0x%08x" $$[$(CONFIG_PAGE_OFFSET) + \ | 19 | IMAGE_OFFSET := $(shell printf "0x%08x" $$[$(CONFIG_PAGE_OFFSET) + \ |
26 | $(CONFIG_MEMORY_START) + \ | 20 | $(CONFIG_MEMORY_START) + \ |
27 | $(CONFIG_BOOT_LINK_OFFSET)]) | 21 | $(CONFIG_BOOT_LINK_OFFSET)]) |
diff --git a/arch/sh/boot/compressed/head.S b/arch/sh/boot/compressed/head.S index 4c26a192277d..a8399b013729 100644 --- a/arch/sh/boot/compressed/head.S +++ b/arch/sh/boot/compressed/head.S | |||
@@ -8,6 +8,7 @@ | |||
8 | .text | 8 | .text |
9 | 9 | ||
10 | #include <linux/linkage.h> | 10 | #include <linux/linkage.h> |
11 | #include <asm/page.h> | ||
11 | 12 | ||
12 | .global startup | 13 | .global startup |
13 | startup: | 14 | startup: |
@@ -97,7 +98,7 @@ init_stack_addr: | |||
97 | decompress_kernel_addr: | 98 | decompress_kernel_addr: |
98 | .long decompress_kernel | 99 | .long decompress_kernel |
99 | kernel_start_addr: | 100 | kernel_start_addr: |
100 | .long _text+0x1000 | 101 | .long _text+PAGE_SIZE |
101 | 102 | ||
102 | .align 9 | 103 | .align 9 |
103 | fake_headers_as_bzImage: | 104 | fake_headers_as_bzImage: |
diff --git a/arch/sh/boot/compressed/misc.c b/arch/sh/boot/compressed/misc.c index 35452d85b7f7..df65e305acf7 100644 --- a/arch/sh/boot/compressed/misc.c +++ b/arch/sh/boot/compressed/misc.c | |||
@@ -13,6 +13,7 @@ | |||
13 | 13 | ||
14 | #include <asm/uaccess.h> | 14 | #include <asm/uaccess.h> |
15 | #include <asm/addrspace.h> | 15 | #include <asm/addrspace.h> |
16 | #include <asm/page.h> | ||
16 | #ifdef CONFIG_SH_STANDARD_BIOS | 17 | #ifdef CONFIG_SH_STANDARD_BIOS |
17 | #include <asm/sh_bios.h> | 18 | #include <asm/sh_bios.h> |
18 | #endif | 19 | #endif |
@@ -229,7 +230,7 @@ long* stack_start = &user_stack[STACK_SIZE]; | |||
229 | void decompress_kernel(void) | 230 | void decompress_kernel(void) |
230 | { | 231 | { |
231 | output_data = 0; | 232 | output_data = 0; |
232 | output_ptr = P2SEGADDR((unsigned long)&_text+0x1000); | 233 | output_ptr = P2SEGADDR((unsigned long)&_text+PAGE_SIZE); |
233 | free_mem_ptr = (unsigned long)&_end; | 234 | free_mem_ptr = (unsigned long)&_end; |
234 | free_mem_end_ptr = free_mem_ptr + HEAP_SIZE; | 235 | free_mem_end_ptr = free_mem_ptr + HEAP_SIZE; |
235 | 236 | ||
diff --git a/arch/sh/configs/landisk_defconfig b/arch/sh/configs/landisk_defconfig index 238c0f109907..e7f8ddb0ada4 100644 --- a/arch/sh/configs/landisk_defconfig +++ b/arch/sh/configs/landisk_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.18 | 3 | # Linux kernel version: 2.6.19 |
4 | # Tue Oct 3 11:14:13 2006 | 4 | # Thu Dec 7 17:13:04 2006 |
5 | # | 5 | # |
6 | CONFIG_SUPERH=y | 6 | CONFIG_SUPERH=y |
7 | CONFIG_RWSEM_GENERIC_SPINLOCK=y | 7 | CONFIG_RWSEM_GENERIC_SPINLOCK=y |
@@ -10,6 +10,9 @@ CONFIG_GENERIC_HWEIGHT=y | |||
10 | CONFIG_GENERIC_HARDIRQS=y | 10 | CONFIG_GENERIC_HARDIRQS=y |
11 | CONFIG_GENERIC_IRQ_PROBE=y | 11 | CONFIG_GENERIC_IRQ_PROBE=y |
12 | CONFIG_GENERIC_CALIBRATE_DELAY=y | 12 | CONFIG_GENERIC_CALIBRATE_DELAY=y |
13 | # CONFIG_GENERIC_TIME is not set | ||
14 | CONFIG_STACKTRACE_SUPPORT=y | ||
15 | CONFIG_LOCKDEP_SUPPORT=y | ||
13 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" | 16 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" |
14 | 17 | ||
15 | # | 18 | # |
@@ -33,6 +36,7 @@ CONFIG_SYSVIPC=y | |||
33 | # CONFIG_UTS_NS is not set | 36 | # CONFIG_UTS_NS is not set |
34 | # CONFIG_AUDIT is not set | 37 | # CONFIG_AUDIT is not set |
35 | # CONFIG_IKCONFIG is not set | 38 | # CONFIG_IKCONFIG is not set |
39 | CONFIG_SYSFS_DEPRECATED=y | ||
36 | # CONFIG_RELAY is not set | 40 | # CONFIG_RELAY is not set |
37 | CONFIG_INITRAMFS_SOURCE="" | 41 | CONFIG_INITRAMFS_SOURCE="" |
38 | CONFIG_CC_OPTIMIZE_FOR_SIZE=y | 42 | CONFIG_CC_OPTIMIZE_FOR_SIZE=y |
@@ -114,6 +118,8 @@ CONFIG_DEFAULT_IOSCHED="anticipatory" | |||
114 | CONFIG_SH_LANDISK=y | 118 | CONFIG_SH_LANDISK=y |
115 | # CONFIG_SH_TITAN is not set | 119 | # CONFIG_SH_TITAN is not set |
116 | # CONFIG_SH_SHMIN is not set | 120 | # CONFIG_SH_SHMIN is not set |
121 | # CONFIG_SH_7206_SOLUTION_ENGINE is not set | ||
122 | # CONFIG_SH_7619_SOLUTION_ENGINE is not set | ||
117 | # CONFIG_SH_UNKNOWN is not set | 123 | # CONFIG_SH_UNKNOWN is not set |
118 | 124 | ||
119 | # | 125 | # |
@@ -125,6 +131,12 @@ CONFIG_CPU_SH4=y | |||
125 | # SH-2 Processor Support | 131 | # SH-2 Processor Support |
126 | # | 132 | # |
127 | # CONFIG_CPU_SUBTYPE_SH7604 is not set | 133 | # CONFIG_CPU_SUBTYPE_SH7604 is not set |
134 | # CONFIG_CPU_SUBTYPE_SH7619 is not set | ||
135 | |||
136 | # | ||
137 | # SH-2A Processor Support | ||
138 | # | ||
139 | # CONFIG_CPU_SUBTYPE_SH7206 is not set | ||
128 | 140 | ||
129 | # | 141 | # |
130 | # SH-3 Processor Support | 142 | # SH-3 Processor Support |
@@ -160,6 +172,7 @@ CONFIG_CPU_SUBTYPE_SH7751R=y | |||
160 | # | 172 | # |
161 | # CONFIG_CPU_SUBTYPE_SH7770 is not set | 173 | # CONFIG_CPU_SUBTYPE_SH7770 is not set |
162 | # CONFIG_CPU_SUBTYPE_SH7780 is not set | 174 | # CONFIG_CPU_SUBTYPE_SH7780 is not set |
175 | # CONFIG_CPU_SUBTYPE_SH7785 is not set | ||
163 | 176 | ||
164 | # | 177 | # |
165 | # SH4AL-DSP Processor Support | 178 | # SH4AL-DSP Processor Support |
@@ -175,6 +188,9 @@ CONFIG_PAGE_OFFSET=0x80000000 | |||
175 | CONFIG_MEMORY_START=0x0c000000 | 188 | CONFIG_MEMORY_START=0x0c000000 |
176 | CONFIG_MEMORY_SIZE=0x04000000 | 189 | CONFIG_MEMORY_SIZE=0x04000000 |
177 | CONFIG_VSYSCALL=y | 190 | CONFIG_VSYSCALL=y |
191 | CONFIG_PAGE_SIZE_4KB=y | ||
192 | # CONFIG_PAGE_SIZE_8KB is not set | ||
193 | # CONFIG_PAGE_SIZE_64KB is not set | ||
178 | CONFIG_SELECT_MEMORY_MODEL=y | 194 | CONFIG_SELECT_MEMORY_MODEL=y |
179 | CONFIG_FLATMEM_MANUAL=y | 195 | CONFIG_FLATMEM_MANUAL=y |
180 | # CONFIG_DISCONTIGMEM_MANUAL is not set | 196 | # CONFIG_DISCONTIGMEM_MANUAL is not set |
@@ -196,16 +212,21 @@ CONFIG_SPLIT_PTLOCK_CPUS=4 | |||
196 | # Processor features | 212 | # Processor features |
197 | # | 213 | # |
198 | CONFIG_CPU_LITTLE_ENDIAN=y | 214 | CONFIG_CPU_LITTLE_ENDIAN=y |
215 | # CONFIG_CPU_BIG_ENDIAN is not set | ||
199 | CONFIG_SH_FPU=y | 216 | CONFIG_SH_FPU=y |
200 | # CONFIG_SH_DSP is not set | 217 | # CONFIG_SH_DSP is not set |
201 | # CONFIG_SH_STORE_QUEUES is not set | 218 | # CONFIG_SH_STORE_QUEUES is not set |
202 | CONFIG_CPU_HAS_INTEVT=y | 219 | CONFIG_CPU_HAS_INTEVT=y |
220 | CONFIG_CPU_HAS_IPR_IRQ=y | ||
203 | CONFIG_CPU_HAS_SR_RB=y | 221 | CONFIG_CPU_HAS_SR_RB=y |
222 | CONFIG_CPU_HAS_PTEA=y | ||
204 | 223 | ||
205 | # | 224 | # |
206 | # Timer support | 225 | # Timer support |
207 | # | 226 | # |
208 | CONFIG_SH_TMU=y | 227 | CONFIG_SH_TMU=y |
228 | CONFIG_SH_TIMER_IRQ=16 | ||
229 | # CONFIG_NO_IDLE_HZ is not set | ||
209 | CONFIG_SH_PCLK_FREQ=33333333 | 230 | CONFIG_SH_PCLK_FREQ=33333333 |
210 | 231 | ||
211 | # | 232 | # |
@@ -216,9 +237,7 @@ CONFIG_SH_PCLK_FREQ=33333333 | |||
216 | # | 237 | # |
217 | # DMA support | 238 | # DMA support |
218 | # | 239 | # |
219 | CONFIG_SH_DMA=y | 240 | # CONFIG_SH_DMA is not set |
220 | CONFIG_NR_ONCHIP_DMA_CHANNELS=4 | ||
221 | # CONFIG_NR_DMA_CHANNELS_BOOL is not set | ||
222 | 241 | ||
223 | # | 242 | # |
224 | # Companion Chips | 243 | # Companion Chips |
@@ -227,6 +246,11 @@ CONFIG_NR_ONCHIP_DMA_CHANNELS=4 | |||
227 | CONFIG_HEARTBEAT=y | 246 | CONFIG_HEARTBEAT=y |
228 | 247 | ||
229 | # | 248 | # |
249 | # Additional SuperH Device Drivers | ||
250 | # | ||
251 | # CONFIG_PUSH_SWITCH is not set | ||
252 | |||
253 | # | ||
230 | # Kernel features | 254 | # Kernel features |
231 | # | 255 | # |
232 | # CONFIG_HZ_100 is not set | 256 | # CONFIG_HZ_100 is not set |
@@ -340,11 +364,13 @@ CONFIG_IP_PNP=y | |||
340 | # CONFIG_INET_TUNNEL is not set | 364 | # CONFIG_INET_TUNNEL is not set |
341 | CONFIG_INET_XFRM_MODE_TRANSPORT=y | 365 | CONFIG_INET_XFRM_MODE_TRANSPORT=y |
342 | CONFIG_INET_XFRM_MODE_TUNNEL=y | 366 | CONFIG_INET_XFRM_MODE_TUNNEL=y |
367 | CONFIG_INET_XFRM_MODE_BEET=y | ||
343 | CONFIG_INET_DIAG=y | 368 | CONFIG_INET_DIAG=y |
344 | CONFIG_INET_TCP_DIAG=y | 369 | CONFIG_INET_TCP_DIAG=y |
345 | # CONFIG_TCP_CONG_ADVANCED is not set | 370 | # CONFIG_TCP_CONG_ADVANCED is not set |
346 | CONFIG_TCP_CONG_CUBIC=y | 371 | CONFIG_TCP_CONG_CUBIC=y |
347 | CONFIG_DEFAULT_TCP_CONG="cubic" | 372 | CONFIG_DEFAULT_TCP_CONG="cubic" |
373 | # CONFIG_TCP_MD5SIG is not set | ||
348 | 374 | ||
349 | # | 375 | # |
350 | # IP: Virtual Server Configuration | 376 | # IP: Virtual Server Configuration |
@@ -361,24 +387,12 @@ CONFIG_NETFILTER=y | |||
361 | # Core Netfilter Configuration | 387 | # Core Netfilter Configuration |
362 | # | 388 | # |
363 | # CONFIG_NETFILTER_NETLINK is not set | 389 | # CONFIG_NETFILTER_NETLINK is not set |
390 | # CONFIG_NF_CONNTRACK_ENABLED is not set | ||
364 | # CONFIG_NETFILTER_XTABLES is not set | 391 | # CONFIG_NETFILTER_XTABLES is not set |
365 | 392 | ||
366 | # | 393 | # |
367 | # IP: Netfilter Configuration | 394 | # IP: Netfilter Configuration |
368 | # | 395 | # |
369 | CONFIG_IP_NF_CONNTRACK=m | ||
370 | CONFIG_IP_NF_CT_ACCT=y | ||
371 | CONFIG_IP_NF_CONNTRACK_MARK=y | ||
372 | # CONFIG_IP_NF_CONNTRACK_EVENTS is not set | ||
373 | # CONFIG_IP_NF_CT_PROTO_SCTP is not set | ||
374 | CONFIG_IP_NF_FTP=m | ||
375 | CONFIG_IP_NF_IRC=m | ||
376 | # CONFIG_IP_NF_NETBIOS_NS is not set | ||
377 | CONFIG_IP_NF_TFTP=m | ||
378 | CONFIG_IP_NF_AMANDA=m | ||
379 | # CONFIG_IP_NF_PPTP is not set | ||
380 | # CONFIG_IP_NF_H323 is not set | ||
381 | # CONFIG_IP_NF_SIP is not set | ||
382 | CONFIG_IP_NF_QUEUE=m | 396 | CONFIG_IP_NF_QUEUE=m |
383 | 397 | ||
384 | # | 398 | # |
@@ -477,6 +491,12 @@ CONFIG_BLK_DEV_RAM_BLOCKSIZE=1024 | |||
477 | # CONFIG_ATA_OVER_ETH is not set | 491 | # CONFIG_ATA_OVER_ETH is not set |
478 | 492 | ||
479 | # | 493 | # |
494 | # Misc devices | ||
495 | # | ||
496 | # CONFIG_SGI_IOC4 is not set | ||
497 | # CONFIG_TIFM_CORE is not set | ||
498 | |||
499 | # | ||
480 | # ATA/ATAPI/MFM/RLL support | 500 | # ATA/ATAPI/MFM/RLL support |
481 | # | 501 | # |
482 | CONFIG_IDE=y | 502 | CONFIG_IDE=y |
@@ -519,6 +539,7 @@ CONFIG_BLK_DEV_AEC62XX=y | |||
519 | # CONFIG_BLK_DEV_CS5530 is not set | 539 | # CONFIG_BLK_DEV_CS5530 is not set |
520 | # CONFIG_BLK_DEV_HPT34X is not set | 540 | # CONFIG_BLK_DEV_HPT34X is not set |
521 | # CONFIG_BLK_DEV_HPT366 is not set | 541 | # CONFIG_BLK_DEV_HPT366 is not set |
542 | # CONFIG_BLK_DEV_JMICRON is not set | ||
522 | # CONFIG_BLK_DEV_SC1200 is not set | 543 | # CONFIG_BLK_DEV_SC1200 is not set |
523 | # CONFIG_BLK_DEV_PIIX is not set | 544 | # CONFIG_BLK_DEV_PIIX is not set |
524 | # CONFIG_BLK_DEV_IT821X is not set | 545 | # CONFIG_BLK_DEV_IT821X is not set |
@@ -542,6 +563,7 @@ CONFIG_IDEDMA_AUTO=y | |||
542 | # | 563 | # |
543 | # CONFIG_RAID_ATTRS is not set | 564 | # CONFIG_RAID_ATTRS is not set |
544 | CONFIG_SCSI=y | 565 | CONFIG_SCSI=y |
566 | # CONFIG_SCSI_TGT is not set | ||
545 | # CONFIG_SCSI_NETLINK is not set | 567 | # CONFIG_SCSI_NETLINK is not set |
546 | CONFIG_SCSI_PROC_FS=y | 568 | CONFIG_SCSI_PROC_FS=y |
547 | 569 | ||
@@ -561,6 +583,7 @@ CONFIG_BLK_DEV_SD=y | |||
561 | CONFIG_SCSI_MULTI_LUN=y | 583 | CONFIG_SCSI_MULTI_LUN=y |
562 | # CONFIG_SCSI_CONSTANTS is not set | 584 | # CONFIG_SCSI_CONSTANTS is not set |
563 | # CONFIG_SCSI_LOGGING is not set | 585 | # CONFIG_SCSI_LOGGING is not set |
586 | # CONFIG_SCSI_SCAN_ASYNC is not set | ||
564 | 587 | ||
565 | # | 588 | # |
566 | # SCSI Transports | 589 | # SCSI Transports |
@@ -602,12 +625,12 @@ CONFIG_SCSI_MULTI_LUN=y | |||
602 | # CONFIG_SCSI_NCR53C406A is not set | 625 | # CONFIG_SCSI_NCR53C406A is not set |
603 | # CONFIG_SCSI_STEX is not set | 626 | # CONFIG_SCSI_STEX is not set |
604 | # CONFIG_SCSI_SYM53C8XX_2 is not set | 627 | # CONFIG_SCSI_SYM53C8XX_2 is not set |
605 | # CONFIG_SCSI_IPR is not set | ||
606 | # CONFIG_SCSI_PAS16 is not set | 628 | # CONFIG_SCSI_PAS16 is not set |
607 | # CONFIG_SCSI_PSI240I is not set | 629 | # CONFIG_SCSI_PSI240I is not set |
608 | # CONFIG_SCSI_QLOGIC_FAS is not set | 630 | # CONFIG_SCSI_QLOGIC_FAS is not set |
609 | # CONFIG_SCSI_QLOGIC_1280 is not set | 631 | # CONFIG_SCSI_QLOGIC_1280 is not set |
610 | # CONFIG_SCSI_QLA_FC is not set | 632 | # CONFIG_SCSI_QLA_FC is not set |
633 | # CONFIG_SCSI_QLA_ISCSI is not set | ||
611 | # CONFIG_SCSI_LPFC is not set | 634 | # CONFIG_SCSI_LPFC is not set |
612 | # CONFIG_SCSI_SYM53C416 is not set | 635 | # CONFIG_SCSI_SYM53C416 is not set |
613 | # CONFIG_SCSI_DC395x is not set | 636 | # CONFIG_SCSI_DC395x is not set |
@@ -615,6 +638,7 @@ CONFIG_SCSI_MULTI_LUN=y | |||
615 | # CONFIG_SCSI_T128 is not set | 638 | # CONFIG_SCSI_T128 is not set |
616 | # CONFIG_SCSI_NSP32 is not set | 639 | # CONFIG_SCSI_NSP32 is not set |
617 | # CONFIG_SCSI_DEBUG is not set | 640 | # CONFIG_SCSI_DEBUG is not set |
641 | # CONFIG_SCSI_SRP is not set | ||
618 | 642 | ||
619 | # | 643 | # |
620 | # PCMCIA SCSI adapter support | 644 | # PCMCIA SCSI adapter support |
@@ -757,6 +781,7 @@ CONFIG_8139CP=y | |||
757 | # CONFIG_IXGB is not set | 781 | # CONFIG_IXGB is not set |
758 | # CONFIG_S2IO is not set | 782 | # CONFIG_S2IO is not set |
759 | # CONFIG_MYRI10GE is not set | 783 | # CONFIG_MYRI10GE is not set |
784 | # CONFIG_NETXEN_NIC is not set | ||
760 | 785 | ||
761 | # | 786 | # |
762 | # Token Ring devices | 787 | # Token Ring devices |
@@ -871,10 +896,6 @@ CONFIG_HW_RANDOM=y | |||
871 | # CONFIG_DTLK is not set | 896 | # CONFIG_DTLK is not set |
872 | # CONFIG_R3964 is not set | 897 | # CONFIG_R3964 is not set |
873 | # CONFIG_APPLICOM is not set | 898 | # CONFIG_APPLICOM is not set |
874 | |||
875 | # | ||
876 | # Ftape, the floppy tape device driver | ||
877 | # | ||
878 | # CONFIG_DRM is not set | 899 | # CONFIG_DRM is not set |
879 | 900 | ||
880 | # | 901 | # |
@@ -889,7 +910,6 @@ CONFIG_HW_RANDOM=y | |||
889 | # TPM devices | 910 | # TPM devices |
890 | # | 911 | # |
891 | # CONFIG_TCG_TPM is not set | 912 | # CONFIG_TCG_TPM is not set |
892 | # CONFIG_TELCLOCK is not set | ||
893 | 913 | ||
894 | # | 914 | # |
895 | # I2C support | 915 | # I2C support |
@@ -905,6 +925,7 @@ CONFIG_HW_RANDOM=y | |||
905 | # | 925 | # |
906 | # Dallas's 1-wire bus | 926 | # Dallas's 1-wire bus |
907 | # | 927 | # |
928 | # CONFIG_W1 is not set | ||
908 | 929 | ||
909 | # | 930 | # |
910 | # Hardware Monitoring support | 931 | # Hardware Monitoring support |
@@ -917,10 +938,6 @@ CONFIG_HWMON=y | |||
917 | # CONFIG_HWMON_DEBUG_CHIP is not set | 938 | # CONFIG_HWMON_DEBUG_CHIP is not set |
918 | 939 | ||
919 | # | 940 | # |
920 | # Misc devices | ||
921 | # | ||
922 | |||
923 | # | ||
924 | # Multimedia devices | 941 | # Multimedia devices |
925 | # | 942 | # |
926 | CONFIG_VIDEO_DEV=m | 943 | CONFIG_VIDEO_DEV=m |
@@ -1037,6 +1054,7 @@ CONFIG_USB=y | |||
1037 | CONFIG_USB_DEVICEFS=y | 1054 | CONFIG_USB_DEVICEFS=y |
1038 | # CONFIG_USB_BANDWIDTH is not set | 1055 | # CONFIG_USB_BANDWIDTH is not set |
1039 | # CONFIG_USB_DYNAMIC_MINORS is not set | 1056 | # CONFIG_USB_DYNAMIC_MINORS is not set |
1057 | # CONFIG_USB_MULTITHREAD_PROBE is not set | ||
1040 | # CONFIG_USB_OTG is not set | 1058 | # CONFIG_USB_OTG is not set |
1041 | 1059 | ||
1042 | # | 1060 | # |
@@ -1106,7 +1124,6 @@ CONFIG_USB_HIDINPUT=y | |||
1106 | # CONFIG_USB_ATI_REMOTE2 is not set | 1124 | # CONFIG_USB_ATI_REMOTE2 is not set |
1107 | # CONFIG_USB_KEYSPAN_REMOTE is not set | 1125 | # CONFIG_USB_KEYSPAN_REMOTE is not set |
1108 | # CONFIG_USB_APPLETOUCH is not set | 1126 | # CONFIG_USB_APPLETOUCH is not set |
1109 | # CONFIG_USB_TRANCEVIBRATOR is not set | ||
1110 | 1127 | ||
1111 | # | 1128 | # |
1112 | # USB Imaging devices | 1129 | # USB Imaging devices |
@@ -1121,6 +1138,7 @@ CONFIG_USB_HIDINPUT=y | |||
1121 | # CONFIG_USB_KAWETH is not set | 1138 | # CONFIG_USB_KAWETH is not set |
1122 | CONFIG_USB_PEGASUS=m | 1139 | CONFIG_USB_PEGASUS=m |
1123 | CONFIG_USB_RTL8150=m | 1140 | CONFIG_USB_RTL8150=m |
1141 | # CONFIG_USB_USBNET_MII is not set | ||
1124 | # CONFIG_USB_USBNET is not set | 1142 | # CONFIG_USB_USBNET is not set |
1125 | CONFIG_USB_MON=y | 1143 | CONFIG_USB_MON=y |
1126 | 1144 | ||
@@ -1156,6 +1174,7 @@ CONFIG_USB_SERIAL_FTDI_SIO=m | |||
1156 | # CONFIG_USB_SERIAL_KLSI is not set | 1174 | # CONFIG_USB_SERIAL_KLSI is not set |
1157 | # CONFIG_USB_SERIAL_KOBIL_SCT is not set | 1175 | # CONFIG_USB_SERIAL_KOBIL_SCT is not set |
1158 | # CONFIG_USB_SERIAL_MCT_U232 is not set | 1176 | # CONFIG_USB_SERIAL_MCT_U232 is not set |
1177 | # CONFIG_USB_SERIAL_MOS7720 is not set | ||
1159 | # CONFIG_USB_SERIAL_MOS7840 is not set | 1178 | # CONFIG_USB_SERIAL_MOS7840 is not set |
1160 | # CONFIG_USB_SERIAL_NAVMAN is not set | 1179 | # CONFIG_USB_SERIAL_NAVMAN is not set |
1161 | CONFIG_USB_SERIAL_PL2303=m | 1180 | CONFIG_USB_SERIAL_PL2303=m |
@@ -1167,6 +1186,7 @@ CONFIG_USB_SERIAL_PL2303=m | |||
1167 | # CONFIG_USB_SERIAL_XIRCOM is not set | 1186 | # CONFIG_USB_SERIAL_XIRCOM is not set |
1168 | # CONFIG_USB_SERIAL_OPTION is not set | 1187 | # CONFIG_USB_SERIAL_OPTION is not set |
1169 | # CONFIG_USB_SERIAL_OMNINET is not set | 1188 | # CONFIG_USB_SERIAL_OMNINET is not set |
1189 | # CONFIG_USB_SERIAL_DEBUG is not set | ||
1170 | 1190 | ||
1171 | # | 1191 | # |
1172 | # USB Miscellaneous drivers | 1192 | # USB Miscellaneous drivers |
@@ -1188,6 +1208,7 @@ CONFIG_USB_EMI26=m | |||
1188 | CONFIG_USB_SISUSBVGA=m | 1208 | CONFIG_USB_SISUSBVGA=m |
1189 | CONFIG_USB_SISUSBVGA_CON=y | 1209 | CONFIG_USB_SISUSBVGA_CON=y |
1190 | # CONFIG_USB_LD is not set | 1210 | # CONFIG_USB_LD is not set |
1211 | # CONFIG_USB_TRANCEVIBRATOR is not set | ||
1191 | # CONFIG_USB_TEST is not set | 1212 | # CONFIG_USB_TEST is not set |
1192 | 1213 | ||
1193 | # | 1214 | # |
@@ -1254,6 +1275,7 @@ CONFIG_EXT3_FS=y | |||
1254 | CONFIG_EXT3_FS_XATTR=y | 1275 | CONFIG_EXT3_FS_XATTR=y |
1255 | # CONFIG_EXT3_FS_POSIX_ACL is not set | 1276 | # CONFIG_EXT3_FS_POSIX_ACL is not set |
1256 | # CONFIG_EXT3_FS_SECURITY is not set | 1277 | # CONFIG_EXT3_FS_SECURITY is not set |
1278 | # CONFIG_EXT4DEV_FS is not set | ||
1257 | CONFIG_JBD=y | 1279 | CONFIG_JBD=y |
1258 | # CONFIG_JBD_DEBUG is not set | 1280 | # CONFIG_JBD_DEBUG is not set |
1259 | CONFIG_FS_MBCACHE=y | 1281 | CONFIG_FS_MBCACHE=y |
@@ -1264,6 +1286,7 @@ CONFIG_REISERFS_FS=y | |||
1264 | # CONFIG_JFS_FS is not set | 1286 | # CONFIG_JFS_FS is not set |
1265 | # CONFIG_FS_POSIX_ACL is not set | 1287 | # CONFIG_FS_POSIX_ACL is not set |
1266 | # CONFIG_XFS_FS is not set | 1288 | # CONFIG_XFS_FS is not set |
1289 | # CONFIG_GFS2_FS is not set | ||
1267 | # CONFIG_OCFS2_FS is not set | 1290 | # CONFIG_OCFS2_FS is not set |
1268 | # CONFIG_MINIX_FS is not set | 1291 | # CONFIG_MINIX_FS is not set |
1269 | CONFIG_ROMFS_FS=y | 1292 | CONFIG_ROMFS_FS=y |
@@ -1414,6 +1437,7 @@ CONFIG_NLS_CODEPAGE_932=y | |||
1414 | # | 1437 | # |
1415 | # Kernel hacking | 1438 | # Kernel hacking |
1416 | # | 1439 | # |
1440 | CONFIG_TRACE_IRQFLAGS_SUPPORT=y | ||
1417 | # CONFIG_PRINTK_TIME is not set | 1441 | # CONFIG_PRINTK_TIME is not set |
1418 | CONFIG_ENABLE_MUST_CHECK=y | 1442 | CONFIG_ENABLE_MUST_CHECK=y |
1419 | # CONFIG_MAGIC_SYSRQ is not set | 1443 | # CONFIG_MAGIC_SYSRQ is not set |
@@ -1422,6 +1446,7 @@ CONFIG_ENABLE_MUST_CHECK=y | |||
1422 | CONFIG_LOG_BUF_SHIFT=14 | 1446 | CONFIG_LOG_BUF_SHIFT=14 |
1423 | # CONFIG_DEBUG_BUGVERBOSE is not set | 1447 | # CONFIG_DEBUG_BUGVERBOSE is not set |
1424 | # CONFIG_DEBUG_FS is not set | 1448 | # CONFIG_DEBUG_FS is not set |
1449 | # CONFIG_HEADERS_CHECK is not set | ||
1425 | CONFIG_SH_STANDARD_BIOS=y | 1450 | CONFIG_SH_STANDARD_BIOS=y |
1426 | # CONFIG_EARLY_SCIF_CONSOLE is not set | 1451 | # CONFIG_EARLY_SCIF_CONSOLE is not set |
1427 | # CONFIG_EARLY_PRINTK is not set | 1452 | # CONFIG_EARLY_PRINTK is not set |
@@ -1445,6 +1470,4 @@ CONFIG_SH_STANDARD_BIOS=y | |||
1445 | # CONFIG_CRC16 is not set | 1470 | # CONFIG_CRC16 is not set |
1446 | CONFIG_CRC32=y | 1471 | CONFIG_CRC32=y |
1447 | # CONFIG_LIBCRC32C is not set | 1472 | # CONFIG_LIBCRC32C is not set |
1448 | CONFIG_TEXTSEARCH=y | ||
1449 | CONFIG_TEXTSEARCH_KMP=m | ||
1450 | CONFIG_PLIST=y | 1473 | CONFIG_PLIST=y |
diff --git a/arch/sh/configs/se7206_defconfig b/arch/sh/configs/se7206_defconfig index 36cec0b6e7c1..87ab9080fd1d 100644 --- a/arch/sh/configs/se7206_defconfig +++ b/arch/sh/configs/se7206_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.19-rc4 | 3 | # Linux kernel version: 2.6.19 |
4 | # Sun Nov 5 16:20:10 2006 | 4 | # Wed Dec 6 14:40:15 2006 |
5 | # | 5 | # |
6 | CONFIG_SUPERH=y | 6 | CONFIG_SUPERH=y |
7 | CONFIG_RWSEM_GENERIC_SPINLOCK=y | 7 | CONFIG_RWSEM_GENERIC_SPINLOCK=y |
@@ -11,6 +11,8 @@ CONFIG_GENERIC_HARDIRQS=y | |||
11 | CONFIG_GENERIC_IRQ_PROBE=y | 11 | CONFIG_GENERIC_IRQ_PROBE=y |
12 | CONFIG_GENERIC_CALIBRATE_DELAY=y | 12 | CONFIG_GENERIC_CALIBRATE_DELAY=y |
13 | # CONFIG_GENERIC_TIME is not set | 13 | # CONFIG_GENERIC_TIME is not set |
14 | CONFIG_STACKTRACE_SUPPORT=y | ||
15 | CONFIG_LOCKDEP_SUPPORT=y | ||
14 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" | 16 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" |
15 | 17 | ||
16 | # | 18 | # |
@@ -34,24 +36,23 @@ CONFIG_LOCALVERSION="" | |||
34 | # CONFIG_IKCONFIG is not set | 36 | # CONFIG_IKCONFIG is not set |
35 | # CONFIG_RELAY is not set | 37 | # CONFIG_RELAY is not set |
36 | CONFIG_INITRAMFS_SOURCE="" | 38 | CONFIG_INITRAMFS_SOURCE="" |
37 | # CONFIG_CC_OPTIMIZE_FOR_SIZE is not set | 39 | CONFIG_CC_OPTIMIZE_FOR_SIZE=y |
38 | CONFIG_SYSCTL=y | 40 | CONFIG_SYSCTL=y |
39 | CONFIG_EMBEDDED=y | 41 | CONFIG_EMBEDDED=y |
40 | CONFIG_UID16=y | 42 | # CONFIG_UID16 is not set |
41 | # CONFIG_SYSCTL_SYSCALL is not set | 43 | # CONFIG_SYSCTL_SYSCALL is not set |
42 | CONFIG_KALLSYMS=y | 44 | # CONFIG_KALLSYMS is not set |
43 | # CONFIG_KALLSYMS_EXTRA_PASS is not set | ||
44 | # CONFIG_HOTPLUG is not set | 45 | # CONFIG_HOTPLUG is not set |
45 | CONFIG_PRINTK=y | 46 | CONFIG_PRINTK=y |
46 | CONFIG_BUG=y | 47 | CONFIG_BUG=y |
47 | CONFIG_ELF_CORE=y | 48 | # CONFIG_ELF_CORE is not set |
48 | CONFIG_BASE_FULL=y | 49 | # CONFIG_BASE_FULL is not set |
49 | # CONFIG_FUTEX is not set | 50 | # CONFIG_FUTEX is not set |
50 | # CONFIG_EPOLL is not set | 51 | # CONFIG_EPOLL is not set |
51 | CONFIG_SLAB=y | 52 | CONFIG_SLAB=y |
52 | CONFIG_VM_EVENT_COUNTERS=y | 53 | # CONFIG_VM_EVENT_COUNTERS is not set |
53 | CONFIG_TINY_SHMEM=y | 54 | CONFIG_TINY_SHMEM=y |
54 | CONFIG_BASE_SMALL=0 | 55 | CONFIG_BASE_SMALL=1 |
55 | # CONFIG_SLOB is not set | 56 | # CONFIG_SLOB is not set |
56 | 57 | ||
57 | # | 58 | # |
@@ -160,6 +161,7 @@ CONFIG_CPU_SUBTYPE_SH7206=y | |||
160 | # | 161 | # |
161 | # CONFIG_CPU_SUBTYPE_SH7770 is not set | 162 | # CONFIG_CPU_SUBTYPE_SH7770 is not set |
162 | # CONFIG_CPU_SUBTYPE_SH7780 is not set | 163 | # CONFIG_CPU_SUBTYPE_SH7780 is not set |
164 | # CONFIG_CPU_SUBTYPE_SH7785 is not set | ||
163 | 165 | ||
164 | # | 166 | # |
165 | # SH4AL-DSP Processor Support | 167 | # SH4AL-DSP Processor Support |
@@ -172,7 +174,10 @@ CONFIG_CPU_SUBTYPE_SH7206=y | |||
172 | # | 174 | # |
173 | CONFIG_PAGE_OFFSET=0x00000000 | 175 | CONFIG_PAGE_OFFSET=0x00000000 |
174 | CONFIG_MEMORY_START=0x0c000000 | 176 | CONFIG_MEMORY_START=0x0c000000 |
175 | CONFIG_MEMORY_SIZE=0x02000000 | 177 | CONFIG_MEMORY_SIZE=0x04000000 |
178 | CONFIG_PAGE_SIZE_4KB=y | ||
179 | # CONFIG_PAGE_SIZE_8KB is not set | ||
180 | # CONFIG_PAGE_SIZE_64KB is not set | ||
176 | CONFIG_SELECT_MEMORY_MODEL=y | 181 | CONFIG_SELECT_MEMORY_MODEL=y |
177 | CONFIG_FLATMEM_MANUAL=y | 182 | CONFIG_FLATMEM_MANUAL=y |
178 | # CONFIG_DISCONTIGMEM_MANUAL is not set | 183 | # CONFIG_DISCONTIGMEM_MANUAL is not set |
@@ -194,6 +199,7 @@ CONFIG_SPLIT_PTLOCK_CPUS=4 | |||
194 | # Processor features | 199 | # Processor features |
195 | # | 200 | # |
196 | # CONFIG_CPU_LITTLE_ENDIAN is not set | 201 | # CONFIG_CPU_LITTLE_ENDIAN is not set |
202 | CONFIG_CPU_BIG_ENDIAN=y | ||
197 | # CONFIG_SH_FPU is not set | 203 | # CONFIG_SH_FPU is not set |
198 | # CONFIG_SH_FPU_EMU is not set | 204 | # CONFIG_SH_FPU_EMU is not set |
199 | # CONFIG_SH_DSP is not set | 205 | # CONFIG_SH_DSP is not set |
@@ -203,6 +209,8 @@ CONFIG_SPLIT_PTLOCK_CPUS=4 | |||
203 | # | 209 | # |
204 | CONFIG_SH_CMT=y | 210 | CONFIG_SH_CMT=y |
205 | # CONFIG_SH_MTU2 is not set | 211 | # CONFIG_SH_MTU2 is not set |
212 | CONFIG_SH_TIMER_IRQ=140 | ||
213 | # CONFIG_NO_IDLE_HZ is not set | ||
206 | CONFIG_SH_PCLK_FREQ=33333333 | 214 | CONFIG_SH_PCLK_FREQ=33333333 |
207 | CONFIG_SH_CLK_MD=6 | 215 | CONFIG_SH_CLK_MD=6 |
208 | 216 | ||
@@ -222,6 +230,11 @@ CONFIG_SH_CLK_MD=6 | |||
222 | # CONFIG_HD6446X_SERIES is not set | 230 | # CONFIG_HD6446X_SERIES is not set |
223 | 231 | ||
224 | # | 232 | # |
233 | # Additional SuperH Device Drivers | ||
234 | # | ||
235 | # CONFIG_PUSH_SWITCH is not set | ||
236 | |||
237 | # | ||
225 | # Kernel features | 238 | # Kernel features |
226 | # | 239 | # |
227 | CONFIG_HZ_100=y | 240 | CONFIG_HZ_100=y |
@@ -279,9 +292,6 @@ CONFIG_NET=y | |||
279 | # CONFIG_NETDEBUG is not set | 292 | # CONFIG_NETDEBUG is not set |
280 | # CONFIG_PACKET is not set | 293 | # CONFIG_PACKET is not set |
281 | # CONFIG_UNIX is not set | 294 | # CONFIG_UNIX is not set |
282 | CONFIG_XFRM=y | ||
283 | # CONFIG_XFRM_USER is not set | ||
284 | # CONFIG_XFRM_SUB_POLICY is not set | ||
285 | # CONFIG_NET_KEY is not set | 295 | # CONFIG_NET_KEY is not set |
286 | CONFIG_INET=y | 296 | CONFIG_INET=y |
287 | # CONFIG_IP_MULTICAST is not set | 297 | # CONFIG_IP_MULTICAST is not set |
@@ -297,9 +307,9 @@ CONFIG_IP_FIB_HASH=y | |||
297 | # CONFIG_INET_IPCOMP is not set | 307 | # CONFIG_INET_IPCOMP is not set |
298 | # CONFIG_INET_XFRM_TUNNEL is not set | 308 | # CONFIG_INET_XFRM_TUNNEL is not set |
299 | # CONFIG_INET_TUNNEL is not set | 309 | # CONFIG_INET_TUNNEL is not set |
300 | CONFIG_INET_XFRM_MODE_TRANSPORT=y | 310 | # CONFIG_INET_XFRM_MODE_TRANSPORT is not set |
301 | CONFIG_INET_XFRM_MODE_TUNNEL=y | 311 | # CONFIG_INET_XFRM_MODE_TUNNEL is not set |
302 | CONFIG_INET_XFRM_MODE_BEET=y | 312 | # CONFIG_INET_XFRM_MODE_BEET is not set |
303 | # CONFIG_INET_DIAG is not set | 313 | # CONFIG_INET_DIAG is not set |
304 | # CONFIG_TCP_CONG_ADVANCED is not set | 314 | # CONFIG_TCP_CONG_ADVANCED is not set |
305 | CONFIG_TCP_CONG_CUBIC=y | 315 | CONFIG_TCP_CONG_CUBIC=y |
@@ -371,7 +381,7 @@ CONFIG_DEFAULT_TCP_CONG="cubic" | |||
371 | # | 381 | # |
372 | CONFIG_MTD=y | 382 | CONFIG_MTD=y |
373 | # CONFIG_MTD_DEBUG is not set | 383 | # CONFIG_MTD_DEBUG is not set |
374 | # CONFIG_MTD_CONCAT is not set | 384 | CONFIG_MTD_CONCAT=y |
375 | CONFIG_MTD_PARTITIONS=y | 385 | CONFIG_MTD_PARTITIONS=y |
376 | CONFIG_MTD_REDBOOT_PARTS=y | 386 | CONFIG_MTD_REDBOOT_PARTS=y |
377 | CONFIG_MTD_REDBOOT_DIRECTORY_BLOCK=-1 | 387 | CONFIG_MTD_REDBOOT_DIRECTORY_BLOCK=-1 |
@@ -422,7 +432,7 @@ CONFIG_MTD_CFI_UTIL=y | |||
422 | # CONFIG_MTD_COMPLEX_MAPPINGS is not set | 432 | # CONFIG_MTD_COMPLEX_MAPPINGS is not set |
423 | CONFIG_MTD_PHYSMAP=y | 433 | CONFIG_MTD_PHYSMAP=y |
424 | CONFIG_MTD_PHYSMAP_START=0x20000000 | 434 | CONFIG_MTD_PHYSMAP_START=0x20000000 |
425 | CONFIG_MTD_PHYSMAP_LEN=0x1000000 | 435 | CONFIG_MTD_PHYSMAP_LEN=0x01000000 |
426 | CONFIG_MTD_PHYSMAP_BANKWIDTH=4 | 436 | CONFIG_MTD_PHYSMAP_BANKWIDTH=4 |
427 | # CONFIG_MTD_SOLUTIONENGINE is not set | 437 | # CONFIG_MTD_SOLUTIONENGINE is not set |
428 | # CONFIG_MTD_UCLINUX is not set | 438 | # CONFIG_MTD_UCLINUX is not set |
@@ -468,10 +478,7 @@ CONFIG_MTD_PHYSMAP_BANKWIDTH=4 | |||
468 | # CONFIG_BLK_DEV_COW_COMMON is not set | 478 | # CONFIG_BLK_DEV_COW_COMMON is not set |
469 | # CONFIG_BLK_DEV_LOOP is not set | 479 | # CONFIG_BLK_DEV_LOOP is not set |
470 | # CONFIG_BLK_DEV_NBD is not set | 480 | # CONFIG_BLK_DEV_NBD is not set |
471 | CONFIG_BLK_DEV_RAM=y | 481 | # CONFIG_BLK_DEV_RAM is not set |
472 | CONFIG_BLK_DEV_RAM_COUNT=16 | ||
473 | CONFIG_BLK_DEV_RAM_SIZE=4096 | ||
474 | CONFIG_BLK_DEV_RAM_BLOCKSIZE=1024 | ||
475 | # CONFIG_BLK_DEV_INITRD is not set | 482 | # CONFIG_BLK_DEV_INITRD is not set |
476 | # CONFIG_CDROM_PKTCDVD is not set | 483 | # CONFIG_CDROM_PKTCDVD is not set |
477 | # CONFIG_ATA_OVER_ETH is not set | 484 | # CONFIG_ATA_OVER_ETH is not set |
@@ -519,7 +526,50 @@ CONFIG_BLK_DEV_RAM_BLOCKSIZE=1024 | |||
519 | # | 526 | # |
520 | # Network device support | 527 | # Network device support |
521 | # | 528 | # |
522 | # CONFIG_NETDEVICES is not set | 529 | CONFIG_NETDEVICES=y |
530 | # CONFIG_DUMMY is not set | ||
531 | # CONFIG_BONDING is not set | ||
532 | # CONFIG_EQUALIZER is not set | ||
533 | # CONFIG_TUN is not set | ||
534 | |||
535 | # | ||
536 | # PHY device support | ||
537 | # | ||
538 | # CONFIG_PHYLIB is not set | ||
539 | |||
540 | # | ||
541 | # Ethernet (10 or 100Mbit) | ||
542 | # | ||
543 | CONFIG_NET_ETHERNET=y | ||
544 | CONFIG_MII=y | ||
545 | # CONFIG_STNIC is not set | ||
546 | CONFIG_SMC91X=y | ||
547 | |||
548 | # | ||
549 | # Ethernet (1000 Mbit) | ||
550 | # | ||
551 | |||
552 | # | ||
553 | # Ethernet (10000 Mbit) | ||
554 | # | ||
555 | |||
556 | # | ||
557 | # Token Ring devices | ||
558 | # | ||
559 | |||
560 | # | ||
561 | # Wireless LAN (non-hamradio) | ||
562 | # | ||
563 | # CONFIG_NET_RADIO is not set | ||
564 | |||
565 | # | ||
566 | # Wan interfaces | ||
567 | # | ||
568 | # CONFIG_WAN is not set | ||
569 | # CONFIG_PPP is not set | ||
570 | # CONFIG_SLIP is not set | ||
571 | # CONFIG_SHAPER is not set | ||
572 | # CONFIG_NETCONSOLE is not set | ||
523 | # CONFIG_NETPOLL is not set | 573 | # CONFIG_NETPOLL is not set |
524 | # CONFIG_NET_POLL_CONTROLLER is not set | 574 | # CONFIG_NET_POLL_CONTROLLER is not set |
525 | 575 | ||
@@ -536,7 +586,26 @@ CONFIG_BLK_DEV_RAM_BLOCKSIZE=1024 | |||
536 | # | 586 | # |
537 | # Input device support | 587 | # Input device support |
538 | # | 588 | # |
539 | # CONFIG_INPUT is not set | 589 | CONFIG_INPUT=y |
590 | # CONFIG_INPUT_FF_MEMLESS is not set | ||
591 | |||
592 | # | ||
593 | # Userland interfaces | ||
594 | # | ||
595 | # CONFIG_INPUT_MOUSEDEV is not set | ||
596 | # CONFIG_INPUT_JOYDEV is not set | ||
597 | # CONFIG_INPUT_TSDEV is not set | ||
598 | # CONFIG_INPUT_EVDEV is not set | ||
599 | # CONFIG_INPUT_EVBUG is not set | ||
600 | |||
601 | # | ||
602 | # Input Device Drivers | ||
603 | # | ||
604 | # CONFIG_INPUT_KEYBOARD is not set | ||
605 | # CONFIG_INPUT_MOUSE is not set | ||
606 | # CONFIG_INPUT_JOYSTICK is not set | ||
607 | # CONFIG_INPUT_TOUCHSCREEN is not set | ||
608 | # CONFIG_INPUT_MISC is not set | ||
540 | 609 | ||
541 | # | 610 | # |
542 | # Hardware I/O ports | 611 | # Hardware I/O ports |
@@ -564,8 +633,7 @@ CONFIG_SERIAL_SH_SCI_CONSOLE=y | |||
564 | CONFIG_SERIAL_CORE=y | 633 | CONFIG_SERIAL_CORE=y |
565 | CONFIG_SERIAL_CORE_CONSOLE=y | 634 | CONFIG_SERIAL_CORE_CONSOLE=y |
566 | # CONFIG_UNIX98_PTYS is not set | 635 | # CONFIG_UNIX98_PTYS is not set |
567 | CONFIG_LEGACY_PTYS=y | 636 | # CONFIG_LEGACY_PTYS is not set |
568 | CONFIG_LEGACY_PTY_COUNT=256 | ||
569 | 637 | ||
570 | # | 638 | # |
571 | # IPMI | 639 | # IPMI |
@@ -576,7 +644,7 @@ CONFIG_LEGACY_PTY_COUNT=256 | |||
576 | # Watchdog Cards | 644 | # Watchdog Cards |
577 | # | 645 | # |
578 | # CONFIG_WATCHDOG is not set | 646 | # CONFIG_WATCHDOG is not set |
579 | CONFIG_HW_RANDOM=y | 647 | # CONFIG_HW_RANDOM is not set |
580 | # CONFIG_GEN_RTC is not set | 648 | # CONFIG_GEN_RTC is not set |
581 | # CONFIG_DTLK is not set | 649 | # CONFIG_DTLK is not set |
582 | # CONFIG_R3964 is not set | 650 | # CONFIG_R3964 is not set |
@@ -610,12 +678,8 @@ CONFIG_HW_RANDOM=y | |||
610 | # | 678 | # |
611 | # Hardware Monitoring support | 679 | # Hardware Monitoring support |
612 | # | 680 | # |
613 | CONFIG_HWMON=y | 681 | # CONFIG_HWMON is not set |
614 | # CONFIG_HWMON_VID is not set | 682 | # CONFIG_HWMON_VID is not set |
615 | # CONFIG_SENSORS_ABITUGURU is not set | ||
616 | # CONFIG_SENSORS_F71805F is not set | ||
617 | # CONFIG_SENSORS_VT1211 is not set | ||
618 | # CONFIG_HWMON_DEBUG_CHIP is not set | ||
619 | 683 | ||
620 | # | 684 | # |
621 | # Multimedia devices | 685 | # Multimedia devices |
@@ -630,7 +694,7 @@ CONFIG_HWMON=y | |||
630 | # | 694 | # |
631 | # Graphics support | 695 | # Graphics support |
632 | # | 696 | # |
633 | CONFIG_FIRMWARE_EDID=y | 697 | # CONFIG_FIRMWARE_EDID is not set |
634 | # CONFIG_FB is not set | 698 | # CONFIG_FB is not set |
635 | 699 | ||
636 | # | 700 | # |
@@ -701,8 +765,7 @@ CONFIG_FIRMWARE_EDID=y | |||
701 | # | 765 | # |
702 | # File systems | 766 | # File systems |
703 | # | 767 | # |
704 | CONFIG_EXT2_FS=y | 768 | # CONFIG_EXT2_FS is not set |
705 | # CONFIG_EXT2_FS_XATTR is not set | ||
706 | # CONFIG_EXT3_FS is not set | 769 | # CONFIG_EXT3_FS is not set |
707 | # CONFIG_EXT4DEV_FS is not set | 770 | # CONFIG_EXT4DEV_FS is not set |
708 | # CONFIG_REISERFS_FS is not set | 771 | # CONFIG_REISERFS_FS is not set |
@@ -755,7 +818,7 @@ CONFIG_RAMFS=y | |||
755 | # CONFIG_EFS_FS is not set | 818 | # CONFIG_EFS_FS is not set |
756 | # CONFIG_JFFS_FS is not set | 819 | # CONFIG_JFFS_FS is not set |
757 | # CONFIG_JFFS2_FS is not set | 820 | # CONFIG_JFFS2_FS is not set |
758 | CONFIG_CRAMFS=y | 821 | # CONFIG_CRAMFS is not set |
759 | # CONFIG_VXFS_FS is not set | 822 | # CONFIG_VXFS_FS is not set |
760 | # CONFIG_HPFS_FS is not set | 823 | # CONFIG_HPFS_FS is not set |
761 | # CONFIG_QNX4FS_FS is not set | 824 | # CONFIG_QNX4FS_FS is not set |
@@ -793,8 +856,9 @@ CONFIG_MSDOS_PARTITION=y | |||
793 | # | 856 | # |
794 | # Kernel hacking | 857 | # Kernel hacking |
795 | # | 858 | # |
859 | CONFIG_TRACE_IRQFLAGS_SUPPORT=y | ||
796 | # CONFIG_PRINTK_TIME is not set | 860 | # CONFIG_PRINTK_TIME is not set |
797 | CONFIG_ENABLE_MUST_CHECK=y | 861 | # CONFIG_ENABLE_MUST_CHECK is not set |
798 | # CONFIG_MAGIC_SYSRQ is not set | 862 | # CONFIG_MAGIC_SYSRQ is not set |
799 | # CONFIG_UNUSED_SYMBOLS is not set | 863 | # CONFIG_UNUSED_SYMBOLS is not set |
800 | # CONFIG_DEBUG_KERNEL is not set | 864 | # CONFIG_DEBUG_KERNEL is not set |
@@ -819,7 +883,7 @@ CONFIG_LOG_BUF_SHIFT=14 | |||
819 | # | 883 | # |
820 | # Library routines | 884 | # Library routines |
821 | # | 885 | # |
822 | CONFIG_CRC_CCITT=y | 886 | # CONFIG_CRC_CCITT is not set |
823 | # CONFIG_CRC16 is not set | 887 | # CONFIG_CRC16 is not set |
824 | CONFIG_CRC32=y | 888 | CONFIG_CRC32=y |
825 | # CONFIG_LIBCRC32C is not set | 889 | # CONFIG_LIBCRC32C is not set |
diff --git a/arch/sh/configs/se7619_defconfig b/arch/sh/configs/se7619_defconfig new file mode 100644 index 000000000000..20ac7f4c53fb --- /dev/null +++ b/arch/sh/configs/se7619_defconfig | |||
@@ -0,0 +1,744 @@ | |||
1 | # | ||
2 | # Automatically generated make config: don't edit | ||
3 | # Linux kernel version: 2.6.19 | ||
4 | # Wed Dec 6 16:35:36 2006 | ||
5 | # | ||
6 | CONFIG_SUPERH=y | ||
7 | CONFIG_RWSEM_GENERIC_SPINLOCK=y | ||
8 | CONFIG_GENERIC_FIND_NEXT_BIT=y | ||
9 | CONFIG_GENERIC_HWEIGHT=y | ||
10 | CONFIG_GENERIC_HARDIRQS=y | ||
11 | CONFIG_GENERIC_IRQ_PROBE=y | ||
12 | CONFIG_GENERIC_CALIBRATE_DELAY=y | ||
13 | # CONFIG_GENERIC_TIME is not set | ||
14 | CONFIG_STACKTRACE_SUPPORT=y | ||
15 | CONFIG_LOCKDEP_SUPPORT=y | ||
16 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" | ||
17 | |||
18 | # | ||
19 | # Code maturity level options | ||
20 | # | ||
21 | CONFIG_EXPERIMENTAL=y | ||
22 | CONFIG_BROKEN_ON_SMP=y | ||
23 | CONFIG_INIT_ENV_ARG_LIMIT=32 | ||
24 | |||
25 | # | ||
26 | # General setup | ||
27 | # | ||
28 | CONFIG_LOCALVERSION="" | ||
29 | # CONFIG_LOCALVERSION_AUTO is not set | ||
30 | # CONFIG_SYSVIPC is not set | ||
31 | # CONFIG_BSD_PROCESS_ACCT is not set | ||
32 | # CONFIG_UTS_NS is not set | ||
33 | # CONFIG_IKCONFIG is not set | ||
34 | # CONFIG_RELAY is not set | ||
35 | CONFIG_INITRAMFS_SOURCE="" | ||
36 | CONFIG_CC_OPTIMIZE_FOR_SIZE=y | ||
37 | CONFIG_SYSCTL=y | ||
38 | CONFIG_EMBEDDED=y | ||
39 | # CONFIG_UID16 is not set | ||
40 | # CONFIG_SYSCTL_SYSCALL is not set | ||
41 | # CONFIG_KALLSYMS is not set | ||
42 | # CONFIG_HOTPLUG is not set | ||
43 | CONFIG_PRINTK=y | ||
44 | CONFIG_BUG=y | ||
45 | # CONFIG_ELF_CORE is not set | ||
46 | # CONFIG_BASE_FULL is not set | ||
47 | # CONFIG_FUTEX is not set | ||
48 | # CONFIG_EPOLL is not set | ||
49 | CONFIG_SLAB=y | ||
50 | # CONFIG_VM_EVENT_COUNTERS is not set | ||
51 | CONFIG_TINY_SHMEM=y | ||
52 | CONFIG_BASE_SMALL=1 | ||
53 | # CONFIG_SLOB is not set | ||
54 | |||
55 | # | ||
56 | # Loadable module support | ||
57 | # | ||
58 | # CONFIG_MODULES is not set | ||
59 | |||
60 | # | ||
61 | # Block layer | ||
62 | # | ||
63 | CONFIG_BLOCK=y | ||
64 | # CONFIG_LBD is not set | ||
65 | # CONFIG_LSF is not set | ||
66 | |||
67 | # | ||
68 | # IO Schedulers | ||
69 | # | ||
70 | CONFIG_IOSCHED_NOOP=y | ||
71 | # CONFIG_IOSCHED_AS is not set | ||
72 | # CONFIG_IOSCHED_DEADLINE is not set | ||
73 | # CONFIG_IOSCHED_CFQ is not set | ||
74 | # CONFIG_DEFAULT_AS is not set | ||
75 | # CONFIG_DEFAULT_DEADLINE is not set | ||
76 | # CONFIG_DEFAULT_CFQ is not set | ||
77 | CONFIG_DEFAULT_NOOP=y | ||
78 | CONFIG_DEFAULT_IOSCHED="noop" | ||
79 | |||
80 | # | ||
81 | # System type | ||
82 | # | ||
83 | # CONFIG_SH_SOLUTION_ENGINE is not set | ||
84 | # CONFIG_SH_7751_SOLUTION_ENGINE is not set | ||
85 | # CONFIG_SH_7300_SOLUTION_ENGINE is not set | ||
86 | # CONFIG_SH_7343_SOLUTION_ENGINE is not set | ||
87 | # CONFIG_SH_73180_SOLUTION_ENGINE is not set | ||
88 | # CONFIG_SH_7751_SYSTEMH is not set | ||
89 | # CONFIG_SH_HP6XX is not set | ||
90 | # CONFIG_SH_EC3104 is not set | ||
91 | # CONFIG_SH_SATURN is not set | ||
92 | # CONFIG_SH_DREAMCAST is not set | ||
93 | # CONFIG_SH_BIGSUR is not set | ||
94 | # CONFIG_SH_MPC1211 is not set | ||
95 | # CONFIG_SH_SH03 is not set | ||
96 | # CONFIG_SH_SECUREEDGE5410 is not set | ||
97 | # CONFIG_SH_HS7751RVOIP is not set | ||
98 | # CONFIG_SH_7710VOIPGW is not set | ||
99 | # CONFIG_SH_RTS7751R2D is not set | ||
100 | # CONFIG_SH_R7780RP is not set | ||
101 | # CONFIG_SH_EDOSK7705 is not set | ||
102 | # CONFIG_SH_SH4202_MICRODEV is not set | ||
103 | # CONFIG_SH_LANDISK is not set | ||
104 | # CONFIG_SH_TITAN is not set | ||
105 | # CONFIG_SH_SHMIN is not set | ||
106 | # CONFIG_SH_7206_SOLUTION_ENGINE is not set | ||
107 | CONFIG_SH_7619_SOLUTION_ENGINE=y | ||
108 | # CONFIG_SH_UNKNOWN is not set | ||
109 | |||
110 | # | ||
111 | # Processor selection | ||
112 | # | ||
113 | CONFIG_CPU_SH2=y | ||
114 | |||
115 | # | ||
116 | # SH-2 Processor Support | ||
117 | # | ||
118 | # CONFIG_CPU_SUBTYPE_SH7604 is not set | ||
119 | CONFIG_CPU_SUBTYPE_SH7619=y | ||
120 | |||
121 | # | ||
122 | # SH-2A Processor Support | ||
123 | # | ||
124 | # CONFIG_CPU_SUBTYPE_SH7206 is not set | ||
125 | |||
126 | # | ||
127 | # SH-3 Processor Support | ||
128 | # | ||
129 | # CONFIG_CPU_SUBTYPE_SH7300 is not set | ||
130 | # CONFIG_CPU_SUBTYPE_SH7705 is not set | ||
131 | # CONFIG_CPU_SUBTYPE_SH7706 is not set | ||
132 | # CONFIG_CPU_SUBTYPE_SH7707 is not set | ||
133 | # CONFIG_CPU_SUBTYPE_SH7708 is not set | ||
134 | # CONFIG_CPU_SUBTYPE_SH7709 is not set | ||
135 | # CONFIG_CPU_SUBTYPE_SH7710 is not set | ||
136 | |||
137 | # | ||
138 | # SH-4 Processor Support | ||
139 | # | ||
140 | # CONFIG_CPU_SUBTYPE_SH7750 is not set | ||
141 | # CONFIG_CPU_SUBTYPE_SH7091 is not set | ||
142 | # CONFIG_CPU_SUBTYPE_SH7750R is not set | ||
143 | # CONFIG_CPU_SUBTYPE_SH7750S is not set | ||
144 | # CONFIG_CPU_SUBTYPE_SH7751 is not set | ||
145 | # CONFIG_CPU_SUBTYPE_SH7751R is not set | ||
146 | # CONFIG_CPU_SUBTYPE_SH7760 is not set | ||
147 | # CONFIG_CPU_SUBTYPE_SH4_202 is not set | ||
148 | |||
149 | # | ||
150 | # ST40 Processor Support | ||
151 | # | ||
152 | # CONFIG_CPU_SUBTYPE_ST40STB1 is not set | ||
153 | # CONFIG_CPU_SUBTYPE_ST40GX1 is not set | ||
154 | |||
155 | # | ||
156 | # SH-4A Processor Support | ||
157 | # | ||
158 | # CONFIG_CPU_SUBTYPE_SH7770 is not set | ||
159 | # CONFIG_CPU_SUBTYPE_SH7780 is not set | ||
160 | # CONFIG_CPU_SUBTYPE_SH7785 is not set | ||
161 | |||
162 | # | ||
163 | # SH4AL-DSP Processor Support | ||
164 | # | ||
165 | # CONFIG_CPU_SUBTYPE_SH73180 is not set | ||
166 | # CONFIG_CPU_SUBTYPE_SH7343 is not set | ||
167 | |||
168 | # | ||
169 | # Memory management options | ||
170 | # | ||
171 | CONFIG_PAGE_OFFSET=0x00000000 | ||
172 | CONFIG_MEMORY_START=0x0c000000 | ||
173 | CONFIG_MEMORY_SIZE=0x04000000 | ||
174 | CONFIG_PAGE_SIZE_4KB=y | ||
175 | # CONFIG_PAGE_SIZE_8KB is not set | ||
176 | # CONFIG_PAGE_SIZE_64KB is not set | ||
177 | CONFIG_SELECT_MEMORY_MODEL=y | ||
178 | CONFIG_FLATMEM_MANUAL=y | ||
179 | # CONFIG_DISCONTIGMEM_MANUAL is not set | ||
180 | # CONFIG_SPARSEMEM_MANUAL is not set | ||
181 | CONFIG_FLATMEM=y | ||
182 | CONFIG_FLAT_NODE_MEM_MAP=y | ||
183 | # CONFIG_SPARSEMEM_STATIC is not set | ||
184 | CONFIG_SPLIT_PTLOCK_CPUS=4 | ||
185 | # CONFIG_RESOURCES_64BIT is not set | ||
186 | |||
187 | # | ||
188 | # Cache configuration | ||
189 | # | ||
190 | # CONFIG_SH_DIRECT_MAPPED is not set | ||
191 | CONFIG_SH_WRITETHROUGH=y | ||
192 | # CONFIG_SH_OCRAM is not set | ||
193 | |||
194 | # | ||
195 | # Processor features | ||
196 | # | ||
197 | # CONFIG_CPU_LITTLE_ENDIAN is not set | ||
198 | CONFIG_CPU_BIG_ENDIAN=y | ||
199 | # CONFIG_SH_FPU is not set | ||
200 | # CONFIG_SH_FPU_EMU is not set | ||
201 | # CONFIG_SH_DSP is not set | ||
202 | |||
203 | # | ||
204 | # Timer support | ||
205 | # | ||
206 | CONFIG_SH_CMT=y | ||
207 | CONFIG_SH_TIMER_IRQ=86 | ||
208 | # CONFIG_NO_IDLE_HZ is not set | ||
209 | CONFIG_SH_PCLK_FREQ=31250000 | ||
210 | CONFIG_SH_CLK_MD=5 | ||
211 | |||
212 | # | ||
213 | # CPU Frequency scaling | ||
214 | # | ||
215 | # CONFIG_CPU_FREQ is not set | ||
216 | |||
217 | # | ||
218 | # DMA support | ||
219 | # | ||
220 | # CONFIG_SH_DMA is not set | ||
221 | |||
222 | # | ||
223 | # Companion Chips | ||
224 | # | ||
225 | # CONFIG_HD6446X_SERIES is not set | ||
226 | |||
227 | # | ||
228 | # Additional SuperH Device Drivers | ||
229 | # | ||
230 | # CONFIG_PUSH_SWITCH is not set | ||
231 | |||
232 | # | ||
233 | # Kernel features | ||
234 | # | ||
235 | CONFIG_HZ_100=y | ||
236 | # CONFIG_HZ_250 is not set | ||
237 | # CONFIG_HZ_1000 is not set | ||
238 | CONFIG_HZ=100 | ||
239 | # CONFIG_KEXEC is not set | ||
240 | # CONFIG_SMP is not set | ||
241 | CONFIG_PREEMPT_NONE=y | ||
242 | # CONFIG_PREEMPT_VOLUNTARY is not set | ||
243 | # CONFIG_PREEMPT is not set | ||
244 | |||
245 | # | ||
246 | # Boot options | ||
247 | # | ||
248 | CONFIG_ZERO_PAGE_OFFSET=0x00001000 | ||
249 | CONFIG_BOOT_LINK_OFFSET=0x00800000 | ||
250 | # CONFIG_UBC_WAKEUP is not set | ||
251 | # CONFIG_CMDLINE_BOOL is not set | ||
252 | |||
253 | # | ||
254 | # Bus options | ||
255 | # | ||
256 | # CONFIG_PCI is not set | ||
257 | |||
258 | # | ||
259 | # PCCARD (PCMCIA/CardBus) support | ||
260 | # | ||
261 | |||
262 | # | ||
263 | # PCI Hotplug Support | ||
264 | # | ||
265 | |||
266 | # | ||
267 | # Executable file formats | ||
268 | # | ||
269 | CONFIG_BINFMT_FLAT=y | ||
270 | CONFIG_BINFMT_ZFLAT=y | ||
271 | # CONFIG_BINFMT_SHARED_FLAT is not set | ||
272 | # CONFIG_BINFMT_MISC is not set | ||
273 | |||
274 | # | ||
275 | # Power management options (EXPERIMENTAL) | ||
276 | # | ||
277 | # CONFIG_PM is not set | ||
278 | |||
279 | # | ||
280 | # Networking | ||
281 | # | ||
282 | # CONFIG_NET is not set | ||
283 | |||
284 | # | ||
285 | # Device Drivers | ||
286 | # | ||
287 | |||
288 | # | ||
289 | # Generic Driver Options | ||
290 | # | ||
291 | # CONFIG_STANDALONE is not set | ||
292 | # CONFIG_PREVENT_FIRMWARE_BUILD is not set | ||
293 | # CONFIG_SYS_HYPERVISOR is not set | ||
294 | |||
295 | # | ||
296 | # Connector - unified userspace <-> kernelspace linker | ||
297 | # | ||
298 | |||
299 | # | ||
300 | # Memory Technology Devices (MTD) | ||
301 | # | ||
302 | CONFIG_MTD=y | ||
303 | # CONFIG_MTD_DEBUG is not set | ||
304 | CONFIG_MTD_CONCAT=y | ||
305 | CONFIG_MTD_PARTITIONS=y | ||
306 | CONFIG_MTD_REDBOOT_PARTS=y | ||
307 | CONFIG_MTD_REDBOOT_DIRECTORY_BLOCK=-1 | ||
308 | # CONFIG_MTD_REDBOOT_PARTS_UNALLOCATED is not set | ||
309 | # CONFIG_MTD_REDBOOT_PARTS_READONLY is not set | ||
310 | # CONFIG_MTD_CMDLINE_PARTS is not set | ||
311 | |||
312 | # | ||
313 | # User Modules And Translation Layers | ||
314 | # | ||
315 | CONFIG_MTD_CHAR=y | ||
316 | CONFIG_MTD_BLOCK=y | ||
317 | # CONFIG_FTL is not set | ||
318 | # CONFIG_NFTL is not set | ||
319 | # CONFIG_INFTL is not set | ||
320 | # CONFIG_RFD_FTL is not set | ||
321 | # CONFIG_SSFDC is not set | ||
322 | |||
323 | # | ||
324 | # RAM/ROM/Flash chip drivers | ||
325 | # | ||
326 | CONFIG_MTD_CFI=y | ||
327 | # CONFIG_MTD_JEDECPROBE is not set | ||
328 | CONFIG_MTD_GEN_PROBE=y | ||
329 | # CONFIG_MTD_CFI_ADV_OPTIONS is not set | ||
330 | CONFIG_MTD_MAP_BANK_WIDTH_1=y | ||
331 | CONFIG_MTD_MAP_BANK_WIDTH_2=y | ||
332 | CONFIG_MTD_MAP_BANK_WIDTH_4=y | ||
333 | # CONFIG_MTD_MAP_BANK_WIDTH_8 is not set | ||
334 | # CONFIG_MTD_MAP_BANK_WIDTH_16 is not set | ||
335 | # CONFIG_MTD_MAP_BANK_WIDTH_32 is not set | ||
336 | CONFIG_MTD_CFI_I1=y | ||
337 | CONFIG_MTD_CFI_I2=y | ||
338 | # CONFIG_MTD_CFI_I4 is not set | ||
339 | # CONFIG_MTD_CFI_I8 is not set | ||
340 | # CONFIG_MTD_CFI_INTELEXT is not set | ||
341 | CONFIG_MTD_CFI_AMDSTD=y | ||
342 | # CONFIG_MTD_CFI_STAA is not set | ||
343 | CONFIG_MTD_CFI_UTIL=y | ||
344 | # CONFIG_MTD_RAM is not set | ||
345 | # CONFIG_MTD_ROM is not set | ||
346 | # CONFIG_MTD_ABSENT is not set | ||
347 | # CONFIG_MTD_OBSOLETE_CHIPS is not set | ||
348 | |||
349 | # | ||
350 | # Mapping drivers for chip access | ||
351 | # | ||
352 | # CONFIG_MTD_COMPLEX_MAPPINGS is not set | ||
353 | CONFIG_MTD_PHYSMAP=y | ||
354 | CONFIG_MTD_PHYSMAP_START=0xa0000000 | ||
355 | CONFIG_MTD_PHYSMAP_LEN=0x01000000 | ||
356 | CONFIG_MTD_PHYSMAP_BANKWIDTH=2 | ||
357 | # CONFIG_MTD_SOLUTIONENGINE is not set | ||
358 | # CONFIG_MTD_UCLINUX is not set | ||
359 | # CONFIG_MTD_PLATRAM is not set | ||
360 | |||
361 | # | ||
362 | # Self-contained MTD device drivers | ||
363 | # | ||
364 | # CONFIG_MTD_SLRAM is not set | ||
365 | # CONFIG_MTD_PHRAM is not set | ||
366 | # CONFIG_MTD_MTDRAM is not set | ||
367 | # CONFIG_MTD_BLOCK2MTD is not set | ||
368 | |||
369 | # | ||
370 | # Disk-On-Chip Device Drivers | ||
371 | # | ||
372 | # CONFIG_MTD_DOC2000 is not set | ||
373 | # CONFIG_MTD_DOC2001 is not set | ||
374 | # CONFIG_MTD_DOC2001PLUS is not set | ||
375 | |||
376 | # | ||
377 | # NAND Flash Device Drivers | ||
378 | # | ||
379 | # CONFIG_MTD_NAND is not set | ||
380 | |||
381 | # | ||
382 | # OneNAND Flash Device Drivers | ||
383 | # | ||
384 | # CONFIG_MTD_ONENAND is not set | ||
385 | |||
386 | # | ||
387 | # Parallel port support | ||
388 | # | ||
389 | # CONFIG_PARPORT is not set | ||
390 | |||
391 | # | ||
392 | # Plug and Play support | ||
393 | # | ||
394 | |||
395 | # | ||
396 | # Block devices | ||
397 | # | ||
398 | # CONFIG_BLK_DEV_COW_COMMON is not set | ||
399 | # CONFIG_BLK_DEV_LOOP is not set | ||
400 | # CONFIG_BLK_DEV_RAM is not set | ||
401 | # CONFIG_BLK_DEV_INITRD is not set | ||
402 | # CONFIG_CDROM_PKTCDVD is not set | ||
403 | |||
404 | # | ||
405 | # Misc devices | ||
406 | # | ||
407 | # CONFIG_TIFM_CORE is not set | ||
408 | |||
409 | # | ||
410 | # ATA/ATAPI/MFM/RLL support | ||
411 | # | ||
412 | # CONFIG_IDE is not set | ||
413 | |||
414 | # | ||
415 | # SCSI device support | ||
416 | # | ||
417 | # CONFIG_RAID_ATTRS is not set | ||
418 | # CONFIG_SCSI is not set | ||
419 | # CONFIG_SCSI_NETLINK is not set | ||
420 | |||
421 | # | ||
422 | # Serial ATA (prod) and Parallel ATA (experimental) drivers | ||
423 | # | ||
424 | # CONFIG_ATA is not set | ||
425 | |||
426 | # | ||
427 | # Multi-device support (RAID and LVM) | ||
428 | # | ||
429 | # CONFIG_MD is not set | ||
430 | |||
431 | # | ||
432 | # Fusion MPT device support | ||
433 | # | ||
434 | # CONFIG_FUSION is not set | ||
435 | |||
436 | # | ||
437 | # IEEE 1394 (FireWire) support | ||
438 | # | ||
439 | |||
440 | # | ||
441 | # I2O device support | ||
442 | # | ||
443 | |||
444 | # | ||
445 | # ISDN subsystem | ||
446 | # | ||
447 | |||
448 | # | ||
449 | # Telephony Support | ||
450 | # | ||
451 | # CONFIG_PHONE is not set | ||
452 | |||
453 | # | ||
454 | # Input device support | ||
455 | # | ||
456 | CONFIG_INPUT=y | ||
457 | # CONFIG_INPUT_FF_MEMLESS is not set | ||
458 | |||
459 | # | ||
460 | # Userland interfaces | ||
461 | # | ||
462 | # CONFIG_INPUT_MOUSEDEV is not set | ||
463 | # CONFIG_INPUT_JOYDEV is not set | ||
464 | # CONFIG_INPUT_TSDEV is not set | ||
465 | # CONFIG_INPUT_EVDEV is not set | ||
466 | # CONFIG_INPUT_EVBUG is not set | ||
467 | |||
468 | # | ||
469 | # Input Device Drivers | ||
470 | # | ||
471 | # CONFIG_INPUT_KEYBOARD is not set | ||
472 | # CONFIG_INPUT_MOUSE is not set | ||
473 | # CONFIG_INPUT_JOYSTICK is not set | ||
474 | # CONFIG_INPUT_TOUCHSCREEN is not set | ||
475 | # CONFIG_INPUT_MISC is not set | ||
476 | |||
477 | # | ||
478 | # Hardware I/O ports | ||
479 | # | ||
480 | # CONFIG_SERIO is not set | ||
481 | # CONFIG_GAMEPORT is not set | ||
482 | |||
483 | # | ||
484 | # Character devices | ||
485 | # | ||
486 | # CONFIG_VT is not set | ||
487 | # CONFIG_SERIAL_NONSTANDARD is not set | ||
488 | |||
489 | # | ||
490 | # Serial drivers | ||
491 | # | ||
492 | # CONFIG_SERIAL_8250 is not set | ||
493 | |||
494 | # | ||
495 | # Non-8250 serial port support | ||
496 | # | ||
497 | CONFIG_SERIAL_SH_SCI=y | ||
498 | CONFIG_SERIAL_SH_SCI_NR_UARTS=3 | ||
499 | CONFIG_SERIAL_SH_SCI_CONSOLE=y | ||
500 | CONFIG_SERIAL_CORE=y | ||
501 | CONFIG_SERIAL_CORE_CONSOLE=y | ||
502 | # CONFIG_UNIX98_PTYS is not set | ||
503 | # CONFIG_LEGACY_PTYS is not set | ||
504 | |||
505 | # | ||
506 | # IPMI | ||
507 | # | ||
508 | # CONFIG_IPMI_HANDLER is not set | ||
509 | |||
510 | # | ||
511 | # Watchdog Cards | ||
512 | # | ||
513 | # CONFIG_WATCHDOG is not set | ||
514 | # CONFIG_HW_RANDOM is not set | ||
515 | # CONFIG_GEN_RTC is not set | ||
516 | # CONFIG_DTLK is not set | ||
517 | # CONFIG_R3964 is not set | ||
518 | |||
519 | # | ||
520 | # Ftape, the floppy tape device driver | ||
521 | # | ||
522 | # CONFIG_RAW_DRIVER is not set | ||
523 | |||
524 | # | ||
525 | # TPM devices | ||
526 | # | ||
527 | # CONFIG_TCG_TPM is not set | ||
528 | |||
529 | # | ||
530 | # I2C support | ||
531 | # | ||
532 | # CONFIG_I2C is not set | ||
533 | |||
534 | # | ||
535 | # SPI support | ||
536 | # | ||
537 | # CONFIG_SPI is not set | ||
538 | # CONFIG_SPI_MASTER is not set | ||
539 | |||
540 | # | ||
541 | # Dallas's 1-wire bus | ||
542 | # | ||
543 | # CONFIG_W1 is not set | ||
544 | |||
545 | # | ||
546 | # Hardware Monitoring support | ||
547 | # | ||
548 | # CONFIG_HWMON is not set | ||
549 | # CONFIG_HWMON_VID is not set | ||
550 | |||
551 | # | ||
552 | # Multimedia devices | ||
553 | # | ||
554 | # CONFIG_VIDEO_DEV is not set | ||
555 | |||
556 | # | ||
557 | # Digital Video Broadcasting Devices | ||
558 | # | ||
559 | |||
560 | # | ||
561 | # Graphics support | ||
562 | # | ||
563 | # CONFIG_FIRMWARE_EDID is not set | ||
564 | # CONFIG_FB is not set | ||
565 | |||
566 | # | ||
567 | # Sound | ||
568 | # | ||
569 | # CONFIG_SOUND is not set | ||
570 | |||
571 | # | ||
572 | # USB support | ||
573 | # | ||
574 | # CONFIG_USB_ARCH_HAS_HCD is not set | ||
575 | # CONFIG_USB_ARCH_HAS_OHCI is not set | ||
576 | # CONFIG_USB_ARCH_HAS_EHCI is not set | ||
577 | |||
578 | # | ||
579 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' | ||
580 | # | ||
581 | |||
582 | # | ||
583 | # USB Gadget Support | ||
584 | # | ||
585 | # CONFIG_USB_GADGET is not set | ||
586 | |||
587 | # | ||
588 | # MMC/SD Card support | ||
589 | # | ||
590 | # CONFIG_MMC is not set | ||
591 | |||
592 | # | ||
593 | # LED devices | ||
594 | # | ||
595 | # CONFIG_NEW_LEDS is not set | ||
596 | |||
597 | # | ||
598 | # LED drivers | ||
599 | # | ||
600 | |||
601 | # | ||
602 | # LED Triggers | ||
603 | # | ||
604 | |||
605 | # | ||
606 | # InfiniBand support | ||
607 | # | ||
608 | |||
609 | # | ||
610 | # EDAC - error detection and reporting (RAS) (EXPERIMENTAL) | ||
611 | # | ||
612 | |||
613 | # | ||
614 | # Real Time Clock | ||
615 | # | ||
616 | # CONFIG_RTC_CLASS is not set | ||
617 | |||
618 | # | ||
619 | # DMA Engine support | ||
620 | # | ||
621 | # CONFIG_DMA_ENGINE is not set | ||
622 | |||
623 | # | ||
624 | # DMA Clients | ||
625 | # | ||
626 | |||
627 | # | ||
628 | # DMA Devices | ||
629 | # | ||
630 | |||
631 | # | ||
632 | # File systems | ||
633 | # | ||
634 | # CONFIG_EXT2_FS is not set | ||
635 | # CONFIG_EXT3_FS is not set | ||
636 | # CONFIG_EXT4DEV_FS is not set | ||
637 | # CONFIG_REISERFS_FS is not set | ||
638 | # CONFIG_JFS_FS is not set | ||
639 | # CONFIG_FS_POSIX_ACL is not set | ||
640 | # CONFIG_XFS_FS is not set | ||
641 | # CONFIG_GFS2_FS is not set | ||
642 | # CONFIG_MINIX_FS is not set | ||
643 | CONFIG_ROMFS_FS=y | ||
644 | # CONFIG_INOTIFY is not set | ||
645 | # CONFIG_QUOTA is not set | ||
646 | # CONFIG_DNOTIFY is not set | ||
647 | # CONFIG_AUTOFS_FS is not set | ||
648 | # CONFIG_AUTOFS4_FS is not set | ||
649 | # CONFIG_FUSE_FS is not set | ||
650 | |||
651 | # | ||
652 | # CD-ROM/DVD Filesystems | ||
653 | # | ||
654 | # CONFIG_ISO9660_FS is not set | ||
655 | # CONFIG_UDF_FS is not set | ||
656 | |||
657 | # | ||
658 | # DOS/FAT/NT Filesystems | ||
659 | # | ||
660 | # CONFIG_MSDOS_FS is not set | ||
661 | # CONFIG_VFAT_FS is not set | ||
662 | # CONFIG_NTFS_FS is not set | ||
663 | |||
664 | # | ||
665 | # Pseudo filesystems | ||
666 | # | ||
667 | CONFIG_PROC_FS=y | ||
668 | CONFIG_PROC_SYSCTL=y | ||
669 | # CONFIG_SYSFS is not set | ||
670 | # CONFIG_TMPFS is not set | ||
671 | # CONFIG_HUGETLBFS is not set | ||
672 | # CONFIG_HUGETLB_PAGE is not set | ||
673 | CONFIG_RAMFS=y | ||
674 | |||
675 | # | ||
676 | # Miscellaneous filesystems | ||
677 | # | ||
678 | # CONFIG_ADFS_FS is not set | ||
679 | # CONFIG_AFFS_FS is not set | ||
680 | # CONFIG_HFS_FS is not set | ||
681 | # CONFIG_HFSPLUS_FS is not set | ||
682 | # CONFIG_BEFS_FS is not set | ||
683 | # CONFIG_BFS_FS is not set | ||
684 | # CONFIG_EFS_FS is not set | ||
685 | # CONFIG_JFFS_FS is not set | ||
686 | # CONFIG_JFFS2_FS is not set | ||
687 | # CONFIG_CRAMFS is not set | ||
688 | # CONFIG_VXFS_FS is not set | ||
689 | # CONFIG_HPFS_FS is not set | ||
690 | # CONFIG_QNX4FS_FS is not set | ||
691 | # CONFIG_SYSV_FS is not set | ||
692 | # CONFIG_UFS_FS is not set | ||
693 | |||
694 | # | ||
695 | # Partition Types | ||
696 | # | ||
697 | # CONFIG_PARTITION_ADVANCED is not set | ||
698 | CONFIG_MSDOS_PARTITION=y | ||
699 | |||
700 | # | ||
701 | # Native Language Support | ||
702 | # | ||
703 | # CONFIG_NLS is not set | ||
704 | |||
705 | # | ||
706 | # Profiling support | ||
707 | # | ||
708 | # CONFIG_PROFILING is not set | ||
709 | |||
710 | # | ||
711 | # Kernel hacking | ||
712 | # | ||
713 | CONFIG_TRACE_IRQFLAGS_SUPPORT=y | ||
714 | # CONFIG_PRINTK_TIME is not set | ||
715 | # CONFIG_ENABLE_MUST_CHECK is not set | ||
716 | # CONFIG_MAGIC_SYSRQ is not set | ||
717 | # CONFIG_UNUSED_SYMBOLS is not set | ||
718 | # CONFIG_DEBUG_KERNEL is not set | ||
719 | CONFIG_LOG_BUF_SHIFT=14 | ||
720 | # CONFIG_DEBUG_BUGVERBOSE is not set | ||
721 | # CONFIG_UNWIND_INFO is not set | ||
722 | # CONFIG_HEADERS_CHECK is not set | ||
723 | # CONFIG_SH_STANDARD_BIOS is not set | ||
724 | # CONFIG_EARLY_SCIF_CONSOLE is not set | ||
725 | # CONFIG_KGDB is not set | ||
726 | |||
727 | # | ||
728 | # Security options | ||
729 | # | ||
730 | # CONFIG_KEYS is not set | ||
731 | |||
732 | # | ||
733 | # Cryptographic options | ||
734 | # | ||
735 | # CONFIG_CRYPTO is not set | ||
736 | |||
737 | # | ||
738 | # Library routines | ||
739 | # | ||
740 | # CONFIG_CRC_CCITT is not set | ||
741 | # CONFIG_CRC16 is not set | ||
742 | CONFIG_CRC32=y | ||
743 | # CONFIG_LIBCRC32C is not set | ||
744 | CONFIG_ZLIB_INFLATE=y | ||
diff --git a/arch/sh/drivers/push-switch.c b/arch/sh/drivers/push-switch.c index f2b9157c314f..b3d20c0e021f 100644 --- a/arch/sh/drivers/push-switch.c +++ b/arch/sh/drivers/push-switch.c | |||
@@ -14,7 +14,7 @@ | |||
14 | #include <asm/push-switch.h> | 14 | #include <asm/push-switch.h> |
15 | 15 | ||
16 | #define DRV_NAME "push-switch" | 16 | #define DRV_NAME "push-switch" |
17 | #define DRV_VERSION "0.1.0" | 17 | #define DRV_VERSION "0.1.1" |
18 | 18 | ||
19 | static ssize_t switch_show(struct device *dev, | 19 | static ssize_t switch_show(struct device *dev, |
20 | struct device_attribute *attr, | 20 | struct device_attribute *attr, |
@@ -32,10 +32,10 @@ static void switch_timer(unsigned long data) | |||
32 | schedule_work(&psw->work); | 32 | schedule_work(&psw->work); |
33 | } | 33 | } |
34 | 34 | ||
35 | static void switch_work_handler(void *data) | 35 | static void switch_work_handler(struct work_struct *work) |
36 | { | 36 | { |
37 | struct platform_device *pdev = data; | 37 | struct push_switch *psw = container_of(work, struct push_switch, work); |
38 | struct push_switch *psw = platform_get_drvdata(pdev); | 38 | struct platform_device *pdev = psw->pdev; |
39 | 39 | ||
40 | psw->state = 0; | 40 | psw->state = 0; |
41 | 41 | ||
@@ -76,12 +76,15 @@ static int switch_drv_probe(struct platform_device *pdev) | |||
76 | } | 76 | } |
77 | } | 77 | } |
78 | 78 | ||
79 | INIT_WORK(&psw->work, switch_work_handler, pdev); | 79 | INIT_WORK(&psw->work, switch_work_handler); |
80 | init_timer(&psw->debounce); | 80 | init_timer(&psw->debounce); |
81 | 81 | ||
82 | psw->debounce.function = switch_timer; | 82 | psw->debounce.function = switch_timer; |
83 | psw->debounce.data = (unsigned long)psw; | 83 | psw->debounce.data = (unsigned long)psw; |
84 | 84 | ||
85 | /* Workqueue API brain-damage */ | ||
86 | psw->pdev = pdev; | ||
87 | |||
85 | platform_set_drvdata(pdev, psw); | 88 | platform_set_drvdata(pdev, psw); |
86 | 89 | ||
87 | return 0; | 90 | return 0; |
diff --git a/arch/sh/kernel/cpu/Makefile b/arch/sh/kernel/cpu/Makefile index 0582e6712b79..d055a3ea6b4b 100644 --- a/arch/sh/kernel/cpu/Makefile +++ b/arch/sh/kernel/cpu/Makefile | |||
@@ -6,6 +6,7 @@ obj-$(CONFIG_CPU_SH2) = sh2/ | |||
6 | obj-$(CONFIG_CPU_SH2A) = sh2a/ | 6 | obj-$(CONFIG_CPU_SH2A) = sh2a/ |
7 | obj-$(CONFIG_CPU_SH3) = sh3/ | 7 | obj-$(CONFIG_CPU_SH3) = sh3/ |
8 | obj-$(CONFIG_CPU_SH4) = sh4/ | 8 | obj-$(CONFIG_CPU_SH4) = sh4/ |
9 | obj-$(CONFIG_CPU_SH4A) += sh4a/ | ||
9 | 10 | ||
10 | obj-$(CONFIG_UBC_WAKEUP) += ubc.o | 11 | obj-$(CONFIG_UBC_WAKEUP) += ubc.o |
11 | obj-$(CONFIG_SH_ADC) += adc.o | 12 | obj-$(CONFIG_SH_ADC) += adc.o |
diff --git a/arch/sh/kernel/cpu/sh2/entry.S b/arch/sh/kernel/cpu/sh2/entry.S index 34d51b3745ea..d51fa5e9904a 100644 --- a/arch/sh/kernel/cpu/sh2/entry.S +++ b/arch/sh/kernel/cpu/sh2/entry.S | |||
@@ -177,15 +177,21 @@ interrupt_entry: | |||
177 | 7: .long do_IRQ | 177 | 7: .long do_IRQ |
178 | 8: .long do_exception_error | 178 | 8: .long do_exception_error |
179 | 179 | ||
180 | trap_entry: | 180 | trap_entry: |
181 | add #-0x10,r9 | 181 | /* verbose BUG trapa entry check */ |
182 | mov #0x3e,r8 | ||
183 | cmp/ge r8,r9 | ||
184 | bf/s 1f | ||
185 | add #-0x10,r9 | ||
186 | add #0x10,r9 | ||
187 | 1: | ||
182 | shll2 r9 ! TRA | 188 | shll2 r9 ! TRA |
183 | mov #OFF_TRA,r8 | 189 | mov #OFF_TRA,r8 |
184 | add r15,r8 | 190 | add r15,r8 |
185 | mov.l r9,@r8 | 191 | mov.l r9,@r8 |
186 | mov r9,r8 | 192 | mov r9,r8 |
187 | #ifdef CONFIG_TRACE_IRQFLAGS | 193 | #ifdef CONFIG_TRACE_IRQFLAGS |
188 | mov.l 5f, r9 | 194 | mov.l 2f, r9 |
189 | jsr @r9 | 195 | jsr @r9 |
190 | nop | 196 | nop |
191 | #endif | 197 | #endif |
@@ -194,12 +200,8 @@ trap_entry: | |||
194 | nop | 200 | nop |
195 | 201 | ||
196 | .align 2 | 202 | .align 2 |
197 | 1: .long syscall_exit | ||
198 | 2: .long break_point_trap_software | ||
199 | 3: .long NR_syscalls | ||
200 | 4: .long sys_call_table | ||
201 | #ifdef CONFIG_TRACE_IRQFLAGS | 203 | #ifdef CONFIG_TRACE_IRQFLAGS |
202 | 5: .long trace_hardirqs_on | 204 | 2: .long trace_hardirqs_on |
203 | #endif | 205 | #endif |
204 | 206 | ||
205 | #if defined(CONFIG_SH_STANDARD_BIOS) | 207 | #if defined(CONFIG_SH_STANDARD_BIOS) |
@@ -264,7 +266,7 @@ ENTRY(address_error_handler) | |||
264 | restore_all: | 266 | restore_all: |
265 | cli | 267 | cli |
266 | #ifdef CONFIG_TRACE_IRQFLAGS | 268 | #ifdef CONFIG_TRACE_IRQFLAGS |
267 | mov.l 3f, r0 | 269 | mov.l 1f, r0 |
268 | jsr @r0 | 270 | jsr @r0 |
269 | nop | 271 | nop |
270 | #endif | 272 | #endif |
@@ -309,20 +311,14 @@ restore_all: | |||
309 | mov.l @r15,r15 | 311 | mov.l @r15,r15 |
310 | rte | 312 | rte |
311 | nop | 313 | nop |
312 | 2: | ||
313 | mov.l 1f,r8 | ||
314 | mov.l 2f,r9 | ||
315 | jmp @r9 | ||
316 | lds r8,pr | ||
317 | 314 | ||
318 | .align 2 | 315 | #ifdef CONFIG_TRACE_IRQFLAGS |
316 | 1: .long trace_hardirqs_off | ||
317 | #endif | ||
319 | $current_thread_info: | 318 | $current_thread_info: |
320 | .long __current_thread_info | 319 | .long __current_thread_info |
321 | $cpu_mode: | 320 | $cpu_mode: |
322 | .long __cpu_mode | 321 | .long __cpu_mode |
323 | #ifdef CONFIG_TRACE_IRQFLAGS | ||
324 | 3: .long trace_hardirqs_off | ||
325 | #endif | ||
326 | 322 | ||
327 | ! common exception handler | 323 | ! common exception handler |
328 | #include "../../entry-common.S" | 324 | #include "../../entry-common.S" |
diff --git a/arch/sh/kernel/cpu/sh2/setup-sh7619.c b/arch/sh/kernel/cpu/sh2/setup-sh7619.c index 82c2d905152f..79283e6c1d8f 100644 --- a/arch/sh/kernel/cpu/sh2/setup-sh7619.c +++ b/arch/sh/kernel/cpu/sh2/setup-sh7619.c | |||
@@ -51,3 +51,44 @@ static int __init sh7619_devices_setup(void) | |||
51 | ARRAY_SIZE(sh7619_devices)); | 51 | ARRAY_SIZE(sh7619_devices)); |
52 | } | 52 | } |
53 | __initcall(sh7619_devices_setup); | 53 | __initcall(sh7619_devices_setup); |
54 | |||
55 | #define INTC_IPRC 0xf8080000UL | ||
56 | #define INTC_IPRD 0xf8080002UL | ||
57 | |||
58 | #define CMI0_IRQ 86 | ||
59 | |||
60 | #define SCIF0_ERI_IRQ 88 | ||
61 | #define SCIF0_RXI_IRQ 89 | ||
62 | #define SCIF0_BRI_IRQ 90 | ||
63 | #define SCIF0_TXI_IRQ 91 | ||
64 | |||
65 | #define SCIF1_ERI_IRQ 92 | ||
66 | #define SCIF1_RXI_IRQ 93 | ||
67 | #define SCIF1_BRI_IRQ 94 | ||
68 | #define SCIF1_TXI_IRQ 95 | ||
69 | |||
70 | #define SCIF2_BRI_IRQ 96 | ||
71 | #define SCIF2_ERI_IRQ 97 | ||
72 | #define SCIF2_RXI_IRQ 98 | ||
73 | #define SCIF2_TXI_IRQ 99 | ||
74 | |||
75 | static struct ipr_data sh7619_ipr_map[] = { | ||
76 | { CMI0_IRQ, INTC_IPRC, 1, 2 }, | ||
77 | { SCIF0_ERI_IRQ, INTC_IPRD, 3, 3 }, | ||
78 | { SCIF0_RXI_IRQ, INTC_IPRD, 3, 3 }, | ||
79 | { SCIF0_BRI_IRQ, INTC_IPRD, 3, 3 }, | ||
80 | { SCIF0_TXI_IRQ, INTC_IPRD, 3, 3 }, | ||
81 | { SCIF1_ERI_IRQ, INTC_IPRD, 2, 3 }, | ||
82 | { SCIF1_RXI_IRQ, INTC_IPRD, 2, 3 }, | ||
83 | { SCIF1_BRI_IRQ, INTC_IPRD, 2, 3 }, | ||
84 | { SCIF1_TXI_IRQ, INTC_IPRD, 2, 3 }, | ||
85 | { SCIF2_ERI_IRQ, INTC_IPRD, 1, 3 }, | ||
86 | { SCIF2_RXI_IRQ, INTC_IPRD, 1, 3 }, | ||
87 | { SCIF2_BRI_IRQ, INTC_IPRD, 1, 3 }, | ||
88 | { SCIF2_TXI_IRQ, INTC_IPRD, 1, 3 }, | ||
89 | }; | ||
90 | |||
91 | void __init init_IRQ_ipr(void) | ||
92 | { | ||
93 | make_ipr_irq(sh7619_ipr_map, ARRAY_SIZE(sh7619_ipr_map)); | ||
94 | } | ||
diff --git a/arch/sh/kernel/cpu/sh2a/setup-sh7206.c b/arch/sh/kernel/cpu/sh2a/setup-sh7206.c index cdfeef49e62e..4b60fcc7d667 100644 --- a/arch/sh/kernel/cpu/sh2a/setup-sh7206.c +++ b/arch/sh/kernel/cpu/sh2a/setup-sh7206.c | |||
@@ -17,22 +17,22 @@ static struct plat_sci_port sci_platform_data[] = { | |||
17 | .mapbase = 0xfffe8000, | 17 | .mapbase = 0xfffe8000, |
18 | .flags = UPF_BOOT_AUTOCONF, | 18 | .flags = UPF_BOOT_AUTOCONF, |
19 | .type = PORT_SCIF, | 19 | .type = PORT_SCIF, |
20 | .irqs = { 240, 241, 242, 243}, | 20 | .irqs = { 241, 242, 243, 240}, |
21 | }, { | 21 | }, { |
22 | .mapbase = 0xfffe8800, | 22 | .mapbase = 0xfffe8800, |
23 | .flags = UPF_BOOT_AUTOCONF, | 23 | .flags = UPF_BOOT_AUTOCONF, |
24 | .type = PORT_SCIF, | 24 | .type = PORT_SCIF, |
25 | .irqs = { 244, 245, 246, 247}, | 25 | .irqs = { 247, 244, 245, 246}, |
26 | }, { | 26 | }, { |
27 | .mapbase = 0xfffe9000, | 27 | .mapbase = 0xfffe9000, |
28 | .flags = UPF_BOOT_AUTOCONF, | 28 | .flags = UPF_BOOT_AUTOCONF, |
29 | .type = PORT_SCIF, | 29 | .type = PORT_SCIF, |
30 | .irqs = { 248, 249, 250, 251}, | 30 | .irqs = { 249, 250, 251, 248}, |
31 | }, { | 31 | }, { |
32 | .mapbase = 0xfffe9800, | 32 | .mapbase = 0xfffe9800, |
33 | .flags = UPF_BOOT_AUTOCONF, | 33 | .flags = UPF_BOOT_AUTOCONF, |
34 | .type = PORT_SCIF, | 34 | .type = PORT_SCIF, |
35 | .irqs = { 252, 253, 254, 255}, | 35 | .irqs = { 253, 254, 255, 252}, |
36 | }, { | 36 | }, { |
37 | .flags = 0, | 37 | .flags = 0, |
38 | } | 38 | } |
@@ -56,3 +56,57 @@ static int __init sh7206_devices_setup(void) | |||
56 | ARRAY_SIZE(sh7206_devices)); | 56 | ARRAY_SIZE(sh7206_devices)); |
57 | } | 57 | } |
58 | __initcall(sh7206_devices_setup); | 58 | __initcall(sh7206_devices_setup); |
59 | |||
60 | #define INTC_IPR08 0xfffe0c04UL | ||
61 | #define INTC_IPR09 0xfffe0c06UL | ||
62 | #define INTC_IPR14 0xfffe0c10UL | ||
63 | |||
64 | #define CMI0_IRQ 140 | ||
65 | |||
66 | #define MTU1_TGI1A 164 | ||
67 | |||
68 | #define SCIF0_BRI_IRQ 240 | ||
69 | #define SCIF0_ERI_IRQ 241 | ||
70 | #define SCIF0_RXI_IRQ 242 | ||
71 | #define SCIF0_TXI_IRQ 243 | ||
72 | |||
73 | #define SCIF1_BRI_IRQ 244 | ||
74 | #define SCIF1_ERI_IRQ 245 | ||
75 | #define SCIF1_RXI_IRQ 246 | ||
76 | #define SCIF1_TXI_IRQ 247 | ||
77 | |||
78 | #define SCIF2_BRI_IRQ 248 | ||
79 | #define SCIF2_ERI_IRQ 249 | ||
80 | #define SCIF2_RXI_IRQ 250 | ||
81 | #define SCIF2_TXI_IRQ 251 | ||
82 | |||
83 | #define SCIF3_BRI_IRQ 252 | ||
84 | #define SCIF3_ERI_IRQ 253 | ||
85 | #define SCIF3_RXI_IRQ 254 | ||
86 | #define SCIF3_TXI_IRQ 255 | ||
87 | |||
88 | static struct ipr_data sh7206_ipr_map[] = { | ||
89 | { CMI0_IRQ, INTC_IPR08, 3, 2 }, | ||
90 | { MTU2_TGI1A, INTC_IPR09, 1, 2 }, | ||
91 | { SCIF0_ERI_IRQ, INTC_IPR14, 3, 3 }, | ||
92 | { SCIF0_RXI_IRQ, INTC_IPR14, 3, 3 }, | ||
93 | { SCIF0_BRI_IRQ, INTC_IPR14, 3, 3 }, | ||
94 | { SCIF0_TXI_IRQ, INTC_IPR14, 3, 3 }, | ||
95 | { SCIF1_ERI_IRQ, INTC_IPR14, 2, 3 }, | ||
96 | { SCIF1_RXI_IRQ, INTC_IPR14, 2, 3 }, | ||
97 | { SCIF1_BRI_IRQ, INTC_IPR14, 2, 3 }, | ||
98 | { SCIF1_TXI_IRQ, INTC_IPR14, 2, 3 }, | ||
99 | { SCIF2_ERI_IRQ, INTC_IPR14, 1, 3 }, | ||
100 | { SCIF2_RXI_IRQ, INTC_IPR14, 1, 3 }, | ||
101 | { SCIF2_BRI_IRQ, INTC_IPR14, 1, 3 }, | ||
102 | { SCIF2_TXI_IRQ, INTC_IPR14, 1, 3 }, | ||
103 | { SCIF3_ERI_IRQ, INTC_IPR14, 0, 3 }, | ||
104 | { SCIF3_RXI_IRQ, INTC_IPR14, 0, 3 }, | ||
105 | { SCIF3_BRI_IRQ, INTC_IPR14, 0, 3 }, | ||
106 | { SCIF3_TXI_IRQ, INTC_IPR14, 0, 3 }, | ||
107 | }; | ||
108 | |||
109 | void __init init_IRQ_ipr(void) | ||
110 | { | ||
111 | make_ipr_irq(sh7206_ipr_map, ARRAY_SIZE(sh7206_ipr_map)); | ||
112 | } | ||
diff --git a/arch/sh/kernel/cpu/sh4/Makefile b/arch/sh/kernel/cpu/sh4/Makefile index 6e415baf04b4..19ca68c71884 100644 --- a/arch/sh/kernel/cpu/sh4/Makefile +++ b/arch/sh/kernel/cpu/sh4/Makefile | |||
@@ -12,17 +12,12 @@ obj-$(CONFIG_SH_STORE_QUEUES) += sq.o | |||
12 | obj-$(CONFIG_CPU_SUBTYPE_SH7750) += setup-sh7750.o | 12 | obj-$(CONFIG_CPU_SUBTYPE_SH7750) += setup-sh7750.o |
13 | obj-$(CONFIG_CPU_SUBTYPE_SH7751) += setup-sh7750.o | 13 | obj-$(CONFIG_CPU_SUBTYPE_SH7751) += setup-sh7750.o |
14 | obj-$(CONFIG_CPU_SUBTYPE_SH7760) += setup-sh7760.o | 14 | obj-$(CONFIG_CPU_SUBTYPE_SH7760) += setup-sh7760.o |
15 | obj-$(CONFIG_CPU_SUBTYPE_SH7770) += setup-sh7770.o | ||
16 | obj-$(CONFIG_CPU_SUBTYPE_SH7780) += setup-sh7780.o | ||
17 | obj-$(CONFIG_CPU_SUBTYPE_SH73180) += setup-sh73180.o | ||
18 | obj-$(CONFIG_CPU_SUBTYPE_SH7343) += setup-sh7343.o | ||
19 | obj-$(CONFIG_CPU_SUBTYPE_SH4_202) += setup-sh4-202.o | 15 | obj-$(CONFIG_CPU_SUBTYPE_SH4_202) += setup-sh4-202.o |
20 | 16 | ||
21 | # Primary on-chip clocks (common) | 17 | # Primary on-chip clocks (common) |
18 | ifndef CONFIG_CPU_SH4A | ||
22 | clock-$(CONFIG_CPU_SH4) := clock-sh4.o | 19 | clock-$(CONFIG_CPU_SH4) := clock-sh4.o |
23 | clock-$(CONFIG_CPU_SUBTYPE_SH73180) := clock-sh73180.o | 20 | endif |
24 | clock-$(CONFIG_CPU_SUBTYPE_SH7770) := clock-sh7770.o | ||
25 | clock-$(CONFIG_CPU_SUBTYPE_SH7780) := clock-sh7780.o | ||
26 | 21 | ||
27 | # Additional clocks by subtype | 22 | # Additional clocks by subtype |
28 | clock-$(CONFIG_CPU_SUBTYPE_SH4_202) += clock-sh4-202.o | 23 | clock-$(CONFIG_CPU_SUBTYPE_SH4_202) += clock-sh4-202.o |
diff --git a/arch/sh/kernel/cpu/sh4/probe.c b/arch/sh/kernel/cpu/sh4/probe.c index afe0f1b1c030..9031a22a2ce7 100644 --- a/arch/sh/kernel/cpu/sh4/probe.c +++ b/arch/sh/kernel/cpu/sh4/probe.c | |||
@@ -119,11 +119,20 @@ int __init detect_cpu_and_cache_system(void) | |||
119 | break; | 119 | break; |
120 | case 0x3000: | 120 | case 0x3000: |
121 | case 0x3003: | 121 | case 0x3003: |
122 | case 0x3009: | ||
122 | cpu_data->type = CPU_SH7343; | 123 | cpu_data->type = CPU_SH7343; |
123 | cpu_data->icache.ways = 4; | 124 | cpu_data->icache.ways = 4; |
124 | cpu_data->dcache.ways = 4; | 125 | cpu_data->dcache.ways = 4; |
125 | cpu_data->flags |= CPU_HAS_LLSC; | 126 | cpu_data->flags |= CPU_HAS_LLSC; |
126 | break; | 127 | break; |
128 | case 0x3008: | ||
129 | if (prr == 0xa0) { | ||
130 | cpu_data->type = CPU_SH7722; | ||
131 | cpu_data->icache.ways = 4; | ||
132 | cpu_data->dcache.ways = 4; | ||
133 | cpu_data->flags |= CPU_HAS_LLSC; | ||
134 | } | ||
135 | break; | ||
127 | case 0x8000: | 136 | case 0x8000: |
128 | cpu_data->type = CPU_ST40RA; | 137 | cpu_data->type = CPU_ST40RA; |
129 | cpu_data->flags |= CPU_HAS_FPU; | 138 | cpu_data->flags |= CPU_HAS_FPU; |
diff --git a/arch/sh/kernel/cpu/sh4/setup-sh7750.c b/arch/sh/kernel/cpu/sh4/setup-sh7750.c index bbcb06f18b04..cbac27634c0b 100644 --- a/arch/sh/kernel/cpu/sh4/setup-sh7750.c +++ b/arch/sh/kernel/cpu/sh4/setup-sh7750.c | |||
@@ -14,6 +14,36 @@ | |||
14 | #include <linux/io.h> | 14 | #include <linux/io.h> |
15 | #include <asm/sci.h> | 15 | #include <asm/sci.h> |
16 | 16 | ||
17 | static struct resource rtc_resources[] = { | ||
18 | [0] = { | ||
19 | .start = 0xffc80000, | ||
20 | .end = 0xffc80000 + 0x58 - 1, | ||
21 | .flags = IORESOURCE_IO, | ||
22 | }, | ||
23 | [1] = { | ||
24 | /* Period IRQ */ | ||
25 | .start = 21, | ||
26 | .flags = IORESOURCE_IRQ, | ||
27 | }, | ||
28 | [2] = { | ||
29 | /* Carry IRQ */ | ||
30 | .start = 22, | ||
31 | .flags = IORESOURCE_IRQ, | ||
32 | }, | ||
33 | [3] = { | ||
34 | /* Alarm IRQ */ | ||
35 | .start = 20, | ||
36 | .flags = IORESOURCE_IRQ, | ||
37 | }, | ||
38 | }; | ||
39 | |||
40 | static struct platform_device rtc_device = { | ||
41 | .name = "sh-rtc", | ||
42 | .id = -1, | ||
43 | .num_resources = ARRAY_SIZE(rtc_resources), | ||
44 | .resource = rtc_resources, | ||
45 | }; | ||
46 | |||
17 | static struct plat_sci_port sci_platform_data[] = { | 47 | static struct plat_sci_port sci_platform_data[] = { |
18 | { | 48 | { |
19 | .mapbase = 0xffe00000, | 49 | .mapbase = 0xffe00000, |
@@ -39,6 +69,7 @@ static struct platform_device sci_device = { | |||
39 | }; | 69 | }; |
40 | 70 | ||
41 | static struct platform_device *sh7750_devices[] __initdata = { | 71 | static struct platform_device *sh7750_devices[] __initdata = { |
72 | &rtc_device, | ||
42 | &sci_device, | 73 | &sci_device, |
43 | }; | 74 | }; |
44 | 75 | ||
diff --git a/arch/sh/kernel/cpu/sh4/sq.c b/arch/sh/kernel/cpu/sh4/sq.c index 0c9ea38d2caa..d7fff752e569 100644 --- a/arch/sh/kernel/cpu/sh4/sq.c +++ b/arch/sh/kernel/cpu/sh4/sq.c | |||
@@ -111,8 +111,9 @@ static int __sq_remap(struct sq_mapping *map, unsigned long flags) | |||
111 | 111 | ||
112 | vma->phys_addr = map->addr; | 112 | vma->phys_addr = map->addr; |
113 | 113 | ||
114 | if (remap_area_pages((unsigned long)vma->addr, vma->phys_addr, | 114 | if (ioremap_page_range((unsigned long)vma->addr, |
115 | map->size, flags)) { | 115 | (unsigned long)vma->addr + map->size, |
116 | vma->phys_addr, __pgprot(flags))) { | ||
116 | vunmap(vma->addr); | 117 | vunmap(vma->addr); |
117 | return -EAGAIN; | 118 | return -EAGAIN; |
118 | } | 119 | } |
@@ -176,7 +177,7 @@ unsigned long sq_remap(unsigned long phys, unsigned int size, | |||
176 | 177 | ||
177 | map->sq_addr = P4SEG_STORE_QUE + (page << PAGE_SHIFT); | 178 | map->sq_addr = P4SEG_STORE_QUE + (page << PAGE_SHIFT); |
178 | 179 | ||
179 | ret = __sq_remap(map, flags); | 180 | ret = __sq_remap(map, pgprot_val(PAGE_KERNEL_NOCACHE) | flags); |
180 | if (unlikely(ret != 0)) | 181 | if (unlikely(ret != 0)) |
181 | goto out; | 182 | goto out; |
182 | 183 | ||
diff --git a/arch/sh/kernel/cpu/sh4a/Makefile b/arch/sh/kernel/cpu/sh4a/Makefile new file mode 100644 index 000000000000..a8f493f2f21f --- /dev/null +++ b/arch/sh/kernel/cpu/sh4a/Makefile | |||
@@ -0,0 +1,19 @@ | |||
1 | # | ||
2 | # Makefile for the Linux/SuperH SH-4 backends. | ||
3 | # | ||
4 | |||
5 | # CPU subtype setup | ||
6 | obj-$(CONFIG_CPU_SUBTYPE_SH7770) += setup-sh7770.o | ||
7 | obj-$(CONFIG_CPU_SUBTYPE_SH7780) += setup-sh7780.o | ||
8 | obj-$(CONFIG_CPU_SUBTYPE_SH73180) += setup-sh73180.o | ||
9 | obj-$(CONFIG_CPU_SUBTYPE_SH7343) += setup-sh7343.o | ||
10 | obj-$(CONFIG_CPU_SUBTYPE_SH7722) += setup-sh7722.o | ||
11 | |||
12 | # Primary on-chip clocks (common) | ||
13 | clock-$(CONFIG_CPU_SUBTYPE_SH73180) := clock-sh73180.o | ||
14 | clock-$(CONFIG_CPU_SUBTYPE_SH7770) := clock-sh7770.o | ||
15 | clock-$(CONFIG_CPU_SUBTYPE_SH7780) := clock-sh7780.o | ||
16 | clock-$(CONFIG_CPU_SUBTYPE_SH7343) := clock-sh7343.o | ||
17 | clock-$(CONFIG_CPU_SUBTYPE_SH7722) := clock-sh7343.o | ||
18 | |||
19 | obj-y += $(clock-y) | ||
diff --git a/arch/sh/kernel/cpu/sh4/clock-sh73180.c b/arch/sh/kernel/cpu/sh4a/clock-sh73180.c index 2fa5cb2ae68d..2fa5cb2ae68d 100644 --- a/arch/sh/kernel/cpu/sh4/clock-sh73180.c +++ b/arch/sh/kernel/cpu/sh4a/clock-sh73180.c | |||
diff --git a/arch/sh/kernel/cpu/sh4a/clock-sh7343.c b/arch/sh/kernel/cpu/sh4a/clock-sh7343.c new file mode 100644 index 000000000000..1707a213f0cf --- /dev/null +++ b/arch/sh/kernel/cpu/sh4a/clock-sh7343.c | |||
@@ -0,0 +1,99 @@ | |||
1 | /* | ||
2 | * arch/sh/kernel/cpu/sh4/clock-sh7343.c | ||
3 | * | ||
4 | * SH7343/SH7722 support for the clock framework | ||
5 | * | ||
6 | * Copyright (C) 2006 Paul Mundt | ||
7 | * | ||
8 | * This file is subject to the terms and conditions of the GNU General Public | ||
9 | * License. See the file "COPYING" in the main directory of this archive | ||
10 | * for more details. | ||
11 | */ | ||
12 | #include <linux/init.h> | ||
13 | #include <linux/kernel.h> | ||
14 | #include <linux/io.h> | ||
15 | #include <asm/clock.h> | ||
16 | #include <asm/freq.h> | ||
17 | |||
18 | /* | ||
19 | * SH7343/SH7722 uses a common set of multipliers and divisors, so this | ||
20 | * is quite simple.. | ||
21 | */ | ||
22 | static int multipliers[] = { 1, 2, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1 }; | ||
23 | static int divisors[] = { 1, 3, 2, 5, 3, 4, 5, 6, 8, 10, 12, 16, 20 }; | ||
24 | |||
25 | #define pll_calc() (((ctrl_inl(FRQCR) >> 24) & 0x1f) + 1) | ||
26 | |||
27 | static void master_clk_init(struct clk *clk) | ||
28 | { | ||
29 | clk->parent = clk_get(NULL, "cpu_clk"); | ||
30 | } | ||
31 | |||
32 | static void master_clk_recalc(struct clk *clk) | ||
33 | { | ||
34 | int idx = (ctrl_inl(FRQCR) & 0x000f); | ||
35 | clk->rate *= clk->parent->rate * multipliers[idx] / divisors[idx]; | ||
36 | } | ||
37 | |||
38 | static struct clk_ops sh7343_master_clk_ops = { | ||
39 | .init = master_clk_init, | ||
40 | .recalc = master_clk_recalc, | ||
41 | }; | ||
42 | |||
43 | static void module_clk_init(struct clk *clk) | ||
44 | { | ||
45 | clk->parent = NULL; | ||
46 | clk->rate = CONFIG_SH_PCLK_FREQ; | ||
47 | } | ||
48 | |||
49 | static struct clk_ops sh7343_module_clk_ops = { | ||
50 | .init = module_clk_init, | ||
51 | }; | ||
52 | |||
53 | static void bus_clk_init(struct clk *clk) | ||
54 | { | ||
55 | clk->parent = clk_get(NULL, "cpu_clk"); | ||
56 | } | ||
57 | |||
58 | static void bus_clk_recalc(struct clk *clk) | ||
59 | { | ||
60 | int idx = (ctrl_inl(FRQCR) >> 8) & 0x000f; | ||
61 | clk->rate = clk->parent->rate * multipliers[idx] / divisors[idx]; | ||
62 | } | ||
63 | |||
64 | static struct clk_ops sh7343_bus_clk_ops = { | ||
65 | .init = bus_clk_init, | ||
66 | .recalc = bus_clk_recalc, | ||
67 | }; | ||
68 | |||
69 | static void cpu_clk_init(struct clk *clk) | ||
70 | { | ||
71 | clk->parent = clk_get(NULL, "module_clk"); | ||
72 | clk->flags |= CLK_RATE_PROPAGATES; | ||
73 | clk_set_rate(clk, clk_get_rate(clk)); | ||
74 | } | ||
75 | |||
76 | static void cpu_clk_recalc(struct clk *clk) | ||
77 | { | ||
78 | int idx = (ctrl_inl(FRQCR) >> 20) & 0x000f; | ||
79 | clk->rate = clk->parent->rate * pll_calc() * | ||
80 | multipliers[idx] / divisors[idx]; | ||
81 | } | ||
82 | |||
83 | static struct clk_ops sh7343_cpu_clk_ops = { | ||
84 | .init = cpu_clk_init, | ||
85 | .recalc = cpu_clk_recalc, | ||
86 | }; | ||
87 | |||
88 | static struct clk_ops *sh7343_clk_ops[] = { | ||
89 | &sh7343_master_clk_ops, | ||
90 | &sh7343_module_clk_ops, | ||
91 | &sh7343_bus_clk_ops, | ||
92 | &sh7343_cpu_clk_ops, | ||
93 | }; | ||
94 | |||
95 | void __init arch_init_clk_ops(struct clk_ops **ops, int idx) | ||
96 | { | ||
97 | if (idx < ARRAY_SIZE(sh7343_clk_ops)) | ||
98 | *ops = sh7343_clk_ops[idx]; | ||
99 | } | ||
diff --git a/arch/sh/kernel/cpu/sh4/clock-sh7770.c b/arch/sh/kernel/cpu/sh4a/clock-sh7770.c index c8694bac6477..c8694bac6477 100644 --- a/arch/sh/kernel/cpu/sh4/clock-sh7770.c +++ b/arch/sh/kernel/cpu/sh4a/clock-sh7770.c | |||
diff --git a/arch/sh/kernel/cpu/sh4/clock-sh7780.c b/arch/sh/kernel/cpu/sh4a/clock-sh7780.c index 9e6a216750c8..9e6a216750c8 100644 --- a/arch/sh/kernel/cpu/sh4/clock-sh7780.c +++ b/arch/sh/kernel/cpu/sh4a/clock-sh7780.c | |||
diff --git a/arch/sh/kernel/cpu/sh4/setup-sh73180.c b/arch/sh/kernel/cpu/sh4a/setup-sh73180.c index cc9ea1e2e5df..cc9ea1e2e5df 100644 --- a/arch/sh/kernel/cpu/sh4/setup-sh73180.c +++ b/arch/sh/kernel/cpu/sh4a/setup-sh73180.c | |||
diff --git a/arch/sh/kernel/cpu/sh4/setup-sh7343.c b/arch/sh/kernel/cpu/sh4a/setup-sh7343.c index 91d61cf91ba1..91d61cf91ba1 100644 --- a/arch/sh/kernel/cpu/sh4/setup-sh7343.c +++ b/arch/sh/kernel/cpu/sh4a/setup-sh7343.c | |||
diff --git a/arch/sh/kernel/cpu/sh4a/setup-sh7722.c b/arch/sh/kernel/cpu/sh4a/setup-sh7722.c new file mode 100644 index 000000000000..1143fbf65faf --- /dev/null +++ b/arch/sh/kernel/cpu/sh4a/setup-sh7722.c | |||
@@ -0,0 +1,80 @@ | |||
1 | /* | ||
2 | * SH7722 Setup | ||
3 | * | ||
4 | * Copyright (C) 2006 Paul Mundt | ||
5 | * | ||
6 | * This file is subject to the terms and conditions of the GNU General Public | ||
7 | * License. See the file "COPYING" in the main directory of this archive | ||
8 | * for more details. | ||
9 | */ | ||
10 | #include <linux/platform_device.h> | ||
11 | #include <linux/init.h> | ||
12 | #include <linux/serial.h> | ||
13 | #include <asm/sci.h> | ||
14 | |||
15 | static struct plat_sci_port sci_platform_data[] = { | ||
16 | { | ||
17 | .mapbase = 0xffe00000, | ||
18 | .flags = UPF_BOOT_AUTOCONF, | ||
19 | .type = PORT_SCIF, | ||
20 | .irqs = { 80, 81, 83, 82 }, | ||
21 | }, { | ||
22 | .flags = 0, | ||
23 | } | ||
24 | }; | ||
25 | |||
26 | static struct platform_device sci_device = { | ||
27 | .name = "sh-sci", | ||
28 | .id = -1, | ||
29 | .dev = { | ||
30 | .platform_data = sci_platform_data, | ||
31 | }, | ||
32 | }; | ||
33 | |||
34 | static struct platform_device *sh7722_devices[] __initdata = { | ||
35 | &sci_device, | ||
36 | }; | ||
37 | |||
38 | static int __init sh7722_devices_setup(void) | ||
39 | { | ||
40 | return platform_add_devices(sh7722_devices, | ||
41 | ARRAY_SIZE(sh7722_devices)); | ||
42 | } | ||
43 | __initcall(sh7722_devices_setup); | ||
44 | |||
45 | static struct ipr_data sh7722_ipr_map[] = { | ||
46 | /* IRQ, IPR-idx, shift, prio */ | ||
47 | { 16, 0, 12, 2 }, /* TMU0 */ | ||
48 | { 17, 0, 8, 2 }, /* TMU1 */ | ||
49 | { 80, 6, 12, 3 }, /* SCIF ERI */ | ||
50 | { 81, 6, 12, 3 }, /* SCIF RXI */ | ||
51 | { 82, 6, 12, 3 }, /* SCIF BRI */ | ||
52 | { 83, 6, 12, 3 }, /* SCIF TXI */ | ||
53 | }; | ||
54 | |||
55 | static unsigned long ipr_offsets[] = { | ||
56 | 0xa4080000, /* 0: IPRA */ | ||
57 | 0xa4080004, /* 1: IPRB */ | ||
58 | 0xa4080008, /* 2: IPRC */ | ||
59 | 0xa408000c, /* 3: IPRD */ | ||
60 | 0xa4080010, /* 4: IPRE */ | ||
61 | 0xa4080014, /* 5: IPRF */ | ||
62 | 0xa4080018, /* 6: IPRG */ | ||
63 | 0xa408001c, /* 7: IPRH */ | ||
64 | 0xa4080020, /* 8: IPRI */ | ||
65 | 0xa4080024, /* 9: IPRJ */ | ||
66 | 0xa4080028, /* 10: IPRK */ | ||
67 | 0xa408002c, /* 11: IPRL */ | ||
68 | }; | ||
69 | |||
70 | unsigned int map_ipridx_to_addr(int idx) | ||
71 | { | ||
72 | if (unlikely(idx >= ARRAY_SIZE(ipr_offsets))) | ||
73 | return 0; | ||
74 | return ipr_offsets[idx]; | ||
75 | } | ||
76 | |||
77 | void __init init_IRQ_ipr(void) | ||
78 | { | ||
79 | make_ipr_irq(sh7722_ipr_map, ARRAY_SIZE(sh7722_ipr_map)); | ||
80 | } | ||
diff --git a/arch/sh/kernel/cpu/sh4/setup-sh7770.c b/arch/sh/kernel/cpu/sh4a/setup-sh7770.c index 6a04cc5f5aca..6a04cc5f5aca 100644 --- a/arch/sh/kernel/cpu/sh4/setup-sh7770.c +++ b/arch/sh/kernel/cpu/sh4a/setup-sh7770.c | |||
diff --git a/arch/sh/kernel/cpu/sh4/setup-sh7780.c b/arch/sh/kernel/cpu/sh4a/setup-sh7780.c index 9aeaa2ddaa28..9aeaa2ddaa28 100644 --- a/arch/sh/kernel/cpu/sh4/setup-sh7780.c +++ b/arch/sh/kernel/cpu/sh4a/setup-sh7780.c | |||
diff --git a/arch/sh/kernel/early_printk.c b/arch/sh/kernel/early_printk.c index 60340823798a..560b91cdd15c 100644 --- a/arch/sh/kernel/early_printk.c +++ b/arch/sh/kernel/early_printk.c | |||
@@ -144,16 +144,16 @@ static struct console *early_console = | |||
144 | ; | 144 | ; |
145 | 145 | ||
146 | static int __initdata keep_early; | 146 | static int __initdata keep_early; |
147 | static int early_console_initialized; | ||
147 | 148 | ||
148 | int __init setup_early_printk(char *opt) | 149 | int __init setup_early_printk(char *buf) |
149 | { | 150 | { |
150 | char *space; | 151 | if (!buf) |
151 | char buf[256]; | 152 | return 0; |
152 | 153 | ||
153 | strlcpy(buf, opt, sizeof(buf)); | 154 | if (early_console_initialized) |
154 | space = strchr(buf, ' '); | 155 | return 0; |
155 | if (space) | 156 | early_console_initialized = 1; |
156 | *space = 0; | ||
157 | 157 | ||
158 | if (strstr(buf, "keep")) | 158 | if (strstr(buf, "keep")) |
159 | keep_early = 1; | 159 | keep_early = 1; |
@@ -175,12 +175,14 @@ int __init setup_early_printk(char *opt) | |||
175 | if (likely(early_console)) | 175 | if (likely(early_console)) |
176 | register_console(early_console); | 176 | register_console(early_console); |
177 | 177 | ||
178 | return 1; | 178 | return 0; |
179 | } | 179 | } |
180 | __setup("earlyprintk=", setup_early_printk); | 180 | early_param("earlyprintk", setup_early_printk); |
181 | 181 | ||
182 | void __init disable_early_printk(void) | 182 | void __init disable_early_printk(void) |
183 | { | 183 | { |
184 | if (!early_console_initialized || !early_console) | ||
185 | return; | ||
184 | if (!keep_early) { | 186 | if (!keep_early) { |
185 | printk("disabling early console\n"); | 187 | printk("disabling early console\n"); |
186 | unregister_console(early_console); | 188 | unregister_console(early_console); |
diff --git a/arch/sh/kernel/entry-common.S b/arch/sh/kernel/entry-common.S index 29136a35d7c7..fc279aeb73ab 100644 --- a/arch/sh/kernel/entry-common.S +++ b/arch/sh/kernel/entry-common.S | |||
@@ -79,18 +79,29 @@ debug_kernel_sw: | |||
79 | .align 2 | 79 | .align 2 |
80 | 3: .long kgdb_handle_exception | 80 | 3: .long kgdb_handle_exception |
81 | #endif /* CONFIG_SH_KGDB */ | 81 | #endif /* CONFIG_SH_KGDB */ |
82 | 82 | #ifdef CONFIG_SH_STANDARD_BIOS | |
83 | bra debug_kernel_fw | ||
84 | nop | ||
85 | #endif | ||
83 | #endif /* CONFIG_SH_STANDARD_BIOS || CONFIG_SH_KGDB */ | 86 | #endif /* CONFIG_SH_STANDARD_BIOS || CONFIG_SH_KGDB */ |
84 | 87 | ||
85 | |||
86 | .align 2 | 88 | .align 2 |
87 | debug_trap: | 89 | debug_trap: |
88 | #if defined(CONFIG_SH_STANDARD_BIOS) || defined(CONFIG_SH_KGDB) | 90 | #if defined(CONFIG_SH_STANDARD_BIOS) || defined(CONFIG_SH_KGDB) |
91 | mov r8, r0 | ||
92 | shlr2 r0 | ||
93 | cmp/eq #0x3f, r0 ! sh_bios() trap | ||
94 | bf 1f | ||
95 | #ifdef CONFIG_SH_KGDB | ||
96 | cmp/eq #0xff, r0 ! XXX: KGDB trap, fix for SH-2. | ||
97 | bf 1f | ||
98 | #endif | ||
89 | mov #OFF_SR, r0 | 99 | mov #OFF_SR, r0 |
90 | mov.l @(r0,r15), r0 ! get status register | 100 | mov.l @(r0,r15), r0 ! get status register |
91 | shll r0 | 101 | shll r0 |
92 | shll r0 ! kernel space? | 102 | shll r0 ! kernel space? |
93 | bt/s debug_kernel | 103 | bt/s debug_kernel |
104 | 1: | ||
94 | #endif | 105 | #endif |
95 | mov.l @r15, r0 ! Restore R0 value | 106 | mov.l @r15, r0 ! Restore R0 value |
96 | mov.l 1f, r8 | 107 | mov.l 1f, r8 |
diff --git a/arch/sh/kernel/head.S b/arch/sh/kernel/head.S index 6aca4bc6ec5d..71a3ad7d283e 100644 --- a/arch/sh/kernel/head.S +++ b/arch/sh/kernel/head.S | |||
@@ -33,7 +33,8 @@ ENTRY(empty_zero_page) | |||
33 | .long 0x00360000 /* INITRD_START */ | 33 | .long 0x00360000 /* INITRD_START */ |
34 | .long 0x000a0000 /* INITRD_SIZE */ | 34 | .long 0x000a0000 /* INITRD_SIZE */ |
35 | .long 0 | 35 | .long 0 |
36 | .balign PAGE_SIZE,0,PAGE_SIZE | 36 | 1: |
37 | .skip PAGE_SIZE - empty_zero_page - 1b | ||
37 | 38 | ||
38 | .text | 39 | .text |
39 | /* | 40 | /* |
diff --git a/arch/sh/kernel/process.c b/arch/sh/kernel/process.c index f3e2631be144..486c06e18033 100644 --- a/arch/sh/kernel/process.c +++ b/arch/sh/kernel/process.c | |||
@@ -470,9 +470,10 @@ unsigned long get_wchan(struct task_struct *p) | |||
470 | */ | 470 | */ |
471 | pc = thread_saved_pc(p); | 471 | pc = thread_saved_pc(p); |
472 | if (in_sched_functions(pc)) { | 472 | if (in_sched_functions(pc)) { |
473 | schedule_frame = ((unsigned long *)(long)p->thread.sp)[1]; | 473 | schedule_frame = (unsigned long)p->thread.sp; |
474 | return (unsigned long)((unsigned long *)schedule_frame)[1]; | 474 | return ((unsigned long *)schedule_frame)[21]; |
475 | } | 475 | } |
476 | |||
476 | return pc; | 477 | return pc; |
477 | } | 478 | } |
478 | 479 | ||
@@ -498,6 +499,16 @@ asmlinkage void break_point_trap_software(unsigned long r4, unsigned long r5, | |||
498 | { | 499 | { |
499 | struct pt_regs *regs = RELOC_HIDE(&__regs, 0); | 500 | struct pt_regs *regs = RELOC_HIDE(&__regs, 0); |
500 | 501 | ||
502 | /* Rewind */ | ||
501 | regs->pc -= 2; | 503 | regs->pc -= 2; |
504 | |||
505 | #ifdef CONFIG_BUG | ||
506 | if (__kernel_text_address(instruction_pointer(regs))) { | ||
507 | u16 insn = *(u16 *)instruction_pointer(regs); | ||
508 | if (insn == TRAPA_BUG_OPCODE) | ||
509 | handle_BUG(regs); | ||
510 | } | ||
511 | #endif | ||
512 | |||
502 | force_sig(SIGTRAP, current); | 513 | force_sig(SIGTRAP, current); |
503 | } | 514 | } |
diff --git a/arch/sh/kernel/setup.c b/arch/sh/kernel/setup.c index f8dd6b7bfab0..225f9ea5cdd7 100644 --- a/arch/sh/kernel/setup.c +++ b/arch/sh/kernel/setup.c | |||
@@ -84,8 +84,7 @@ unsigned long memory_start, memory_end; | |||
84 | 84 | ||
85 | static inline void parse_cmdline (char ** cmdline_p, char mv_name[MV_NAME_SIZE], | 85 | static inline void parse_cmdline (char ** cmdline_p, char mv_name[MV_NAME_SIZE], |
86 | struct sh_machine_vector** mvp, | 86 | struct sh_machine_vector** mvp, |
87 | unsigned long *mv_io_base, | 87 | unsigned long *mv_io_base) |
88 | int *mv_mmio_enable) | ||
89 | { | 88 | { |
90 | char c = ' ', *to = command_line, *from = COMMAND_LINE; | 89 | char c = ' ', *to = command_line, *from = COMMAND_LINE; |
91 | int len = 0; | 90 | int len = 0; |
@@ -112,23 +111,6 @@ static inline void parse_cmdline (char ** cmdline_p, char mv_name[MV_NAME_SIZE], | |||
112 | } | 111 | } |
113 | } | 112 | } |
114 | 113 | ||
115 | #ifdef CONFIG_EARLY_PRINTK | ||
116 | if (c == ' ' && !memcmp(from, "earlyprintk=", 12)) { | ||
117 | char *ep_end; | ||
118 | |||
119 | if (to != command_line) | ||
120 | to--; | ||
121 | |||
122 | from += 12; | ||
123 | ep_end = strchr(from, ' '); | ||
124 | |||
125 | setup_early_printk(from); | ||
126 | printk("early console enabled\n"); | ||
127 | |||
128 | from = ep_end; | ||
129 | } | ||
130 | #endif | ||
131 | |||
132 | if (c == ' ' && !memcmp(from, "sh_mv=", 6)) { | 114 | if (c == ' ' && !memcmp(from, "sh_mv=", 6)) { |
133 | char* mv_end; | 115 | char* mv_end; |
134 | char* mv_comma; | 116 | char* mv_comma; |
@@ -145,7 +127,6 @@ static inline void parse_cmdline (char ** cmdline_p, char mv_name[MV_NAME_SIZE], | |||
145 | int ints[3]; | 127 | int ints[3]; |
146 | get_options(mv_comma+1, ARRAY_SIZE(ints), ints); | 128 | get_options(mv_comma+1, ARRAY_SIZE(ints), ints); |
147 | *mv_io_base = ints[1]; | 129 | *mv_io_base = ints[1]; |
148 | *mv_mmio_enable = ints[2]; | ||
149 | mv_len = mv_comma - from; | 130 | mv_len = mv_comma - from; |
150 | } else { | 131 | } else { |
151 | mv_len = mv_end - from; | 132 | mv_len = mv_end - from; |
@@ -158,6 +139,7 @@ static inline void parse_cmdline (char ** cmdline_p, char mv_name[MV_NAME_SIZE], | |||
158 | 139 | ||
159 | *mvp = get_mv_byname(mv_name); | 140 | *mvp = get_mv_byname(mv_name); |
160 | } | 141 | } |
142 | |||
161 | c = *(from++); | 143 | c = *(from++); |
162 | if (!c) | 144 | if (!c) |
163 | break; | 145 | break; |
@@ -177,9 +159,8 @@ static int __init sh_mv_setup(char **cmdline_p) | |||
177 | struct sh_machine_vector *mv = NULL; | 159 | struct sh_machine_vector *mv = NULL; |
178 | char mv_name[MV_NAME_SIZE] = ""; | 160 | char mv_name[MV_NAME_SIZE] = ""; |
179 | unsigned long mv_io_base = 0; | 161 | unsigned long mv_io_base = 0; |
180 | int mv_mmio_enable = 0; | ||
181 | 162 | ||
182 | parse_cmdline(cmdline_p, mv_name, &mv, &mv_io_base, &mv_mmio_enable); | 163 | parse_cmdline(cmdline_p, mv_name, &mv, &mv_io_base); |
183 | 164 | ||
184 | #ifdef CONFIG_SH_UNKNOWN | 165 | #ifdef CONFIG_SH_UNKNOWN |
185 | if (mv == NULL) { | 166 | if (mv == NULL) { |
@@ -258,6 +239,7 @@ void __init setup_arch(char **cmdline_p) | |||
258 | 239 | ||
259 | sh_mv_setup(cmdline_p); | 240 | sh_mv_setup(cmdline_p); |
260 | 241 | ||
242 | |||
261 | /* | 243 | /* |
262 | * Find the highest page frame number we have available | 244 | * Find the highest page frame number we have available |
263 | */ | 245 | */ |
@@ -305,6 +287,7 @@ void __init setup_arch(char **cmdline_p) | |||
305 | PFN_PHYS(pages)); | 287 | PFN_PHYS(pages)); |
306 | } | 288 | } |
307 | 289 | ||
290 | |||
308 | /* | 291 | /* |
309 | * Reserve the kernel text and | 292 | * Reserve the kernel text and |
310 | * Reserve the bootmem bitmap. We do this in two steps (first step | 293 | * Reserve the bootmem bitmap. We do this in two steps (first step |
@@ -325,14 +308,18 @@ void __init setup_arch(char **cmdline_p) | |||
325 | ROOT_DEV = MKDEV(RAMDISK_MAJOR, 0); | 308 | ROOT_DEV = MKDEV(RAMDISK_MAJOR, 0); |
326 | if (&__rd_start != &__rd_end) { | 309 | if (&__rd_start != &__rd_end) { |
327 | LOADER_TYPE = 1; | 310 | LOADER_TYPE = 1; |
328 | INITRD_START = PHYSADDR((unsigned long)&__rd_start) - __MEMORY_START; | 311 | INITRD_START = PHYSADDR((unsigned long)&__rd_start) - |
329 | INITRD_SIZE = (unsigned long)&__rd_end - (unsigned long)&__rd_start; | 312 | __MEMORY_START; |
313 | INITRD_SIZE = (unsigned long)&__rd_end - | ||
314 | (unsigned long)&__rd_start; | ||
330 | } | 315 | } |
331 | 316 | ||
332 | if (LOADER_TYPE && INITRD_START) { | 317 | if (LOADER_TYPE && INITRD_START) { |
333 | if (INITRD_START + INITRD_SIZE <= (max_low_pfn << PAGE_SHIFT)) { | 318 | if (INITRD_START + INITRD_SIZE <= (max_low_pfn << PAGE_SHIFT)) { |
334 | reserve_bootmem_node(NODE_DATA(0), INITRD_START+__MEMORY_START, INITRD_SIZE); | 319 | reserve_bootmem_node(NODE_DATA(0), INITRD_START + |
335 | initrd_start = INITRD_START + PAGE_OFFSET + __MEMORY_START; | 320 | __MEMORY_START, INITRD_SIZE); |
321 | initrd_start = INITRD_START + PAGE_OFFSET + | ||
322 | __MEMORY_START; | ||
336 | initrd_end = initrd_start + INITRD_SIZE; | 323 | initrd_end = initrd_start + INITRD_SIZE; |
337 | } else { | 324 | } else { |
338 | printk("initrd extends beyond end of memory " | 325 | printk("initrd extends beyond end of memory " |
@@ -404,7 +391,7 @@ static const char *cpu_name[] = { | |||
404 | [CPU_SH4_202] = "SH4-202", [CPU_SH4_501] = "SH4-501", | 391 | [CPU_SH4_202] = "SH4-202", [CPU_SH4_501] = "SH4-501", |
405 | [CPU_SH7770] = "SH7770", [CPU_SH7780] = "SH7780", | 392 | [CPU_SH7770] = "SH7770", [CPU_SH7780] = "SH7780", |
406 | [CPU_SH7781] = "SH7781", [CPU_SH7343] = "SH7343", | 393 | [CPU_SH7781] = "SH7781", [CPU_SH7343] = "SH7343", |
407 | [CPU_SH7785] = "SH7785", | 394 | [CPU_SH7785] = "SH7785", [CPU_SH7722] = "SH7722", |
408 | [CPU_SH_NONE] = "Unknown" | 395 | [CPU_SH_NONE] = "Unknown" |
409 | }; | 396 | }; |
410 | 397 | ||
diff --git a/arch/sh/kernel/sh_ksyms.c b/arch/sh/kernel/sh_ksyms.c index ceee79143401..e6106239a0fe 100644 --- a/arch/sh/kernel/sh_ksyms.c +++ b/arch/sh/kernel/sh_ksyms.c | |||
@@ -70,13 +70,26 @@ DECLARE_EXPORT(__sdivsi3); | |||
70 | DECLARE_EXPORT(__ashrdi3); | 70 | DECLARE_EXPORT(__ashrdi3); |
71 | DECLARE_EXPORT(__ashldi3); | 71 | DECLARE_EXPORT(__ashldi3); |
72 | DECLARE_EXPORT(__lshrdi3); | 72 | DECLARE_EXPORT(__lshrdi3); |
73 | DECLARE_EXPORT(__movstr); | ||
74 | DECLARE_EXPORT(__movstrSI16); | 73 | DECLARE_EXPORT(__movstrSI16); |
74 | #if __GNUC__ == 4 | ||
75 | DECLARE_EXPORT(__movmem); | ||
76 | #else | ||
77 | DECLARE_EXPORT(__movstr); | ||
78 | #endif | ||
75 | 79 | ||
76 | #ifdef CONFIG_CPU_SH4 | 80 | #ifdef CONFIG_CPU_SH4 |
81 | #if __GNUC__ == 4 | ||
82 | DECLARE_EXPORT(__movmem_i4_even); | ||
83 | DECLARE_EXPORT(__movmem_i4_odd); | ||
84 | DECLARE_EXPORT(__movmemSI12_i4); | ||
85 | DECLARE_EXPORT(__sdivsi3_i4i); | ||
86 | DECLARE_EXPORT(__udiv_qrnnd_16); | ||
87 | DECLARE_EXPORT(__udivsi3_i4i); | ||
88 | #else /* GCC 3.x */ | ||
77 | DECLARE_EXPORT(__movstr_i4_even); | 89 | DECLARE_EXPORT(__movstr_i4_even); |
78 | DECLARE_EXPORT(__movstr_i4_odd); | 90 | DECLARE_EXPORT(__movstr_i4_odd); |
79 | DECLARE_EXPORT(__movstrSI12_i4); | 91 | DECLARE_EXPORT(__movstrSI12_i4); |
92 | #endif /* __GNUC__ == 4 */ | ||
80 | #endif | 93 | #endif |
81 | 94 | ||
82 | #if defined(CONFIG_CPU_SH4) || defined(CONFIG_SH7705_CACHE_32KB) | 95 | #if defined(CONFIG_CPU_SH4) || defined(CONFIG_SH7705_CACHE_32KB) |
diff --git a/arch/sh/kernel/signal.c b/arch/sh/kernel/signal.c index bb1c480a59c7..379c88bf5d9a 100644 --- a/arch/sh/kernel/signal.c +++ b/arch/sh/kernel/signal.c | |||
@@ -101,7 +101,7 @@ sys_sigaltstack(const stack_t __user *uss, stack_t __user *uoss, | |||
101 | */ | 101 | */ |
102 | 102 | ||
103 | #define MOVW(n) (0x9300|((n)-2)) /* Move mem word at PC+n to R3 */ | 103 | #define MOVW(n) (0x9300|((n)-2)) /* Move mem word at PC+n to R3 */ |
104 | #if defined(CONFIG_CPU_SH2) || defined(CONFIG_CPU_SH2A) | 104 | #if defined(CONFIG_CPU_SH2) |
105 | #define TRAP_NOARG 0xc320 /* Syscall w/no args (NR in R3) */ | 105 | #define TRAP_NOARG 0xc320 /* Syscall w/no args (NR in R3) */ |
106 | #else | 106 | #else |
107 | #define TRAP_NOARG 0xc310 /* Syscall w/no args (NR in R3) */ | 107 | #define TRAP_NOARG 0xc310 /* Syscall w/no args (NR in R3) */ |
diff --git a/arch/sh/kernel/sys_sh.c b/arch/sh/kernel/sys_sh.c index 5083b6ed4b39..e18f183e1035 100644 --- a/arch/sh/kernel/sys_sh.c +++ b/arch/sh/kernel/sys_sh.c | |||
@@ -314,6 +314,12 @@ asmlinkage int sys_fadvise64_64_wrapper(int fd, u32 offset0, u32 offset1, | |||
314 | #endif | 314 | #endif |
315 | } | 315 | } |
316 | 316 | ||
317 | #if defined(CONFIG_CPU_SH2) || defined(CONFIG_CPU_SH2A) | ||
318 | #define SYSCALL_ARG3 "trapa #0x23" | ||
319 | #else | ||
320 | #define SYSCALL_ARG3 "trapa #0x13" | ||
321 | #endif | ||
322 | |||
317 | /* | 323 | /* |
318 | * Do a system call from kernel instead of calling sys_execve so we | 324 | * Do a system call from kernel instead of calling sys_execve so we |
319 | * end up with proper pt_regs. | 325 | * end up with proper pt_regs. |
@@ -324,7 +330,7 @@ int kernel_execve(const char *filename, char *const argv[], char *const envp[]) | |||
324 | register long __sc4 __asm__ ("r4") = (long) filename; | 330 | register long __sc4 __asm__ ("r4") = (long) filename; |
325 | register long __sc5 __asm__ ("r5") = (long) argv; | 331 | register long __sc5 __asm__ ("r5") = (long) argv; |
326 | register long __sc6 __asm__ ("r6") = (long) envp; | 332 | register long __sc6 __asm__ ("r6") = (long) envp; |
327 | __asm__ __volatile__ ("trapa #0x13" : "=z" (__sc0) | 333 | __asm__ __volatile__ (SYSCALL_ARG3 : "=z" (__sc0) |
328 | : "0" (__sc0), "r" (__sc4), "r" (__sc5), "r" (__sc6) | 334 | : "0" (__sc0), "r" (__sc4), "r" (__sc5), "r" (__sc6) |
329 | : "memory"); | 335 | : "memory"); |
330 | return __sc0; | 336 | return __sc0; |
diff --git a/arch/sh/kernel/traps.c b/arch/sh/kernel/traps.c index 3762d9dc2046..ec110157992d 100644 --- a/arch/sh/kernel/traps.c +++ b/arch/sh/kernel/traps.c | |||
@@ -19,6 +19,7 @@ | |||
19 | #include <linux/kallsyms.h> | 19 | #include <linux/kallsyms.h> |
20 | #include <linux/io.h> | 20 | #include <linux/io.h> |
21 | #include <linux/debug_locks.h> | 21 | #include <linux/debug_locks.h> |
22 | #include <linux/limits.h> | ||
22 | #include <asm/system.h> | 23 | #include <asm/system.h> |
23 | #include <asm/uaccess.h> | 24 | #include <asm/uaccess.h> |
24 | 25 | ||
@@ -129,6 +130,40 @@ static int die_if_no_fixup(const char * str, struct pt_regs * regs, long err) | |||
129 | return -EFAULT; | 130 | return -EFAULT; |
130 | } | 131 | } |
131 | 132 | ||
133 | #ifdef CONFIG_BUG | ||
134 | #ifdef CONFIG_DEBUG_BUGVERBOSE | ||
135 | static inline void do_bug_verbose(struct pt_regs *regs) | ||
136 | { | ||
137 | struct bug_frame f; | ||
138 | long len; | ||
139 | |||
140 | if (__copy_from_user(&f, (const void __user *)regs->pc, | ||
141 | sizeof(struct bug_frame))) | ||
142 | return; | ||
143 | |||
144 | len = __strnlen_user(f.file, PATH_MAX) - 1; | ||
145 | if (unlikely(len < 0 || len >= PATH_MAX)) | ||
146 | f.file = "<bad filename>"; | ||
147 | len = __strnlen_user(f.func, PATH_MAX) - 1; | ||
148 | if (unlikely(len < 0 || len >= PATH_MAX)) | ||
149 | f.func = "<bad function>"; | ||
150 | |||
151 | printk(KERN_ALERT "kernel BUG in %s() at %s:%d!\n", | ||
152 | f.func, f.file, f.line); | ||
153 | } | ||
154 | #else | ||
155 | static inline void do_bug_verbose(struct pt_regs *regs) | ||
156 | { | ||
157 | } | ||
158 | #endif /* CONFIG_DEBUG_BUGVERBOSE */ | ||
159 | #endif /* CONFIG_BUG */ | ||
160 | |||
161 | void handle_BUG(struct pt_regs *regs) | ||
162 | { | ||
163 | do_bug_verbose(regs); | ||
164 | die("Kernel BUG", regs, TRAPA_BUG_OPCODE & 0xff); | ||
165 | } | ||
166 | |||
132 | /* | 167 | /* |
133 | * handle an instruction that does an unaligned memory access by emulating the | 168 | * handle an instruction that does an unaligned memory access by emulating the |
134 | * desired behaviour | 169 | * desired behaviour |
diff --git a/arch/sh/kernel/vmlinux.lds.S b/arch/sh/kernel/vmlinux.lds.S index 77b4026d5688..f34bdcc33a7d 100644 --- a/arch/sh/kernel/vmlinux.lds.S +++ b/arch/sh/kernel/vmlinux.lds.S | |||
@@ -51,7 +51,7 @@ SECTIONS | |||
51 | } | 51 | } |
52 | 52 | ||
53 | . = ALIGN(PAGE_SIZE); | 53 | . = ALIGN(PAGE_SIZE); |
54 | .data.page_aligned : { *(.data.idt) } | 54 | .data.page_aligned : { *(.data.page_aligned) } |
55 | 55 | ||
56 | . = ALIGN(32); | 56 | . = ALIGN(32); |
57 | __per_cpu_start = .; | 57 | __per_cpu_start = .; |
diff --git a/arch/sh/mm/Kconfig b/arch/sh/mm/Kconfig index 4e0362f50384..29f4ee35c6dc 100644 --- a/arch/sh/mm/Kconfig +++ b/arch/sh/mm/Kconfig | |||
@@ -35,6 +35,9 @@ config CPU_SUBTYPE_ST40 | |||
35 | select CPU_SH4 | 35 | select CPU_SH4 |
36 | select CPU_HAS_INTC2_IRQ | 36 | select CPU_HAS_INTC2_IRQ |
37 | 37 | ||
38 | config CPU_SHX2 | ||
39 | bool | ||
40 | |||
38 | # | 41 | # |
39 | # Processor subtypes | 42 | # Processor subtypes |
40 | # | 43 | # |
@@ -180,6 +183,7 @@ config CPU_SUBTYPE_SH7780 | |||
180 | config CPU_SUBTYPE_SH7785 | 183 | config CPU_SUBTYPE_SH7785 |
181 | bool "Support SH7785 processor" | 184 | bool "Support SH7785 processor" |
182 | select CPU_SH4A | 185 | select CPU_SH4A |
186 | select CPU_SHX2 | ||
183 | select CPU_HAS_INTC2_IRQ | 187 | select CPU_HAS_INTC2_IRQ |
184 | 188 | ||
185 | comment "SH4AL-DSP Processor Support" | 189 | comment "SH4AL-DSP Processor Support" |
@@ -192,6 +196,12 @@ config CPU_SUBTYPE_SH7343 | |||
192 | bool "Support SH7343 processor" | 196 | bool "Support SH7343 processor" |
193 | select CPU_SH4AL_DSP | 197 | select CPU_SH4AL_DSP |
194 | 198 | ||
199 | config CPU_SUBTYPE_SH7722 | ||
200 | bool "Support SH7722 processor" | ||
201 | select CPU_SH4AL_DSP | ||
202 | select CPU_SHX2 | ||
203 | select CPU_HAS_IPR_IRQ | ||
204 | |||
195 | endmenu | 205 | endmenu |
196 | 206 | ||
197 | menu "Memory management options" | 207 | menu "Memory management options" |
@@ -250,7 +260,7 @@ config 32BIT | |||
250 | 260 | ||
251 | config X2TLB | 261 | config X2TLB |
252 | bool "Enable extended TLB mode" | 262 | bool "Enable extended TLB mode" |
253 | depends on CPU_SUBTYPE_SH7785 && MMU && EXPERIMENTAL | 263 | depends on CPU_SHX2 && MMU && EXPERIMENTAL |
254 | help | 264 | help |
255 | Selecting this option will enable the extended mode of the SH-X2 | 265 | Selecting this option will enable the extended mode of the SH-X2 |
256 | TLB. For legacy SH-X behaviour and interoperability, say N. For | 266 | TLB. For legacy SH-X behaviour and interoperability, say N. For |
diff --git a/arch/sh/mm/cache-sh4.c b/arch/sh/mm/cache-sh4.c index ae531affccbd..c6955157c989 100644 --- a/arch/sh/mm/cache-sh4.c +++ b/arch/sh/mm/cache-sh4.c | |||
@@ -107,7 +107,7 @@ void __init p3_cache_init(void) | |||
107 | 107 | ||
108 | emit_cache_params(); | 108 | emit_cache_params(); |
109 | 109 | ||
110 | if (remap_area_pages(P3SEG, 0, PAGE_SIZE * 4, _PAGE_CACHABLE)) | 110 | if (ioremap_page_range(P3SEG, P3SEG + (PAGE_SIZE * 4), 0, PAGE_KERNEL)) |
111 | panic("%s failed.", __FUNCTION__); | 111 | panic("%s failed.", __FUNCTION__); |
112 | 112 | ||
113 | for (i = 0; i < cpu_data->dcache.n_aliases; i++) | 113 | for (i = 0; i < cpu_data->dcache.n_aliases; i++) |
diff --git a/arch/sh/mm/init.c b/arch/sh/mm/init.c index 59f4cc18235b..29bd37b1488e 100644 --- a/arch/sh/mm/init.c +++ b/arch/sh/mm/init.c | |||
@@ -77,6 +77,7 @@ void show_mem(void) | |||
77 | printk("%d pages swap cached\n",cached); | 77 | printk("%d pages swap cached\n",cached); |
78 | } | 78 | } |
79 | 79 | ||
80 | #ifdef CONFIG_MMU | ||
80 | static void set_pte_phys(unsigned long addr, unsigned long phys, pgprot_t prot) | 81 | static void set_pte_phys(unsigned long addr, unsigned long phys, pgprot_t prot) |
81 | { | 82 | { |
82 | pgd_t *pgd; | 83 | pgd_t *pgd; |
@@ -139,6 +140,7 @@ void __set_fixmap(enum fixed_addresses idx, unsigned long phys, pgprot_t prot) | |||
139 | 140 | ||
140 | set_pte_phys(address, phys, prot); | 141 | set_pte_phys(address, phys, prot); |
141 | } | 142 | } |
143 | #endif /* CONFIG_MMU */ | ||
142 | 144 | ||
143 | /* References to section boundaries */ | 145 | /* References to section boundaries */ |
144 | 146 | ||
diff --git a/drivers/rtc/rtc-sh.c b/drivers/rtc/rtc-sh.c index 143302a8e79c..72ba1a70f35f 100644 --- a/drivers/rtc/rtc-sh.c +++ b/drivers/rtc/rtc-sh.c | |||
@@ -2,6 +2,7 @@ | |||
2 | * SuperH On-Chip RTC Support | 2 | * SuperH On-Chip RTC Support |
3 | * | 3 | * |
4 | * Copyright (C) 2006 Paul Mundt | 4 | * Copyright (C) 2006 Paul Mundt |
5 | * Copyright (C) 2006 Jamie Lenehan | ||
5 | * | 6 | * |
6 | * Based on the old arch/sh/kernel/cpu/rtc.c by: | 7 | * Based on the old arch/sh/kernel/cpu/rtc.c by: |
7 | * | 8 | * |
@@ -21,7 +22,10 @@ | |||
21 | #include <linux/seq_file.h> | 22 | #include <linux/seq_file.h> |
22 | #include <linux/interrupt.h> | 23 | #include <linux/interrupt.h> |
23 | #include <linux/spinlock.h> | 24 | #include <linux/spinlock.h> |
24 | #include <asm/io.h> | 25 | #include <linux/io.h> |
26 | |||
27 | #define DRV_NAME "sh-rtc" | ||
28 | #define DRV_VERSION "0.1.2" | ||
25 | 29 | ||
26 | #ifdef CONFIG_CPU_SH3 | 30 | #ifdef CONFIG_CPU_SH3 |
27 | #define rtc_reg_size sizeof(u16) | 31 | #define rtc_reg_size sizeof(u16) |
@@ -33,22 +37,26 @@ | |||
33 | 37 | ||
34 | #define RTC_REG(r) ((r) * rtc_reg_size) | 38 | #define RTC_REG(r) ((r) * rtc_reg_size) |
35 | 39 | ||
36 | #define R64CNT RTC_REG(0) | 40 | #define R64CNT RTC_REG(0) |
37 | #define RSECCNT RTC_REG(1) | 41 | |
38 | #define RMINCNT RTC_REG(2) | 42 | #define RSECCNT RTC_REG(1) /* RTC sec */ |
39 | #define RHRCNT RTC_REG(3) | 43 | #define RMINCNT RTC_REG(2) /* RTC min */ |
40 | #define RWKCNT RTC_REG(4) | 44 | #define RHRCNT RTC_REG(3) /* RTC hour */ |
41 | #define RDAYCNT RTC_REG(5) | 45 | #define RWKCNT RTC_REG(4) /* RTC week */ |
42 | #define RMONCNT RTC_REG(6) | 46 | #define RDAYCNT RTC_REG(5) /* RTC day */ |
43 | #define RYRCNT RTC_REG(7) | 47 | #define RMONCNT RTC_REG(6) /* RTC month */ |
44 | #define RSECAR RTC_REG(8) | 48 | #define RYRCNT RTC_REG(7) /* RTC year */ |
45 | #define RMINAR RTC_REG(9) | 49 | #define RSECAR RTC_REG(8) /* ALARM sec */ |
46 | #define RHRAR RTC_REG(10) | 50 | #define RMINAR RTC_REG(9) /* ALARM min */ |
47 | #define RWKAR RTC_REG(11) | 51 | #define RHRAR RTC_REG(10) /* ALARM hour */ |
48 | #define RDAYAR RTC_REG(12) | 52 | #define RWKAR RTC_REG(11) /* ALARM week */ |
49 | #define RMONAR RTC_REG(13) | 53 | #define RDAYAR RTC_REG(12) /* ALARM day */ |
50 | #define RCR1 RTC_REG(14) | 54 | #define RMONAR RTC_REG(13) /* ALARM month */ |
51 | #define RCR2 RTC_REG(15) | 55 | #define RCR1 RTC_REG(14) /* Control */ |
56 | #define RCR2 RTC_REG(15) /* Control */ | ||
57 | |||
58 | /* ALARM Bits - or with BCD encoded value */ | ||
59 | #define AR_ENB 0x80 /* Enable for alarm cmp */ | ||
52 | 60 | ||
53 | /* RCR1 Bits */ | 61 | /* RCR1 Bits */ |
54 | #define RCR1_CF 0x80 /* Carry Flag */ | 62 | #define RCR1_CF 0x80 /* Carry Flag */ |
@@ -71,22 +79,28 @@ struct sh_rtc { | |||
71 | unsigned int alarm_irq, periodic_irq, carry_irq; | 79 | unsigned int alarm_irq, periodic_irq, carry_irq; |
72 | struct rtc_device *rtc_dev; | 80 | struct rtc_device *rtc_dev; |
73 | spinlock_t lock; | 81 | spinlock_t lock; |
82 | int rearm_aie; | ||
74 | }; | 83 | }; |
75 | 84 | ||
76 | static irqreturn_t sh_rtc_interrupt(int irq, void *id) | 85 | static irqreturn_t sh_rtc_interrupt(int irq, void *dev_id) |
77 | { | 86 | { |
78 | struct platform_device *pdev = id; | 87 | struct platform_device *pdev = to_platform_device(dev_id); |
79 | struct sh_rtc *rtc = platform_get_drvdata(pdev); | 88 | struct sh_rtc *rtc = platform_get_drvdata(pdev); |
80 | unsigned int tmp, events = 0; | 89 | unsigned int tmp, events = 0; |
81 | 90 | ||
82 | spin_lock(&rtc->lock); | 91 | spin_lock(&rtc->lock); |
83 | 92 | ||
84 | tmp = readb(rtc->regbase + RCR1); | 93 | tmp = readb(rtc->regbase + RCR1); |
94 | tmp &= ~RCR1_CF; | ||
85 | 95 | ||
86 | if (tmp & RCR1_AF) | 96 | if (rtc->rearm_aie) { |
87 | events |= RTC_AF | RTC_IRQF; | 97 | if (tmp & RCR1_AF) |
88 | 98 | tmp &= ~RCR1_AF; /* try to clear AF again */ | |
89 | tmp &= ~(RCR1_CF | RCR1_AF); | 99 | else { |
100 | tmp |= RCR1_AIE; /* AF has cleared, rearm IRQ */ | ||
101 | rtc->rearm_aie = 0; | ||
102 | } | ||
103 | } | ||
90 | 104 | ||
91 | writeb(tmp, rtc->regbase + RCR1); | 105 | writeb(tmp, rtc->regbase + RCR1); |
92 | 106 | ||
@@ -97,9 +111,45 @@ static irqreturn_t sh_rtc_interrupt(int irq, void *id) | |||
97 | return IRQ_HANDLED; | 111 | return IRQ_HANDLED; |
98 | } | 112 | } |
99 | 113 | ||
100 | static irqreturn_t sh_rtc_periodic(int irq, void *id) | 114 | static irqreturn_t sh_rtc_alarm(int irq, void *dev_id) |
115 | { | ||
116 | struct platform_device *pdev = to_platform_device(dev_id); | ||
117 | struct sh_rtc *rtc = platform_get_drvdata(pdev); | ||
118 | unsigned int tmp, events = 0; | ||
119 | |||
120 | spin_lock(&rtc->lock); | ||
121 | |||
122 | tmp = readb(rtc->regbase + RCR1); | ||
123 | |||
124 | /* | ||
125 | * If AF is set then the alarm has triggered. If we clear AF while | ||
126 | * the alarm time still matches the RTC time then AF will | ||
127 | * immediately be set again, and if AIE is enabled then the alarm | ||
128 | * interrupt will immediately be retrigger. So we clear AIE here | ||
129 | * and use rtc->rearm_aie so that the carry interrupt will keep | ||
130 | * trying to clear AF and once it stays cleared it'll re-enable | ||
131 | * AIE. | ||
132 | */ | ||
133 | if (tmp & RCR1_AF) { | ||
134 | events |= RTC_AF | RTC_IRQF; | ||
135 | |||
136 | tmp &= ~(RCR1_AF|RCR1_AIE); | ||
137 | |||
138 | writeb(tmp, rtc->regbase + RCR1); | ||
139 | |||
140 | rtc->rearm_aie = 1; | ||
141 | |||
142 | rtc_update_irq(&rtc->rtc_dev->class_dev, 1, events); | ||
143 | } | ||
144 | |||
145 | spin_unlock(&rtc->lock); | ||
146 | return IRQ_HANDLED; | ||
147 | } | ||
148 | |||
149 | static irqreturn_t sh_rtc_periodic(int irq, void *dev_id) | ||
101 | { | 150 | { |
102 | struct sh_rtc *rtc = dev_get_drvdata(id); | 151 | struct platform_device *pdev = to_platform_device(dev_id); |
152 | struct sh_rtc *rtc = platform_get_drvdata(pdev); | ||
103 | 153 | ||
104 | spin_lock(&rtc->lock); | 154 | spin_lock(&rtc->lock); |
105 | 155 | ||
@@ -139,10 +189,11 @@ static inline void sh_rtc_setaie(struct device *dev, unsigned int enable) | |||
139 | 189 | ||
140 | tmp = readb(rtc->regbase + RCR1); | 190 | tmp = readb(rtc->regbase + RCR1); |
141 | 191 | ||
142 | if (enable) | 192 | if (!enable) { |
143 | tmp |= RCR1_AIE; | ||
144 | else | ||
145 | tmp &= ~RCR1_AIE; | 193 | tmp &= ~RCR1_AIE; |
194 | rtc->rearm_aie = 0; | ||
195 | } else if (rtc->rearm_aie == 0) | ||
196 | tmp |= RCR1_AIE; | ||
146 | 197 | ||
147 | writeb(tmp, rtc->regbase + RCR1); | 198 | writeb(tmp, rtc->regbase + RCR1); |
148 | 199 | ||
@@ -177,7 +228,7 @@ static int sh_rtc_open(struct device *dev) | |||
177 | goto err_bad_carry; | 228 | goto err_bad_carry; |
178 | } | 229 | } |
179 | 230 | ||
180 | ret = request_irq(rtc->alarm_irq, sh_rtc_interrupt, IRQF_DISABLED, | 231 | ret = request_irq(rtc->alarm_irq, sh_rtc_alarm, IRQF_DISABLED, |
181 | "sh-rtc alarm", dev); | 232 | "sh-rtc alarm", dev); |
182 | if (unlikely(ret)) { | 233 | if (unlikely(ret)) { |
183 | dev_err(dev, "request alarm IRQ failed with %d, IRQ %d\n", | 234 | dev_err(dev, "request alarm IRQ failed with %d, IRQ %d\n", |
@@ -200,6 +251,7 @@ static void sh_rtc_release(struct device *dev) | |||
200 | struct sh_rtc *rtc = dev_get_drvdata(dev); | 251 | struct sh_rtc *rtc = dev_get_drvdata(dev); |
201 | 252 | ||
202 | sh_rtc_setpie(dev, 0); | 253 | sh_rtc_setpie(dev, 0); |
254 | sh_rtc_setaie(dev, 0); | ||
203 | 255 | ||
204 | free_irq(rtc->periodic_irq, dev); | 256 | free_irq(rtc->periodic_irq, dev); |
205 | free_irq(rtc->carry_irq, dev); | 257 | free_irq(rtc->carry_irq, dev); |
@@ -267,7 +319,7 @@ static int sh_rtc_read_time(struct device *dev, struct rtc_time *tm) | |||
267 | tm->tm_hour = BCD2BIN(readb(rtc->regbase + RHRCNT)); | 319 | tm->tm_hour = BCD2BIN(readb(rtc->regbase + RHRCNT)); |
268 | tm->tm_wday = BCD2BIN(readb(rtc->regbase + RWKCNT)); | 320 | tm->tm_wday = BCD2BIN(readb(rtc->regbase + RWKCNT)); |
269 | tm->tm_mday = BCD2BIN(readb(rtc->regbase + RDAYCNT)); | 321 | tm->tm_mday = BCD2BIN(readb(rtc->regbase + RDAYCNT)); |
270 | tm->tm_mon = BCD2BIN(readb(rtc->regbase + RMONCNT)); | 322 | tm->tm_mon = BCD2BIN(readb(rtc->regbase + RMONCNT)) - 1; |
271 | 323 | ||
272 | #if defined(CONFIG_CPU_SH4) | 324 | #if defined(CONFIG_CPU_SH4) |
273 | yr = readw(rtc->regbase + RYRCNT); | 325 | yr = readw(rtc->regbase + RYRCNT); |
@@ -295,7 +347,7 @@ static int sh_rtc_read_time(struct device *dev, struct rtc_time *tm) | |||
295 | "mday=%d, mon=%d, year=%d, wday=%d\n", | 347 | "mday=%d, mon=%d, year=%d, wday=%d\n", |
296 | __FUNCTION__, | 348 | __FUNCTION__, |
297 | tm->tm_sec, tm->tm_min, tm->tm_hour, | 349 | tm->tm_sec, tm->tm_min, tm->tm_hour, |
298 | tm->tm_mday, tm->tm_mon, tm->tm_year, tm->tm_wday); | 350 | tm->tm_mday, tm->tm_mon + 1, tm->tm_year, tm->tm_wday); |
299 | 351 | ||
300 | if (rtc_valid_tm(tm) < 0) | 352 | if (rtc_valid_tm(tm) < 0) |
301 | dev_err(dev, "invalid date\n"); | 353 | dev_err(dev, "invalid date\n"); |
@@ -322,7 +374,7 @@ static int sh_rtc_set_time(struct device *dev, struct rtc_time *tm) | |||
322 | writeb(BIN2BCD(tm->tm_hour), rtc->regbase + RHRCNT); | 374 | writeb(BIN2BCD(tm->tm_hour), rtc->regbase + RHRCNT); |
323 | writeb(BIN2BCD(tm->tm_wday), rtc->regbase + RWKCNT); | 375 | writeb(BIN2BCD(tm->tm_wday), rtc->regbase + RWKCNT); |
324 | writeb(BIN2BCD(tm->tm_mday), rtc->regbase + RDAYCNT); | 376 | writeb(BIN2BCD(tm->tm_mday), rtc->regbase + RDAYCNT); |
325 | writeb(BIN2BCD(tm->tm_mon), rtc->regbase + RMONCNT); | 377 | writeb(BIN2BCD(tm->tm_mon + 1), rtc->regbase + RMONCNT); |
326 | 378 | ||
327 | #ifdef CONFIG_CPU_SH3 | 379 | #ifdef CONFIG_CPU_SH3 |
328 | year = tm->tm_year % 100; | 380 | year = tm->tm_year % 100; |
@@ -344,12 +396,136 @@ static int sh_rtc_set_time(struct device *dev, struct rtc_time *tm) | |||
344 | return 0; | 396 | return 0; |
345 | } | 397 | } |
346 | 398 | ||
399 | static inline int sh_rtc_read_alarm_value(struct sh_rtc *rtc, int reg_off) | ||
400 | { | ||
401 | unsigned int byte; | ||
402 | int value = 0xff; /* return 0xff for ignored values */ | ||
403 | |||
404 | byte = readb(rtc->regbase + reg_off); | ||
405 | if (byte & AR_ENB) { | ||
406 | byte &= ~AR_ENB; /* strip the enable bit */ | ||
407 | value = BCD2BIN(byte); | ||
408 | } | ||
409 | |||
410 | return value; | ||
411 | } | ||
412 | |||
413 | static int sh_rtc_read_alarm(struct device *dev, struct rtc_wkalrm *wkalrm) | ||
414 | { | ||
415 | struct platform_device *pdev = to_platform_device(dev); | ||
416 | struct sh_rtc *rtc = platform_get_drvdata(pdev); | ||
417 | struct rtc_time* tm = &wkalrm->time; | ||
418 | |||
419 | spin_lock_irq(&rtc->lock); | ||
420 | |||
421 | tm->tm_sec = sh_rtc_read_alarm_value(rtc, RSECAR); | ||
422 | tm->tm_min = sh_rtc_read_alarm_value(rtc, RMINAR); | ||
423 | tm->tm_hour = sh_rtc_read_alarm_value(rtc, RHRAR); | ||
424 | tm->tm_wday = sh_rtc_read_alarm_value(rtc, RWKAR); | ||
425 | tm->tm_mday = sh_rtc_read_alarm_value(rtc, RDAYAR); | ||
426 | tm->tm_mon = sh_rtc_read_alarm_value(rtc, RMONAR); | ||
427 | if (tm->tm_mon > 0) | ||
428 | tm->tm_mon -= 1; /* RTC is 1-12, tm_mon is 0-11 */ | ||
429 | tm->tm_year = 0xffff; | ||
430 | |||
431 | spin_unlock_irq(&rtc->lock); | ||
432 | |||
433 | return 0; | ||
434 | } | ||
435 | |||
436 | static inline void sh_rtc_write_alarm_value(struct sh_rtc *rtc, | ||
437 | int value, int reg_off) | ||
438 | { | ||
439 | /* < 0 for a value that is ignored */ | ||
440 | if (value < 0) | ||
441 | writeb(0, rtc->regbase + reg_off); | ||
442 | else | ||
443 | writeb(BIN2BCD(value) | AR_ENB, rtc->regbase + reg_off); | ||
444 | } | ||
445 | |||
446 | static int sh_rtc_check_alarm(struct rtc_time* tm) | ||
447 | { | ||
448 | /* | ||
449 | * The original rtc says anything > 0xc0 is "don't care" or "match | ||
450 | * all" - most users use 0xff but rtc-dev uses -1 for the same thing. | ||
451 | * The original rtc doesn't support years - some things use -1 and | ||
452 | * some 0xffff. We use -1 to make out tests easier. | ||
453 | */ | ||
454 | if (tm->tm_year == 0xffff) | ||
455 | tm->tm_year = -1; | ||
456 | if (tm->tm_mon >= 0xff) | ||
457 | tm->tm_mon = -1; | ||
458 | if (tm->tm_mday >= 0xff) | ||
459 | tm->tm_mday = -1; | ||
460 | if (tm->tm_wday >= 0xff) | ||
461 | tm->tm_wday = -1; | ||
462 | if (tm->tm_hour >= 0xff) | ||
463 | tm->tm_hour = -1; | ||
464 | if (tm->tm_min >= 0xff) | ||
465 | tm->tm_min = -1; | ||
466 | if (tm->tm_sec >= 0xff) | ||
467 | tm->tm_sec = -1; | ||
468 | |||
469 | if (tm->tm_year > 9999 || | ||
470 | tm->tm_mon >= 12 || | ||
471 | tm->tm_mday == 0 || tm->tm_mday >= 32 || | ||
472 | tm->tm_wday >= 7 || | ||
473 | tm->tm_hour >= 24 || | ||
474 | tm->tm_min >= 60 || | ||
475 | tm->tm_sec >= 60) | ||
476 | return -EINVAL; | ||
477 | |||
478 | return 0; | ||
479 | } | ||
480 | |||
481 | static int sh_rtc_set_alarm(struct device *dev, struct rtc_wkalrm *wkalrm) | ||
482 | { | ||
483 | struct platform_device *pdev = to_platform_device(dev); | ||
484 | struct sh_rtc *rtc = platform_get_drvdata(pdev); | ||
485 | unsigned int rcr1; | ||
486 | struct rtc_time *tm = &wkalrm->time; | ||
487 | int mon, err; | ||
488 | |||
489 | err = sh_rtc_check_alarm(tm); | ||
490 | if (unlikely(err < 0)) | ||
491 | return err; | ||
492 | |||
493 | spin_lock_irq(&rtc->lock); | ||
494 | |||
495 | /* disable alarm interrupt and clear flag */ | ||
496 | rcr1 = readb(rtc->regbase + RCR1); | ||
497 | rcr1 &= ~RCR1_AF; | ||
498 | writeb(rcr1 & ~RCR1_AIE, rtc->regbase + RCR1); | ||
499 | |||
500 | rtc->rearm_aie = 0; | ||
501 | |||
502 | /* set alarm time */ | ||
503 | sh_rtc_write_alarm_value(rtc, tm->tm_sec, RSECAR); | ||
504 | sh_rtc_write_alarm_value(rtc, tm->tm_min, RMINAR); | ||
505 | sh_rtc_write_alarm_value(rtc, tm->tm_hour, RHRAR); | ||
506 | sh_rtc_write_alarm_value(rtc, tm->tm_wday, RWKAR); | ||
507 | sh_rtc_write_alarm_value(rtc, tm->tm_mday, RDAYAR); | ||
508 | mon = tm->tm_mon; | ||
509 | if (mon >= 0) | ||
510 | mon += 1; | ||
511 | sh_rtc_write_alarm_value(rtc, mon, RMONAR); | ||
512 | |||
513 | /* Restore interrupt activation status */ | ||
514 | writeb(rcr1, rtc->regbase + RCR1); | ||
515 | |||
516 | spin_unlock_irq(&rtc->lock); | ||
517 | |||
518 | return 0; | ||
519 | } | ||
520 | |||
347 | static struct rtc_class_ops sh_rtc_ops = { | 521 | static struct rtc_class_ops sh_rtc_ops = { |
348 | .open = sh_rtc_open, | 522 | .open = sh_rtc_open, |
349 | .release = sh_rtc_release, | 523 | .release = sh_rtc_release, |
350 | .ioctl = sh_rtc_ioctl, | 524 | .ioctl = sh_rtc_ioctl, |
351 | .read_time = sh_rtc_read_time, | 525 | .read_time = sh_rtc_read_time, |
352 | .set_time = sh_rtc_set_time, | 526 | .set_time = sh_rtc_set_time, |
527 | .read_alarm = sh_rtc_read_alarm, | ||
528 | .set_alarm = sh_rtc_set_alarm, | ||
353 | .proc = sh_rtc_proc, | 529 | .proc = sh_rtc_proc, |
354 | }; | 530 | }; |
355 | 531 | ||
@@ -442,7 +618,7 @@ static int __devexit sh_rtc_remove(struct platform_device *pdev) | |||
442 | } | 618 | } |
443 | static struct platform_driver sh_rtc_platform_driver = { | 619 | static struct platform_driver sh_rtc_platform_driver = { |
444 | .driver = { | 620 | .driver = { |
445 | .name = "sh-rtc", | 621 | .name = DRV_NAME, |
446 | .owner = THIS_MODULE, | 622 | .owner = THIS_MODULE, |
447 | }, | 623 | }, |
448 | .probe = sh_rtc_probe, | 624 | .probe = sh_rtc_probe, |
@@ -463,5 +639,6 @@ module_init(sh_rtc_init); | |||
463 | module_exit(sh_rtc_exit); | 639 | module_exit(sh_rtc_exit); |
464 | 640 | ||
465 | MODULE_DESCRIPTION("SuperH on-chip RTC driver"); | 641 | MODULE_DESCRIPTION("SuperH on-chip RTC driver"); |
466 | MODULE_AUTHOR("Paul Mundt <lethal@linux-sh.org>"); | 642 | MODULE_VERSION(DRV_VERSION); |
643 | MODULE_AUTHOR("Paul Mundt <lethal@linux-sh.org>, Jamie Lenehan <lenehan@twibble.org>"); | ||
467 | MODULE_LICENSE("GPL"); | 644 | MODULE_LICENSE("GPL"); |
diff --git a/drivers/serial/sh-sci.c b/drivers/serial/sh-sci.c index 9031b57f12dd..c53b69610a51 100644 --- a/drivers/serial/sh-sci.c +++ b/drivers/serial/sh-sci.c | |||
@@ -319,6 +319,28 @@ static void sci_init_pins_scif(struct uart_port *port, unsigned int cflag) | |||
319 | 319 | ||
320 | sci_out(port, SCFCR, fcr_val); | 320 | sci_out(port, SCFCR, fcr_val); |
321 | } | 321 | } |
322 | #elif defined(CONFIG_CPU_SUBTYPE_SH7722) | ||
323 | static void sci_init_pins_scif(struct uart_port *port, unsigned int cflag) | ||
324 | { | ||
325 | unsigned int fcr_val = 0; | ||
326 | |||
327 | if (cflag & CRTSCTS) { | ||
328 | fcr_val |= SCFCR_MCE; | ||
329 | |||
330 | ctrl_outw(0x0000, PORT_PSCR); | ||
331 | } else { | ||
332 | unsigned short data; | ||
333 | |||
334 | data = ctrl_inw(PORT_PSCR); | ||
335 | data &= 0x033f; | ||
336 | data |= 0x0400; | ||
337 | ctrl_outw(data, PORT_PSCR); | ||
338 | |||
339 | ctrl_outw(ctrl_inw(SCSPTR0) & 0x17, SCSPTR0); | ||
340 | } | ||
341 | |||
342 | sci_out(port, SCFCR, fcr_val); | ||
343 | } | ||
322 | #else | 344 | #else |
323 | /* For SH7750 */ | 345 | /* For SH7750 */ |
324 | static void sci_init_pins_scif(struct uart_port *port, unsigned int cflag) | 346 | static void sci_init_pins_scif(struct uart_port *port, unsigned int cflag) |
diff --git a/drivers/serial/sh-sci.h b/drivers/serial/sh-sci.h index e4557cc4f74b..77f7d6351ab1 100644 --- a/drivers/serial/sh-sci.h +++ b/drivers/serial/sh-sci.h | |||
@@ -90,6 +90,13 @@ | |||
90 | # define SCSPTR3 0xffe30010 /* 16 bit SCIF */ | 90 | # define SCSPTR3 0xffe30010 /* 16 bit SCIF */ |
91 | # define SCSCR_INIT(port) 0x32 /* TIE=0,RIE=0,TE=1,RE=1,REIE=0,CKE=1 */ | 91 | # define SCSCR_INIT(port) 0x32 /* TIE=0,RIE=0,TE=1,RE=1,REIE=0,CKE=1 */ |
92 | # define SCIF_ONLY | 92 | # define SCIF_ONLY |
93 | #elif defined(CONFIG_CPU_SUBTYPE_SH7722) | ||
94 | # define SCPDR0 0xA405013E /* 16 bit SCIF0 PSDR */ | ||
95 | # define SCSPTR0 SCPDR0 | ||
96 | # define SCIF_ORER 0x0001 /* overrun error bit */ | ||
97 | # define SCSCR_INIT(port) 0x0038 /* TIE=0,RIE=0,TE=1,RE=1,REIE=1 */ | ||
98 | # define SCIF_ONLY | ||
99 | # define PORT_PSCR 0xA405011E | ||
93 | #elif defined(CONFIG_CPU_SUBTYPE_SH4_202) | 100 | #elif defined(CONFIG_CPU_SUBTYPE_SH4_202) |
94 | # define SCSPTR2 0xffe80020 /* 16 bit SCIF */ | 101 | # define SCSPTR2 0xffe80020 /* 16 bit SCIF */ |
95 | # define SCIF_ORER 0x0001 /* overrun error bit */ | 102 | # define SCIF_ORER 0x0001 /* overrun error bit */ |
@@ -495,6 +502,7 @@ static inline int sci_rxd_in(struct uart_port *port) | |||
495 | return ctrl_inw(SCSPTR1) & 0x0001 ? 1 : 0; /* SCIF */ | 502 | return ctrl_inw(SCSPTR1) & 0x0001 ? 1 : 0; /* SCIF */ |
496 | if (port->mapbase == 0xfe620000) | 503 | if (port->mapbase == 0xfe620000) |
497 | return ctrl_inw(SCSPTR2) & 0x0001 ? 1 : 0; /* SCIF */ | 504 | return ctrl_inw(SCSPTR2) & 0x0001 ? 1 : 0; /* SCIF */ |
505 | return 1; | ||
498 | } | 506 | } |
499 | #elif defined(CONFIG_CPU_SUBTYPE_SH7300) | 507 | #elif defined(CONFIG_CPU_SUBTYPE_SH7300) |
500 | static inline int sci_rxd_in(struct uart_port *port) | 508 | static inline int sci_rxd_in(struct uart_port *port) |
@@ -521,6 +529,13 @@ static inline int sci_rxd_in(struct uart_port *port) | |||
521 | return ctrl_inw(SCSPTR3) & 0x0001 ? 1 : 0; /* SCIF */ | 529 | return ctrl_inw(SCSPTR3) & 0x0001 ? 1 : 0; /* SCIF */ |
522 | return 1; | 530 | return 1; |
523 | } | 531 | } |
532 | #elif defined(CONFIG_CPU_SUBTYPE_SH7722) | ||
533 | static inline int sci_rxd_in(struct uart_port *port) | ||
534 | { | ||
535 | if (port->mapbase == 0xffe00000) | ||
536 | return ctrl_inb(SCPDR0) & 0x0001 ? 1 : 0; /* SCIF0 */ | ||
537 | return 1; | ||
538 | } | ||
524 | #elif defined(CONFIG_CPU_SUBTYPE_ST40STB1) | 539 | #elif defined(CONFIG_CPU_SUBTYPE_ST40STB1) |
525 | static inline int sci_rxd_in(struct uart_port *port) | 540 | static inline int sci_rxd_in(struct uart_port *port) |
526 | { | 541 | { |
@@ -550,6 +565,7 @@ static inline int sci_rxd_in(struct uart_port *port) | |||
550 | return ctrl_inw(SCSPTR1) & 0x0001 ? 1 : 0; /* SCIF */ | 565 | return ctrl_inw(SCSPTR1) & 0x0001 ? 1 : 0; /* SCIF */ |
551 | if (port->mapbase == 0xff925000) | 566 | if (port->mapbase == 0xff925000) |
552 | return ctrl_inw(SCSPTR2) & 0x0001 ? 1 : 0; /* SCIF */ | 567 | return ctrl_inw(SCSPTR2) & 0x0001 ? 1 : 0; /* SCIF */ |
568 | return 1; | ||
553 | } | 569 | } |
554 | #elif defined(CONFIG_CPU_SUBTYPE_SH7780) | 570 | #elif defined(CONFIG_CPU_SUBTYPE_SH7780) |
555 | static inline int sci_rxd_in(struct uart_port *port) | 571 | static inline int sci_rxd_in(struct uart_port *port) |
@@ -558,6 +574,7 @@ static inline int sci_rxd_in(struct uart_port *port) | |||
558 | return ctrl_inw(SCSPTR0) & 0x0001 ? 1 : 0; /* SCIF */ | 574 | return ctrl_inw(SCSPTR0) & 0x0001 ? 1 : 0; /* SCIF */ |
559 | if (port->mapbase == 0xffe10000) | 575 | if (port->mapbase == 0xffe10000) |
560 | return ctrl_inw(SCSPTR1) & 0x0001 ? 1 : 0; /* SCIF */ | 576 | return ctrl_inw(SCSPTR1) & 0x0001 ? 1 : 0; /* SCIF */ |
577 | return 1; | ||
561 | } | 578 | } |
562 | #elif defined(CONFIG_CPU_SUBTYPE_SH7206) | 579 | #elif defined(CONFIG_CPU_SUBTYPE_SH7206) |
563 | static inline int sci_rxd_in(struct uart_port *port) | 580 | static inline int sci_rxd_in(struct uart_port *port) |
@@ -570,6 +587,7 @@ static inline int sci_rxd_in(struct uart_port *port) | |||
570 | return ctrl_inw(SCSPTR2) & 0x0001 ? 1 : 0; /* SCIF */ | 587 | return ctrl_inw(SCSPTR2) & 0x0001 ? 1 : 0; /* SCIF */ |
571 | if (port->mapbase == 0xfffe9800) | 588 | if (port->mapbase == 0xfffe9800) |
572 | return ctrl_inw(SCSPTR3) & 0x0001 ? 1 : 0; /* SCIF */ | 589 | return ctrl_inw(SCSPTR3) & 0x0001 ? 1 : 0; /* SCIF */ |
590 | return 1; | ||
573 | } | 591 | } |
574 | #elif defined(CONFIG_CPU_SUBTYPE_SH7619) | 592 | #elif defined(CONFIG_CPU_SUBTYPE_SH7619) |
575 | static inline int sci_rxd_in(struct uart_port *port) | 593 | static inline int sci_rxd_in(struct uart_port *port) |
@@ -580,6 +598,7 @@ static inline int sci_rxd_in(struct uart_port *port) | |||
580 | return ctrl_inw(SCSPTR1) & 0x0001 ? 1 : 0; /* SCIF */ | 598 | return ctrl_inw(SCSPTR1) & 0x0001 ? 1 : 0; /* SCIF */ |
581 | if (port->mapbase == 0xf8420000) | 599 | if (port->mapbase == 0xf8420000) |
582 | return ctrl_inw(SCSPTR2) & 0x0001 ? 1 : 0; /* SCIF */ | 600 | return ctrl_inw(SCSPTR2) & 0x0001 ? 1 : 0; /* SCIF */ |
601 | return 1; | ||
583 | } | 602 | } |
584 | #endif | 603 | #endif |
585 | 604 | ||
diff --git a/include/asm-sh/atomic-irq.h b/include/asm-sh/atomic-irq.h new file mode 100644 index 000000000000..74f7943cff6f --- /dev/null +++ b/include/asm-sh/atomic-irq.h | |||
@@ -0,0 +1,71 @@ | |||
1 | #ifndef __ASM_SH_ATOMIC_IRQ_H | ||
2 | #define __ASM_SH_ATOMIC_IRQ_H | ||
3 | |||
4 | /* | ||
5 | * To get proper branch prediction for the main line, we must branch | ||
6 | * forward to code at the end of this object's .text section, then | ||
7 | * branch back to restart the operation. | ||
8 | */ | ||
9 | static inline void atomic_add(int i, atomic_t *v) | ||
10 | { | ||
11 | unsigned long flags; | ||
12 | |||
13 | local_irq_save(flags); | ||
14 | *(long *)v += i; | ||
15 | local_irq_restore(flags); | ||
16 | } | ||
17 | |||
18 | static inline void atomic_sub(int i, atomic_t *v) | ||
19 | { | ||
20 | unsigned long flags; | ||
21 | |||
22 | local_irq_save(flags); | ||
23 | *(long *)v -= i; | ||
24 | local_irq_restore(flags); | ||
25 | } | ||
26 | |||
27 | static inline int atomic_add_return(int i, atomic_t *v) | ||
28 | { | ||
29 | unsigned long temp, flags; | ||
30 | |||
31 | local_irq_save(flags); | ||
32 | temp = *(long *)v; | ||
33 | temp += i; | ||
34 | *(long *)v = temp; | ||
35 | local_irq_restore(flags); | ||
36 | |||
37 | return temp; | ||
38 | } | ||
39 | |||
40 | static inline int atomic_sub_return(int i, atomic_t *v) | ||
41 | { | ||
42 | unsigned long temp, flags; | ||
43 | |||
44 | local_irq_save(flags); | ||
45 | temp = *(long *)v; | ||
46 | temp -= i; | ||
47 | *(long *)v = temp; | ||
48 | local_irq_restore(flags); | ||
49 | |||
50 | return temp; | ||
51 | } | ||
52 | |||
53 | static inline void atomic_clear_mask(unsigned int mask, atomic_t *v) | ||
54 | { | ||
55 | unsigned long flags; | ||
56 | |||
57 | local_irq_save(flags); | ||
58 | *(long *)v &= ~mask; | ||
59 | local_irq_restore(flags); | ||
60 | } | ||
61 | |||
62 | static inline void atomic_set_mask(unsigned int mask, atomic_t *v) | ||
63 | { | ||
64 | unsigned long flags; | ||
65 | |||
66 | local_irq_save(flags); | ||
67 | *(long *)v |= mask; | ||
68 | local_irq_restore(flags); | ||
69 | } | ||
70 | |||
71 | #endif /* __ASM_SH_ATOMIC_IRQ_H */ | ||
diff --git a/include/asm-sh/atomic-llsc.h b/include/asm-sh/atomic-llsc.h new file mode 100644 index 000000000000..4b00b78e3f4f --- /dev/null +++ b/include/asm-sh/atomic-llsc.h | |||
@@ -0,0 +1,107 @@ | |||
1 | #ifndef __ASM_SH_ATOMIC_LLSC_H | ||
2 | #define __ASM_SH_ATOMIC_LLSC_H | ||
3 | |||
4 | /* | ||
5 | * To get proper branch prediction for the main line, we must branch | ||
6 | * forward to code at the end of this object's .text section, then | ||
7 | * branch back to restart the operation. | ||
8 | */ | ||
9 | static inline void atomic_add(int i, atomic_t *v) | ||
10 | { | ||
11 | unsigned long tmp; | ||
12 | |||
13 | __asm__ __volatile__ ( | ||
14 | "1: movli.l @%2, %0 ! atomic_add \n" | ||
15 | " add %1, %0 \n" | ||
16 | " movco.l %0, @%2 \n" | ||
17 | " bf 1b \n" | ||
18 | : "=&z" (tmp) | ||
19 | : "r" (i), "r" (&v->counter) | ||
20 | : "t"); | ||
21 | } | ||
22 | |||
23 | static inline void atomic_sub(int i, atomic_t *v) | ||
24 | { | ||
25 | unsigned long tmp; | ||
26 | |||
27 | __asm__ __volatile__ ( | ||
28 | "1: movli.l @%2, %0 ! atomic_sub \n" | ||
29 | " sub %1, %0 \n" | ||
30 | " movco.l %0, @%2 \n" | ||
31 | " bf 1b \n" | ||
32 | : "=&z" (tmp) | ||
33 | : "r" (i), "r" (&v->counter) | ||
34 | : "t"); | ||
35 | } | ||
36 | |||
37 | /* | ||
38 | * SH-4A note: | ||
39 | * | ||
40 | * We basically get atomic_xxx_return() for free compared with | ||
41 | * atomic_xxx(). movli.l/movco.l require r0 due to the instruction | ||
42 | * encoding, so the retval is automatically set without having to | ||
43 | * do any special work. | ||
44 | */ | ||
45 | static inline int atomic_add_return(int i, atomic_t *v) | ||
46 | { | ||
47 | unsigned long temp; | ||
48 | |||
49 | __asm__ __volatile__ ( | ||
50 | "1: movli.l @%2, %0 ! atomic_add_return \n" | ||
51 | " add %1, %0 \n" | ||
52 | " movco.l %0, @%2 \n" | ||
53 | " bf 1b \n" | ||
54 | " synco \n" | ||
55 | : "=&z" (temp) | ||
56 | : "r" (i), "r" (&v->counter) | ||
57 | : "t"); | ||
58 | |||
59 | return temp; | ||
60 | } | ||
61 | |||
62 | static inline int atomic_sub_return(int i, atomic_t *v) | ||
63 | { | ||
64 | unsigned long temp; | ||
65 | |||
66 | __asm__ __volatile__ ( | ||
67 | "1: movli.l @%2, %0 ! atomic_sub_return \n" | ||
68 | " sub %1, %0 \n" | ||
69 | " movco.l %0, @%2 \n" | ||
70 | " bf 1b \n" | ||
71 | " synco \n" | ||
72 | : "=&z" (temp) | ||
73 | : "r" (i), "r" (&v->counter) | ||
74 | : "t"); | ||
75 | |||
76 | return temp; | ||
77 | } | ||
78 | |||
79 | static inline void atomic_clear_mask(unsigned int mask, atomic_t *v) | ||
80 | { | ||
81 | unsigned long tmp; | ||
82 | |||
83 | __asm__ __volatile__ ( | ||
84 | "1: movli.l @%2, %0 ! atomic_clear_mask \n" | ||
85 | " and %1, %0 \n" | ||
86 | " movco.l %0, @%2 \n" | ||
87 | " bf 1b \n" | ||
88 | : "=&z" (tmp) | ||
89 | : "r" (~mask), "r" (&v->counter) | ||
90 | : "t"); | ||
91 | } | ||
92 | |||
93 | static inline void atomic_set_mask(unsigned int mask, atomic_t *v) | ||
94 | { | ||
95 | unsigned long tmp; | ||
96 | |||
97 | __asm__ __volatile__ ( | ||
98 | "1: movli.l @%2, %0 ! atomic_set_mask \n" | ||
99 | " or %1, %0 \n" | ||
100 | " movco.l %0, @%2 \n" | ||
101 | " bf 1b \n" | ||
102 | : "=&z" (tmp) | ||
103 | : "r" (mask), "r" (&v->counter) | ||
104 | : "t"); | ||
105 | } | ||
106 | |||
107 | #endif /* __ASM_SH_ATOMIC_LLSC_H */ | ||
diff --git a/include/asm-sh/atomic.h b/include/asm-sh/atomic.h index 28305c3cbddf..e12570b9339d 100644 --- a/include/asm-sh/atomic.h +++ b/include/asm-sh/atomic.h | |||
@@ -17,119 +17,14 @@ typedef struct { volatile int counter; } atomic_t; | |||
17 | #include <linux/compiler.h> | 17 | #include <linux/compiler.h> |
18 | #include <asm/system.h> | 18 | #include <asm/system.h> |
19 | 19 | ||
20 | /* | ||
21 | * To get proper branch prediction for the main line, we must branch | ||
22 | * forward to code at the end of this object's .text section, then | ||
23 | * branch back to restart the operation. | ||
24 | */ | ||
25 | static inline void atomic_add(int i, atomic_t *v) | ||
26 | { | ||
27 | #ifdef CONFIG_CPU_SH4A | 20 | #ifdef CONFIG_CPU_SH4A |
28 | unsigned long tmp; | 21 | #include <asm/atomic-llsc.h> |
29 | |||
30 | __asm__ __volatile__ ( | ||
31 | "1: movli.l @%2, %0 ! atomic_add \n" | ||
32 | " add %1, %0 \n" | ||
33 | " movco.l %0, @%2 \n" | ||
34 | " bf 1b \n" | ||
35 | : "=&z" (tmp) | ||
36 | : "r" (i), "r" (&v->counter) | ||
37 | : "t"); | ||
38 | #else | 22 | #else |
39 | unsigned long flags; | 23 | #include <asm/atomic-irq.h> |
40 | |||
41 | local_irq_save(flags); | ||
42 | *(long *)v += i; | ||
43 | local_irq_restore(flags); | ||
44 | #endif | ||
45 | } | ||
46 | |||
47 | static inline void atomic_sub(int i, atomic_t *v) | ||
48 | { | ||
49 | #ifdef CONFIG_CPU_SH4A | ||
50 | unsigned long tmp; | ||
51 | |||
52 | __asm__ __volatile__ ( | ||
53 | "1: movli.l @%2, %0 ! atomic_sub \n" | ||
54 | " sub %1, %0 \n" | ||
55 | " movco.l %0, @%2 \n" | ||
56 | " bf 1b \n" | ||
57 | : "=&z" (tmp) | ||
58 | : "r" (i), "r" (&v->counter) | ||
59 | : "t"); | ||
60 | #else | ||
61 | unsigned long flags; | ||
62 | |||
63 | local_irq_save(flags); | ||
64 | *(long *)v -= i; | ||
65 | local_irq_restore(flags); | ||
66 | #endif | 24 | #endif |
67 | } | ||
68 | |||
69 | /* | ||
70 | * SH-4A note: | ||
71 | * | ||
72 | * We basically get atomic_xxx_return() for free compared with | ||
73 | * atomic_xxx(). movli.l/movco.l require r0 due to the instruction | ||
74 | * encoding, so the retval is automatically set without having to | ||
75 | * do any special work. | ||
76 | */ | ||
77 | static inline int atomic_add_return(int i, atomic_t *v) | ||
78 | { | ||
79 | unsigned long temp; | ||
80 | |||
81 | #ifdef CONFIG_CPU_SH4A | ||
82 | __asm__ __volatile__ ( | ||
83 | "1: movli.l @%2, %0 ! atomic_add_return \n" | ||
84 | " add %1, %0 \n" | ||
85 | " movco.l %0, @%2 \n" | ||
86 | " bf 1b \n" | ||
87 | " synco \n" | ||
88 | : "=&z" (temp) | ||
89 | : "r" (i), "r" (&v->counter) | ||
90 | : "t"); | ||
91 | #else | ||
92 | unsigned long flags; | ||
93 | |||
94 | local_irq_save(flags); | ||
95 | temp = *(long *)v; | ||
96 | temp += i; | ||
97 | *(long *)v = temp; | ||
98 | local_irq_restore(flags); | ||
99 | #endif | ||
100 | |||
101 | return temp; | ||
102 | } | ||
103 | 25 | ||
104 | #define atomic_add_negative(a, v) (atomic_add_return((a), (v)) < 0) | 26 | #define atomic_add_negative(a, v) (atomic_add_return((a), (v)) < 0) |
105 | 27 | ||
106 | static inline int atomic_sub_return(int i, atomic_t *v) | ||
107 | { | ||
108 | unsigned long temp; | ||
109 | |||
110 | #ifdef CONFIG_CPU_SH4A | ||
111 | __asm__ __volatile__ ( | ||
112 | "1: movli.l @%2, %0 ! atomic_sub_return \n" | ||
113 | " sub %1, %0 \n" | ||
114 | " movco.l %0, @%2 \n" | ||
115 | " bf 1b \n" | ||
116 | " synco \n" | ||
117 | : "=&z" (temp) | ||
118 | : "r" (i), "r" (&v->counter) | ||
119 | : "t"); | ||
120 | #else | ||
121 | unsigned long flags; | ||
122 | |||
123 | local_irq_save(flags); | ||
124 | temp = *(long *)v; | ||
125 | temp -= i; | ||
126 | *(long *)v = temp; | ||
127 | local_irq_restore(flags); | ||
128 | #endif | ||
129 | |||
130 | return temp; | ||
131 | } | ||
132 | |||
133 | #define atomic_dec_return(v) atomic_sub_return(1,(v)) | 28 | #define atomic_dec_return(v) atomic_sub_return(1,(v)) |
134 | #define atomic_inc_return(v) atomic_add_return(1,(v)) | 29 | #define atomic_inc_return(v) atomic_add_return(1,(v)) |
135 | 30 | ||
@@ -180,50 +75,6 @@ static inline int atomic_add_unless(atomic_t *v, int a, int u) | |||
180 | } | 75 | } |
181 | #define atomic_inc_not_zero(v) atomic_add_unless((v), 1, 0) | 76 | #define atomic_inc_not_zero(v) atomic_add_unless((v), 1, 0) |
182 | 77 | ||
183 | static inline void atomic_clear_mask(unsigned int mask, atomic_t *v) | ||
184 | { | ||
185 | #ifdef CONFIG_CPU_SH4A | ||
186 | unsigned long tmp; | ||
187 | |||
188 | __asm__ __volatile__ ( | ||
189 | "1: movli.l @%2, %0 ! atomic_clear_mask \n" | ||
190 | " and %1, %0 \n" | ||
191 | " movco.l %0, @%2 \n" | ||
192 | " bf 1b \n" | ||
193 | : "=&z" (tmp) | ||
194 | : "r" (~mask), "r" (&v->counter) | ||
195 | : "t"); | ||
196 | #else | ||
197 | unsigned long flags; | ||
198 | |||
199 | local_irq_save(flags); | ||
200 | *(long *)v &= ~mask; | ||
201 | local_irq_restore(flags); | ||
202 | #endif | ||
203 | } | ||
204 | |||
205 | static inline void atomic_set_mask(unsigned int mask, atomic_t *v) | ||
206 | { | ||
207 | #ifdef CONFIG_CPU_SH4A | ||
208 | unsigned long tmp; | ||
209 | |||
210 | __asm__ __volatile__ ( | ||
211 | "1: movli.l @%2, %0 ! atomic_set_mask \n" | ||
212 | " or %1, %0 \n" | ||
213 | " movco.l %0, @%2 \n" | ||
214 | " bf 1b \n" | ||
215 | : "=&z" (tmp) | ||
216 | : "r" (mask), "r" (&v->counter) | ||
217 | : "t"); | ||
218 | #else | ||
219 | unsigned long flags; | ||
220 | |||
221 | local_irq_save(flags); | ||
222 | *(long *)v |= mask; | ||
223 | local_irq_restore(flags); | ||
224 | #endif | ||
225 | } | ||
226 | |||
227 | /* Atomic operations are already serializing on SH */ | 78 | /* Atomic operations are already serializing on SH */ |
228 | #define smp_mb__before_atomic_dec() barrier() | 79 | #define smp_mb__before_atomic_dec() barrier() |
229 | #define smp_mb__after_atomic_dec() barrier() | 80 | #define smp_mb__after_atomic_dec() barrier() |
diff --git a/include/asm-sh/bug.h b/include/asm-sh/bug.h index 1b4fc52a59e8..2f89dd06d0cd 100644 --- a/include/asm-sh/bug.h +++ b/include/asm-sh/bug.h | |||
@@ -1,19 +1,54 @@ | |||
1 | #ifndef __ASM_SH_BUG_H | 1 | #ifndef __ASM_SH_BUG_H |
2 | #define __ASM_SH_BUG_H | 2 | #define __ASM_SH_BUG_H |
3 | 3 | ||
4 | |||
5 | #ifdef CONFIG_BUG | 4 | #ifdef CONFIG_BUG |
6 | /* | 5 | |
7 | * Tell the user there is some problem. | 6 | struct bug_frame { |
8 | */ | 7 | unsigned short opcode; |
9 | #define BUG() do { \ | 8 | unsigned short line; |
10 | printk("kernel BUG at %s:%d!\n", __FILE__, __LINE__); \ | 9 | const char *file; |
11 | *(volatile int *)0 = 0; \ | 10 | const char *func; |
11 | }; | ||
12 | |||
13 | struct pt_regs; | ||
14 | |||
15 | extern void handle_BUG(struct pt_regs *); | ||
16 | |||
17 | #define TRAPA_BUG_OPCODE 0xc33e /* trapa #0x3e */ | ||
18 | |||
19 | #ifdef CONFIG_DEBUG_BUGVERBOSE | ||
20 | |||
21 | #define BUG() \ | ||
22 | do { \ | ||
23 | __asm__ __volatile__ ( \ | ||
24 | ".align 2\n\t" \ | ||
25 | ".short %O0\n\t" \ | ||
26 | ".short %O1\n\t" \ | ||
27 | ".long %O2\n\t" \ | ||
28 | ".long %O3\n\t" \ | ||
29 | : \ | ||
30 | : "n" (TRAPA_BUG_OPCODE), \ | ||
31 | "i" (__LINE__), "X" (__FILE__), \ | ||
32 | "X" (__FUNCTION__)); \ | ||
33 | } while (0) | ||
34 | |||
35 | #else | ||
36 | |||
37 | #define BUG() \ | ||
38 | do { \ | ||
39 | __asm__ __volatile__ ( \ | ||
40 | ".align 2\n\t" \ | ||
41 | ".short %O0\n\t" \ | ||
42 | : \ | ||
43 | : "n" (TRAPA_BUG_OPCODE)); \ | ||
12 | } while (0) | 44 | } while (0) |
13 | 45 | ||
46 | #endif /* CONFIG_DEBUG_BUGVERBOSE */ | ||
47 | |||
14 | #define HAVE_ARCH_BUG | 48 | #define HAVE_ARCH_BUG |
15 | #endif | 49 | |
50 | #endif /* CONFIG_BUG */ | ||
16 | 51 | ||
17 | #include <asm-generic/bug.h> | 52 | #include <asm-generic/bug.h> |
18 | 53 | ||
19 | #endif | 54 | #endif /* __ASM_SH_BUG_H */ |
diff --git a/include/asm-sh/bugs.h b/include/asm-sh/bugs.h index 795047da5e17..a294997a8412 100644 --- a/include/asm-sh/bugs.h +++ b/include/asm-sh/bugs.h | |||
@@ -16,9 +16,8 @@ | |||
16 | 16 | ||
17 | static void __init check_bugs(void) | 17 | static void __init check_bugs(void) |
18 | { | 18 | { |
19 | extern char *get_cpu_subtype(void); | ||
20 | extern unsigned long loops_per_jiffy; | 19 | extern unsigned long loops_per_jiffy; |
21 | char *p= &init_utsname()->machine[2]; /* "sh" */ | 20 | char *p = &init_utsname()->machine[2]; /* "sh" */ |
22 | 21 | ||
23 | cpu_data->loops_per_jiffy = loops_per_jiffy; | 22 | cpu_data->loops_per_jiffy = loops_per_jiffy; |
24 | 23 | ||
@@ -40,6 +39,15 @@ static void __init check_bugs(void) | |||
40 | *p++ = '4'; | 39 | *p++ = '4'; |
41 | *p++ = 'a'; | 40 | *p++ = 'a'; |
42 | break; | 41 | break; |
42 | case CPU_SH73180 ... CPU_SH7722: | ||
43 | *p++ = '4'; | ||
44 | *p++ = 'a'; | ||
45 | *p++ = 'l'; | ||
46 | *p++ = '-'; | ||
47 | *p++ = 'd'; | ||
48 | *p++ = 's'; | ||
49 | *p++ = 'p'; | ||
50 | break; | ||
43 | default: | 51 | default: |
44 | *p++ = '?'; | 52 | *p++ = '?'; |
45 | *p++ = '!'; | 53 | *p++ = '!'; |
diff --git a/include/asm-sh/checksum.h b/include/asm-sh/checksum.h index d44344c88e73..4bc8357e8892 100644 --- a/include/asm-sh/checksum.h +++ b/include/asm-sh/checksum.h | |||
@@ -34,25 +34,26 @@ asmlinkage __wsum csum_partial(const void *buff, int len, __wsum sum); | |||
34 | */ | 34 | */ |
35 | 35 | ||
36 | asmlinkage __wsum csum_partial_copy_generic(const void *src, void *dst, | 36 | asmlinkage __wsum csum_partial_copy_generic(const void *src, void *dst, |
37 | int len, __wsum sum, int *src_err_ptr, int *dst_err_ptr); | 37 | int len, __wsum sum, |
38 | int *src_err_ptr, int *dst_err_ptr); | ||
38 | 39 | ||
39 | /* | 40 | /* |
40 | * Note: when you get a NULL pointer exception here this means someone | 41 | * Note: when you get a NULL pointer exception here this means someone |
41 | * passed in an incorrect kernel address to one of these functions. | 42 | * passed in an incorrect kernel address to one of these functions. |
42 | * | 43 | * |
43 | * If you use these functions directly please don't forget the | 44 | * If you use these functions directly please don't forget the |
44 | * access_ok(). | 45 | * access_ok(). |
45 | */ | 46 | */ |
46 | static __inline__ | 47 | static inline |
47 | __wsum csum_partial_copy_nocheck(const void *src, void *dst, | 48 | __wsum csum_partial_copy_nocheck(const void *src, void *dst, |
48 | int len, __wsum sum) | 49 | int len, __wsum sum) |
49 | { | 50 | { |
50 | return csum_partial_copy_generic ( src, dst, len, sum, NULL, NULL); | 51 | return csum_partial_copy_generic(src, dst, len, sum, NULL, NULL); |
51 | } | 52 | } |
52 | 53 | ||
53 | static __inline__ | 54 | static inline |
54 | __wsum csum_partial_copy_from_user(const void __user *src, void *dst, | 55 | __wsum csum_partial_copy_from_user(const void __user *src, void *dst, |
55 | int len, __wsum sum, int *err_ptr) | 56 | int len, __wsum sum, int *err_ptr) |
56 | { | 57 | { |
57 | return csum_partial_copy_generic((__force const void *)src, dst, | 58 | return csum_partial_copy_generic((__force const void *)src, dst, |
58 | len, sum, err_ptr, NULL); | 59 | len, sum, err_ptr, NULL); |
@@ -62,7 +63,7 @@ __wsum csum_partial_copy_from_user(const void __user *src, void *dst, | |||
62 | * Fold a partial checksum | 63 | * Fold a partial checksum |
63 | */ | 64 | */ |
64 | 65 | ||
65 | static __inline__ __sum16 csum_fold(__wsum sum) | 66 | static inline __sum16 csum_fold(__wsum sum) |
66 | { | 67 | { |
67 | unsigned int __dummy; | 68 | unsigned int __dummy; |
68 | __asm__("swap.w %0, %1\n\t" | 69 | __asm__("swap.w %0, %1\n\t" |
@@ -85,7 +86,7 @@ static __inline__ __sum16 csum_fold(__wsum sum) | |||
85 | * i386 version by Jorge Cwik <jorge@laser.satlink.net>, adapted | 86 | * i386 version by Jorge Cwik <jorge@laser.satlink.net>, adapted |
86 | * for linux by * Arnt Gulbrandsen. | 87 | * for linux by * Arnt Gulbrandsen. |
87 | */ | 88 | */ |
88 | static __inline__ __sum16 ip_fast_csum(const void *iph, unsigned int ihl) | 89 | static inline __sum16 ip_fast_csum(const void *iph, unsigned int ihl) |
89 | { | 90 | { |
90 | unsigned int sum, __dummy0, __dummy1; | 91 | unsigned int sum, __dummy0, __dummy1; |
91 | 92 | ||
@@ -113,10 +114,10 @@ static __inline__ __sum16 ip_fast_csum(const void *iph, unsigned int ihl) | |||
113 | return csum_fold(sum); | 114 | return csum_fold(sum); |
114 | } | 115 | } |
115 | 116 | ||
116 | static __inline__ __wsum csum_tcpudp_nofold(__be32 saddr, __be32 daddr, | 117 | static inline __wsum csum_tcpudp_nofold(__be32 saddr, __be32 daddr, |
117 | unsigned short len, | 118 | unsigned short len, |
118 | unsigned short proto, | 119 | unsigned short proto, |
119 | __wsum sum) | 120 | __wsum sum) |
120 | { | 121 | { |
121 | #ifdef __LITTLE_ENDIAN__ | 122 | #ifdef __LITTLE_ENDIAN__ |
122 | unsigned long len_proto = (proto + len) << 8; | 123 | unsigned long len_proto = (proto + len) << 8; |
@@ -132,6 +133,7 @@ static __inline__ __wsum csum_tcpudp_nofold(__be32 saddr, __be32 daddr, | |||
132 | : "=r" (sum), "=r" (len_proto) | 133 | : "=r" (sum), "=r" (len_proto) |
133 | : "r" (daddr), "r" (saddr), "1" (len_proto), "0" (sum) | 134 | : "r" (daddr), "r" (saddr), "1" (len_proto), "0" (sum) |
134 | : "t"); | 135 | : "t"); |
136 | |||
135 | return sum; | 137 | return sum; |
136 | } | 138 | } |
137 | 139 | ||
@@ -139,30 +141,28 @@ static __inline__ __wsum csum_tcpudp_nofold(__be32 saddr, __be32 daddr, | |||
139 | * computes the checksum of the TCP/UDP pseudo-header | 141 | * computes the checksum of the TCP/UDP pseudo-header |
140 | * returns a 16-bit checksum, already complemented | 142 | * returns a 16-bit checksum, already complemented |
141 | */ | 143 | */ |
142 | static __inline__ __sum16 csum_tcpudp_magic(__be32 saddr, __be32 daddr, | 144 | static inline __sum16 csum_tcpudp_magic(__be32 saddr, __be32 daddr, |
143 | unsigned short len, | 145 | unsigned short len, |
144 | unsigned short proto, | 146 | unsigned short proto, |
145 | __wsum sum) | 147 | __wsum sum) |
146 | { | 148 | { |
147 | return csum_fold(csum_tcpudp_nofold(saddr,daddr,len,proto,sum)); | 149 | return csum_fold(csum_tcpudp_nofold(saddr, daddr, len, proto, sum)); |
148 | } | 150 | } |
149 | 151 | ||
150 | /* | 152 | /* |
151 | * this routine is used for miscellaneous IP-like checksums, mainly | 153 | * this routine is used for miscellaneous IP-like checksums, mainly |
152 | * in icmp.c | 154 | * in icmp.c |
153 | */ | 155 | */ |
154 | 156 | static inline __sum16 ip_compute_csum(const void *buff, int len) | |
155 | static __inline__ __sum16 ip_compute_csum(const void *buff, int len) | ||
156 | { | 157 | { |
157 | return csum_fold (csum_partial(buff, len, 0)); | 158 | return csum_fold(csum_partial(buff, len, 0)); |
158 | } | 159 | } |
159 | 160 | ||
160 | #define _HAVE_ARCH_IPV6_CSUM | 161 | #define _HAVE_ARCH_IPV6_CSUM |
161 | #ifdef CONFIG_IPV6 | 162 | static inline __sum16 csum_ipv6_magic(const struct in6_addr *saddr, |
162 | static __inline__ __sum16 csum_ipv6_magic(const struct in6_addr *saddr, | 163 | const struct in6_addr *daddr, |
163 | const struct in6_addr *daddr, | 164 | __u32 len, unsigned short proto, |
164 | __u32 len, unsigned short proto, | 165 | __wsum sum) |
165 | __wsum sum) | ||
166 | { | 166 | { |
167 | unsigned int __dummy; | 167 | unsigned int __dummy; |
168 | __asm__("clrt\n\t" | 168 | __asm__("clrt\n\t" |
@@ -187,22 +187,21 @@ static __inline__ __sum16 csum_ipv6_magic(const struct in6_addr *saddr, | |||
187 | "movt %1\n\t" | 187 | "movt %1\n\t" |
188 | "add %1, %0\n" | 188 | "add %1, %0\n" |
189 | : "=r" (sum), "=&r" (__dummy) | 189 | : "=r" (sum), "=&r" (__dummy) |
190 | : "r" (saddr), "r" (daddr), | 190 | : "r" (saddr), "r" (daddr), |
191 | "r" (htonl(len)), "r" (htonl(proto)), "0" (sum) | 191 | "r" (htonl(len)), "r" (htonl(proto)), "0" (sum) |
192 | : "t"); | 192 | : "t"); |
193 | 193 | ||
194 | return csum_fold(sum); | 194 | return csum_fold(sum); |
195 | } | 195 | } |
196 | #endif | ||
197 | 196 | ||
198 | /* | 197 | /* |
199 | * Copy and checksum to user | 198 | * Copy and checksum to user |
200 | */ | 199 | */ |
201 | #define HAVE_CSUM_COPY_USER | 200 | #define HAVE_CSUM_COPY_USER |
202 | static __inline__ __wsum csum_and_copy_to_user (const void *src, | 201 | static inline __wsum csum_and_copy_to_user(const void *src, |
203 | void __user *dst, | 202 | void __user *dst, |
204 | int len, __wsum sum, | 203 | int len, __wsum sum, |
205 | int *err_ptr) | 204 | int *err_ptr) |
206 | { | 205 | { |
207 | if (access_ok(VERIFY_WRITE, dst, len)) | 206 | if (access_ok(VERIFY_WRITE, dst, len)) |
208 | return csum_partial_copy_generic((__force const void *)src, | 207 | return csum_partial_copy_generic((__force const void *)src, |
diff --git a/include/asm-sh/cpu-sh4/cache.h b/include/asm-sh/cpu-sh4/cache.h index 6e9c7e6ee8e4..f92b20a0983d 100644 --- a/include/asm-sh/cpu-sh4/cache.h +++ b/include/asm-sh/cpu-sh4/cache.h | |||
@@ -22,7 +22,7 @@ | |||
22 | #define CCR_CACHE_ICE 0x0100 /* Instruction Cache Enable */ | 22 | #define CCR_CACHE_ICE 0x0100 /* Instruction Cache Enable */ |
23 | #define CCR_CACHE_ICI 0x0800 /* IC Invalidate */ | 23 | #define CCR_CACHE_ICI 0x0800 /* IC Invalidate */ |
24 | #define CCR_CACHE_IIX 0x8000 /* IC Index Enable */ | 24 | #define CCR_CACHE_IIX 0x8000 /* IC Index Enable */ |
25 | #ifndef CONFIG_CPU_SUBTYPE_SH7780 | 25 | #ifndef CONFIG_CPU_SH4A |
26 | #define CCR_CACHE_EMODE 0x80000000 /* EMODE Enable */ | 26 | #define CCR_CACHE_EMODE 0x80000000 /* EMODE Enable */ |
27 | #endif | 27 | #endif |
28 | 28 | ||
diff --git a/include/asm-sh/cpu-sh4/freq.h b/include/asm-sh/cpu-sh4/freq.h index ef2b9b1ae41f..602d061ca2dc 100644 --- a/include/asm-sh/cpu-sh4/freq.h +++ b/include/asm-sh/cpu-sh4/freq.h | |||
@@ -10,7 +10,7 @@ | |||
10 | #ifndef __ASM_CPU_SH4_FREQ_H | 10 | #ifndef __ASM_CPU_SH4_FREQ_H |
11 | #define __ASM_CPU_SH4_FREQ_H | 11 | #define __ASM_CPU_SH4_FREQ_H |
12 | 12 | ||
13 | #if defined(CONFIG_CPU_SUBTYPE_SH73180) | 13 | #if defined(CONFIG_CPU_SUBTYPE_SH73180) || defined(CONFIG_CPU_SUBTYPE_SH7722) |
14 | #define FRQCR 0xa4150000 | 14 | #define FRQCR 0xa4150000 |
15 | #elif defined(CONFIG_CPU_SUBTYPE_SH7780) | 15 | #elif defined(CONFIG_CPU_SUBTYPE_SH7780) |
16 | #define FRQCR 0xffc80000 | 16 | #define FRQCR 0xffc80000 |
diff --git a/include/asm-sh/dma-mapping.h b/include/asm-sh/dma-mapping.h index 37ab0c131a4d..8d0867b98e05 100644 --- a/include/asm-sh/dma-mapping.h +++ b/include/asm-sh/dma-mapping.h | |||
@@ -67,7 +67,7 @@ static inline dma_addr_t dma_map_single(struct device *dev, | |||
67 | if (dev->bus == &pci_bus_type) | 67 | if (dev->bus == &pci_bus_type) |
68 | return virt_to_bus(ptr); | 68 | return virt_to_bus(ptr); |
69 | #endif | 69 | #endif |
70 | dma_cache_sync(ptr, size, dir); | 70 | dma_cache_sync(dev, ptr, size, dir); |
71 | 71 | ||
72 | return virt_to_bus(ptr); | 72 | return virt_to_bus(ptr); |
73 | } | 73 | } |
@@ -81,7 +81,7 @@ static inline int dma_map_sg(struct device *dev, struct scatterlist *sg, | |||
81 | 81 | ||
82 | for (i = 0; i < nents; i++) { | 82 | for (i = 0; i < nents; i++) { |
83 | #if !defined(CONFIG_PCI) || defined(CONFIG_SH_PCIDMA_NONCOHERENT) | 83 | #if !defined(CONFIG_PCI) || defined(CONFIG_SH_PCIDMA_NONCOHERENT) |
84 | dma_cache_sync(page_address(sg[i].page) + sg[i].offset, | 84 | dma_cache_sync(dev, page_address(sg[i].page) + sg[i].offset, |
85 | sg[i].length, dir); | 85 | sg[i].length, dir); |
86 | #endif | 86 | #endif |
87 | sg[i].dma_address = page_to_phys(sg[i].page) + sg[i].offset; | 87 | sg[i].dma_address = page_to_phys(sg[i].page) + sg[i].offset; |
@@ -112,7 +112,7 @@ static inline void dma_sync_single(struct device *dev, dma_addr_t dma_handle, | |||
112 | if (dev->bus == &pci_bus_type) | 112 | if (dev->bus == &pci_bus_type) |
113 | return; | 113 | return; |
114 | #endif | 114 | #endif |
115 | dma_cache_sync(bus_to_virt(dma_handle), size, dir); | 115 | dma_cache_sync(dev, bus_to_virt(dma_handle), size, dir); |
116 | } | 116 | } |
117 | 117 | ||
118 | static inline void dma_sync_single_range(struct device *dev, | 118 | static inline void dma_sync_single_range(struct device *dev, |
@@ -124,7 +124,7 @@ static inline void dma_sync_single_range(struct device *dev, | |||
124 | if (dev->bus == &pci_bus_type) | 124 | if (dev->bus == &pci_bus_type) |
125 | return; | 125 | return; |
126 | #endif | 126 | #endif |
127 | dma_cache_sync(bus_to_virt(dma_handle) + offset, size, dir); | 127 | dma_cache_sync(dev, bus_to_virt(dma_handle) + offset, size, dir); |
128 | } | 128 | } |
129 | 129 | ||
130 | static inline void dma_sync_sg(struct device *dev, struct scatterlist *sg, | 130 | static inline void dma_sync_sg(struct device *dev, struct scatterlist *sg, |
@@ -134,7 +134,7 @@ static inline void dma_sync_sg(struct device *dev, struct scatterlist *sg, | |||
134 | 134 | ||
135 | for (i = 0; i < nelems; i++) { | 135 | for (i = 0; i < nelems; i++) { |
136 | #if !defined(CONFIG_PCI) || defined(CONFIG_SH_PCIDMA_NONCOHERENT) | 136 | #if !defined(CONFIG_PCI) || defined(CONFIG_SH_PCIDMA_NONCOHERENT) |
137 | dma_cache_sync(page_address(sg[i].page) + sg[i].offset, | 137 | dma_cache_sync(dev, page_address(sg[i].page) + sg[i].offset, |
138 | sg[i].length, dir); | 138 | sg[i].length, dir); |
139 | #endif | 139 | #endif |
140 | sg[i].dma_address = page_to_phys(sg[i].page) + sg[i].offset; | 140 | sg[i].dma_address = page_to_phys(sg[i].page) + sg[i].offset; |
diff --git a/include/asm-sh/irq.h b/include/asm-sh/irq.h index fd576088e47e..bff965ef4b95 100644 --- a/include/asm-sh/irq.h +++ b/include/asm-sh/irq.h | |||
@@ -37,7 +37,8 @@ | |||
37 | # define ONCHIP_NR_IRQS 144 | 37 | # define ONCHIP_NR_IRQS 144 |
38 | #elif defined(CONFIG_CPU_SUBTYPE_SH7300) || \ | 38 | #elif defined(CONFIG_CPU_SUBTYPE_SH7300) || \ |
39 | defined(CONFIG_CPU_SUBTYPE_SH73180) || \ | 39 | defined(CONFIG_CPU_SUBTYPE_SH73180) || \ |
40 | defined(CONFIG_CPU_SUBTYPE_SH7343) | 40 | defined(CONFIG_CPU_SUBTYPE_SH7343) || \ |
41 | defined(CONFIG_CPU_SUBTYPE_SH7722) | ||
41 | # define ONCHIP_NR_IRQS 109 | 42 | # define ONCHIP_NR_IRQS 109 |
42 | #elif defined(CONFIG_CPU_SUBTYPE_SH7780) | 43 | #elif defined(CONFIG_CPU_SUBTYPE_SH7780) |
43 | # define ONCHIP_NR_IRQS 111 | 44 | # define ONCHIP_NR_IRQS 111 |
@@ -79,6 +80,8 @@ | |||
79 | # define OFFCHIP_NR_IRQS 16 | 80 | # define OFFCHIP_NR_IRQS 16 |
80 | #elif defined(CONFIG_SH_7343_SOLUTION_ENGINE) | 81 | #elif defined(CONFIG_SH_7343_SOLUTION_ENGINE) |
81 | # define OFFCHIP_NR_IRQS 12 | 82 | # define OFFCHIP_NR_IRQS 12 |
83 | #elif defined(CONFIG_SH_7722_SOLUTION_ENGINE) | ||
84 | # define OFFCHIP_NR_IRQS 14 | ||
82 | #elif defined(CONFIG_SH_UNKNOWN) | 85 | #elif defined(CONFIG_SH_UNKNOWN) |
83 | # define OFFCHIP_NR_IRQS 16 /* Must also be last */ | 86 | # define OFFCHIP_NR_IRQS 16 /* Must also be last */ |
84 | #else | 87 | #else |
diff --git a/include/asm-sh/pgtable.h b/include/asm-sh/pgtable.h index c84901dbd8e5..036ca2843866 100644 --- a/include/asm-sh/pgtable.h +++ b/include/asm-sh/pgtable.h | |||
@@ -508,16 +508,50 @@ struct vm_area_struct; | |||
508 | extern void update_mmu_cache(struct vm_area_struct * vma, | 508 | extern void update_mmu_cache(struct vm_area_struct * vma, |
509 | unsigned long address, pte_t pte); | 509 | unsigned long address, pte_t pte); |
510 | 510 | ||
511 | /* Encode and de-code a swap entry */ | ||
512 | /* | 511 | /* |
512 | * Encode and de-code a swap entry | ||
513 | * | ||
514 | * Constraints: | ||
515 | * _PAGE_FILE at bit 0 | ||
516 | * _PAGE_PRESENT at bit 8 | ||
517 | * _PAGE_PROTNONE at bit 9 | ||
518 | * | ||
519 | * For the normal case, we encode the swap type into bits 0:7 and the | ||
520 | * swap offset into bits 10:30. For the 64-bit PTE case, we keep the | ||
521 | * preserved bits in the low 32-bits and use the upper 32 as the swap | ||
522 | * offset (along with a 5-bit type), following the same approach as x86 | ||
523 | * PAE. This keeps the logic quite simple, and allows for a full 32 | ||
524 | * PTE_FILE_MAX_BITS, as opposed to the 29-bits we're constrained with | ||
525 | * in the pte_low case. | ||
526 | * | ||
527 | * As is evident by the Alpha code, if we ever get a 64-bit unsigned | ||
528 | * long (swp_entry_t) to match up with the 64-bit PTEs, this all becomes | ||
529 | * much cleaner.. | ||
530 | * | ||
513 | * NOTE: We should set ZEROs at the position of _PAGE_PRESENT | 531 | * NOTE: We should set ZEROs at the position of _PAGE_PRESENT |
514 | * and _PAGE_PROTNONE bits | 532 | * and _PAGE_PROTNONE bits |
515 | */ | 533 | */ |
516 | #define __swp_type(x) ((x).val & 0xff) | 534 | #ifdef CONFIG_X2TLB |
517 | #define __swp_offset(x) ((x).val >> 10) | 535 | #define __swp_type(x) ((x).val & 0x1f) |
518 | #define __swp_entry(type, offset) ((swp_entry_t) { (type) | ((offset) << 10) }) | 536 | #define __swp_offset(x) ((x).val >> 5) |
519 | #define __pte_to_swp_entry(pte) ((swp_entry_t) { pte_val(pte) >> 1 }) | 537 | #define __swp_entry(type, offset) ((swp_entry_t){ (type) | (offset) << 5}) |
520 | #define __swp_entry_to_pte(x) ((pte_t) { (x).val << 1 }) | 538 | #define __pte_to_swp_entry(pte) ((swp_entry_t){ (pte).pte_high }) |
539 | #define __swp_entry_to_pte(x) ((pte_t){ 0, (x).val }) | ||
540 | |||
541 | /* | ||
542 | * Encode and decode a nonlinear file mapping entry | ||
543 | */ | ||
544 | #define pte_to_pgoff(pte) ((pte).pte_high) | ||
545 | #define pgoff_to_pte(off) ((pte_t) { _PAGE_FILE, (off) }) | ||
546 | |||
547 | #define PTE_FILE_MAX_BITS 32 | ||
548 | #else | ||
549 | #define __swp_type(x) ((x).val & 0xff) | ||
550 | #define __swp_offset(x) ((x).val >> 10) | ||
551 | #define __swp_entry(type, offset) ((swp_entry_t){(type) | (offset) <<10}) | ||
552 | |||
553 | #define __pte_to_swp_entry(pte) ((swp_entry_t) { pte_val(pte) >> 1 }) | ||
554 | #define __swp_entry_to_pte(x) ((pte_t) { (x).val << 1 }) | ||
521 | 555 | ||
522 | /* | 556 | /* |
523 | * Encode and decode a nonlinear file mapping entry | 557 | * Encode and decode a nonlinear file mapping entry |
@@ -525,6 +559,7 @@ extern void update_mmu_cache(struct vm_area_struct * vma, | |||
525 | #define PTE_FILE_MAX_BITS 29 | 559 | #define PTE_FILE_MAX_BITS 29 |
526 | #define pte_to_pgoff(pte) (pte_val(pte) >> 1) | 560 | #define pte_to_pgoff(pte) (pte_val(pte) >> 1) |
527 | #define pgoff_to_pte(off) ((pte_t) { ((off) << 1) | _PAGE_FILE }) | 561 | #define pgoff_to_pte(off) ((pte_t) { ((off) << 1) | _PAGE_FILE }) |
562 | #endif | ||
528 | 563 | ||
529 | typedef pte_t *pte_addr_t; | 564 | typedef pte_t *pte_addr_t; |
530 | 565 | ||
diff --git a/include/asm-sh/processor.h b/include/asm-sh/processor.h index 6f1dd7ca1b1d..e29f2abb92de 100644 --- a/include/asm-sh/processor.h +++ b/include/asm-sh/processor.h | |||
@@ -27,6 +27,8 @@ | |||
27 | #define CCN_CVR 0xff000040 | 27 | #define CCN_CVR 0xff000040 |
28 | #define CCN_PRR 0xff000044 | 28 | #define CCN_PRR 0xff000044 |
29 | 29 | ||
30 | const char *get_cpu_subtype(void); | ||
31 | |||
30 | /* | 32 | /* |
31 | * CPU type and hardware bug flags. Kept separately for each CPU. | 33 | * CPU type and hardware bug flags. Kept separately for each CPU. |
32 | * | 34 | * |
@@ -52,8 +54,10 @@ enum cpu_type { | |||
52 | CPU_SH7760, CPU_ST40RA, CPU_ST40GX1, CPU_SH4_202, CPU_SH4_501, | 54 | CPU_SH7760, CPU_ST40RA, CPU_ST40GX1, CPU_SH4_202, CPU_SH4_501, |
53 | 55 | ||
54 | /* SH-4A types */ | 56 | /* SH-4A types */ |
55 | CPU_SH73180, CPU_SH7343, CPU_SH7770, CPU_SH7780, CPU_SH7781, | 57 | CPU_SH7770, CPU_SH7780, CPU_SH7781, CPU_SH7785, |
56 | CPU_SH7785, | 58 | |
59 | /* SH4AL-DSP types */ | ||
60 | CPU_SH73180, CPU_SH7343, CPU_SH7722, | ||
57 | 61 | ||
58 | /* Unknown subtype */ | 62 | /* Unknown subtype */ |
59 | CPU_SH_NONE | 63 | CPU_SH_NONE |
diff --git a/include/asm-sh/push-switch.h b/include/asm-sh/push-switch.h index dfc6bad567f0..4903f9e52dd8 100644 --- a/include/asm-sh/push-switch.h +++ b/include/asm-sh/push-switch.h | |||
@@ -4,6 +4,7 @@ | |||
4 | #include <linux/timer.h> | 4 | #include <linux/timer.h> |
5 | #include <linux/interrupt.h> | 5 | #include <linux/interrupt.h> |
6 | #include <linux/workqueue.h> | 6 | #include <linux/workqueue.h> |
7 | #include <linux/platform_device.h> | ||
7 | 8 | ||
8 | struct push_switch { | 9 | struct push_switch { |
9 | /* switch state */ | 10 | /* switch state */ |
@@ -12,6 +13,8 @@ struct push_switch { | |||
12 | struct timer_list debounce; | 13 | struct timer_list debounce; |
13 | /* workqueue */ | 14 | /* workqueue */ |
14 | struct work_struct work; | 15 | struct work_struct work; |
16 | /* platform device, for workqueue handler */ | ||
17 | struct platform_device *pdev; | ||
15 | }; | 18 | }; |
16 | 19 | ||
17 | struct push_switch_platform_info { | 20 | struct push_switch_platform_info { |