diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-03-21 10:56:58 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-03-21 10:56:58 -0400 |
| commit | 2c7871982cf27caaddbaeb7e2121ce1374b520ff (patch) | |
| tree | b3257b5f532bbd152342a3fea08d18a744e65f85 | |
| parent | 49ccf74aaf6b53751dc0ae06ded9bb39343da822 (diff) | |
| parent | 49a5ba46c5d1e34bcb07634157b29d7414ce13bd (diff) | |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6.25
* git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6.25:
sh: Use relative paths for mach/cpu symlinks.
SH: Use newer, non-deprecated __SPIN_LOCK_UNLOCKED macro.
sh: Fix more user header breakage from sh64 integration.
sh: Fix uImage build error.
sh: Fix up the timer IRQ definition for SH7203.
sh: Fix up the address error exception handler for SH-2.
serial: sh-sci: Fix fifo stall on SH7760/SH7780/SH7785 SCIF.
| -rw-r--r-- | arch/sh/Kconfig | 1 | ||||
| -rw-r--r-- | arch/sh/Makefile | 8 | ||||
| -rw-r--r-- | arch/sh/boot/Makefile | 4 | ||||
| -rw-r--r-- | arch/sh/kernel/cpu/sh2/entry.S | 1 | ||||
| -rw-r--r-- | arch/sh/kernel/smp.c | 2 | ||||
| -rw-r--r-- | drivers/serial/sh-sci.c | 4 | ||||
| -rw-r--r-- | include/asm-sh/byteorder.h | 15 | ||||
| -rw-r--r-- | include/asm-sh/posix_types.h | 6 |
8 files changed, 25 insertions, 16 deletions
diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig index 95b7534e9e3c..12720489e458 100644 --- a/arch/sh/Kconfig +++ b/arch/sh/Kconfig | |||
| @@ -580,6 +580,7 @@ config SH_TIMER_IRQ | |||
| 580 | CPU_SUBTYPE_SH7763 | 580 | CPU_SUBTYPE_SH7763 |
| 581 | default "86" if CPU_SUBTYPE_SH7619 | 581 | default "86" if CPU_SUBTYPE_SH7619 |
| 582 | default "140" if CPU_SUBTYPE_SH7206 | 582 | default "140" if CPU_SUBTYPE_SH7206 |
| 583 | default "142" if CPU_SUBTYPE_SH7203 | ||
| 583 | default "16" | 584 | default "16" |
| 584 | 585 | ||
| 585 | config SH_PCLK_FREQ | 586 | config SH_PCLK_FREQ |
diff --git a/arch/sh/Makefile b/arch/sh/Makefile index c510c225144f..cffc92b1bf2e 100644 --- a/arch/sh/Makefile +++ b/arch/sh/Makefile | |||
| @@ -154,7 +154,11 @@ drivers-$(CONFIG_OPROFILE) += arch/sh/oprofile/ | |||
| 154 | 154 | ||
| 155 | boot := arch/sh/boot | 155 | boot := arch/sh/boot |
| 156 | 156 | ||
| 157 | ifneq ($(KBUILD_SRC),) | ||
| 157 | incdir-prefix := $(srctree)/include/asm-sh/ | 158 | incdir-prefix := $(srctree)/include/asm-sh/ |
| 159 | else | ||
| 160 | incdir-prefix := | ||
| 161 | endif | ||
| 158 | 162 | ||
| 159 | # Update machine arch and proc symlinks if something which affects | 163 | # Update machine arch and proc symlinks if something which affects |
| 160 | # them changed. We use .arch and .mach to indicate when they were | 164 | # them changed. We use .arch and .mach to indicate when they were |
| @@ -182,7 +186,7 @@ include/asm-sh/.mach: $(wildcard include/config/sh/*.h) \ | |||
| 182 | $(Q)if [ ! -d include/asm-sh ]; then mkdir -p include/asm-sh; fi | 186 | $(Q)if [ ! -d include/asm-sh ]; then mkdir -p include/asm-sh; fi |
| 183 | $(Q)rm -f include/asm-sh/mach | 187 | $(Q)rm -f include/asm-sh/mach |
| 184 | $(Q)for i in $(incdir-y); do \ | 188 | $(Q)for i in $(incdir-y); do \ |
| 185 | if [ -d $(incdir-prefix)$$i ]; then \ | 189 | if [ -d $(srctree)/include/asm-sh/$$i ]; then \ |
| 186 | echo -n ' SYMLINK include/asm-sh/mach -> '; \ | 190 | echo -n ' SYMLINK include/asm-sh/mach -> '; \ |
| 187 | echo -e "include/asm-sh/$$i"; \ | 191 | echo -e "include/asm-sh/$$i"; \ |
| 188 | ln -fsn $(incdir-prefix)$$i \ | 192 | ln -fsn $(incdir-prefix)$$i \ |
| @@ -191,7 +195,7 @@ include/asm-sh/.mach: $(wildcard include/config/sh/*.h) \ | |||
| 191 | if [ ! -d include/asm-sh/mach ]; then \ | 195 | if [ ! -d include/asm-sh/mach ]; then \ |
| 192 | echo -n ' SYMLINK include/asm-sh/mach -> '; \ | 196 | echo -n ' SYMLINK include/asm-sh/mach -> '; \ |
| 193 | echo -e 'include/asm-sh'; \ | 197 | echo -e 'include/asm-sh'; \ |
| 194 | ln -fsn $(incdir-prefix) include/asm-sh/mach; \ | 198 | ln -fsn $(incdir-prefix)../asm-sh include/asm-sh/mach; \ |
| 195 | fi; \ | 199 | fi; \ |
| 196 | fi; \ | 200 | fi; \ |
| 197 | done | 201 | done |
diff --git a/arch/sh/boot/Makefile b/arch/sh/boot/Makefile index 59f552c13349..3dda24daa0a8 100644 --- a/arch/sh/boot/Makefile +++ b/arch/sh/boot/Makefile | |||
| @@ -32,12 +32,12 @@ $(obj)/zImage: $(obj)/compressed/vmlinux FORCE | |||
| 32 | $(obj)/compressed/vmlinux: FORCE | 32 | $(obj)/compressed/vmlinux: FORCE |
| 33 | $(Q)$(MAKE) $(build)=$(obj)/compressed $@ | 33 | $(Q)$(MAKE) $(build)=$(obj)/compressed $@ |
| 34 | 34 | ||
| 35 | KERNEL_LOAD := $(shell /bin/bash -c 'printf "0x%8x" \ | 35 | KERNEL_LOAD := $(shell /bin/bash -c 'printf "0x%08x" \ |
| 36 | $$[$(CONFIG_PAGE_OFFSET) + \ | 36 | $$[$(CONFIG_PAGE_OFFSET) + \ |
| 37 | $(CONFIG_MEMORY_START) + \ | 37 | $(CONFIG_MEMORY_START) + \ |
| 38 | $(CONFIG_ZERO_PAGE_OFFSET)]') | 38 | $(CONFIG_ZERO_PAGE_OFFSET)]') |
| 39 | 39 | ||
| 40 | KERNEL_ENTRY := $(shell /bin/bash -c 'printf "0x%8x" \ | 40 | KERNEL_ENTRY := $(shell /bin/bash -c 'printf "0x%08x" \ |
| 41 | $$[$(CONFIG_PAGE_OFFSET) + \ | 41 | $$[$(CONFIG_PAGE_OFFSET) + \ |
| 42 | $(CONFIG_MEMORY_START) + \ | 42 | $(CONFIG_MEMORY_START) + \ |
| 43 | $(CONFIG_ZERO_PAGE_OFFSET)+0x1000]') | 43 | $(CONFIG_ZERO_PAGE_OFFSET)+0x1000]') |
diff --git a/arch/sh/kernel/cpu/sh2/entry.S b/arch/sh/kernel/cpu/sh2/entry.S index 7a26569e7956..0fc89069d8c7 100644 --- a/arch/sh/kernel/cpu/sh2/entry.S +++ b/arch/sh/kernel/cpu/sh2/entry.S | |||
| @@ -267,7 +267,6 @@ ENTRY(sh_bios_handler) | |||
| 267 | 267 | ||
| 268 | ENTRY(address_error_trap_handler) | 268 | ENTRY(address_error_trap_handler) |
| 269 | mov r15,r4 ! regs | 269 | mov r15,r4 ! regs |
| 270 | add #4,r4 | ||
| 271 | mov #OFF_PC,r0 | 270 | mov #OFF_PC,r0 |
| 272 | mov.l @(r0,r15),r6 ! pc | 271 | mov.l @(r0,r15),r6 ! pc |
| 273 | mov.l 1f,r0 | 272 | mov.l 1f,r0 |
diff --git a/arch/sh/kernel/smp.c b/arch/sh/kernel/smp.c index 94075e1a1e61..5d039d168f57 100644 --- a/arch/sh/kernel/smp.c +++ b/arch/sh/kernel/smp.c | |||
| @@ -179,7 +179,7 @@ void smp_send_stop(void) | |||
| 179 | } | 179 | } |
| 180 | 180 | ||
| 181 | struct smp_fn_call_struct smp_fn_call = { | 181 | struct smp_fn_call_struct smp_fn_call = { |
| 182 | .lock = SPIN_LOCK_UNLOCKED, | 182 | .lock = __SPIN_LOCK_UNLOCKED(smp_fn_call.lock), |
| 183 | .finished = ATOMIC_INIT(0), | 183 | .finished = ATOMIC_INIT(0), |
| 184 | }; | 184 | }; |
| 185 | 185 | ||
diff --git a/drivers/serial/sh-sci.c b/drivers/serial/sh-sci.c index a8c116b80bff..9d244d1644e1 100644 --- a/drivers/serial/sh-sci.c +++ b/drivers/serial/sh-sci.c | |||
| @@ -414,12 +414,12 @@ static void sci_init_pins_scif(struct uart_port *port, unsigned int cflag) | |||
| 414 | defined(CONFIG_CPU_SUBTYPE_SH7785) | 414 | defined(CONFIG_CPU_SUBTYPE_SH7785) |
| 415 | static inline int scif_txroom(struct uart_port *port) | 415 | static inline int scif_txroom(struct uart_port *port) |
| 416 | { | 416 | { |
| 417 | return SCIF_TXROOM_MAX - (sci_in(port, SCTFDR) & 0x7f); | 417 | return SCIF_TXROOM_MAX - (sci_in(port, SCTFDR) & 0xff); |
| 418 | } | 418 | } |
| 419 | 419 | ||
| 420 | static inline int scif_rxroom(struct uart_port *port) | 420 | static inline int scif_rxroom(struct uart_port *port) |
| 421 | { | 421 | { |
| 422 | return sci_in(port, SCRFDR) & 0x7f; | 422 | return sci_in(port, SCRFDR) & 0xff; |
| 423 | } | 423 | } |
| 424 | #else | 424 | #else |
| 425 | static inline int scif_txroom(struct uart_port *port) | 425 | static inline int scif_txroom(struct uart_port *port) |
diff --git a/include/asm-sh/byteorder.h b/include/asm-sh/byteorder.h index 0eb9904b6545..4c13e6117563 100644 --- a/include/asm-sh/byteorder.h +++ b/include/asm-sh/byteorder.h | |||
| @@ -11,13 +11,13 @@ | |||
| 11 | static inline __attribute_const__ __u32 ___arch__swab32(__u32 x) | 11 | static inline __attribute_const__ __u32 ___arch__swab32(__u32 x) |
| 12 | { | 12 | { |
| 13 | __asm__( | 13 | __asm__( |
| 14 | #ifdef CONFIG_SUPERH32 | 14 | #ifdef __SH5__ |
| 15 | "byterev %0, %0\n\t" | ||
| 16 | "shari %0, 32, %0" | ||
| 17 | #else | ||
| 15 | "swap.b %0, %0\n\t" | 18 | "swap.b %0, %0\n\t" |
| 16 | "swap.w %0, %0\n\t" | 19 | "swap.w %0, %0\n\t" |
| 17 | "swap.b %0, %0" | 20 | "swap.b %0, %0" |
| 18 | #else | ||
| 19 | "byterev %0, %0\n\t" | ||
| 20 | "shari %0, 32, %0" | ||
| 21 | #endif | 21 | #endif |
| 22 | : "=r" (x) | 22 | : "=r" (x) |
| 23 | : "0" (x)); | 23 | : "0" (x)); |
| @@ -28,12 +28,11 @@ static inline __attribute_const__ __u32 ___arch__swab32(__u32 x) | |||
| 28 | static inline __attribute_const__ __u16 ___arch__swab16(__u16 x) | 28 | static inline __attribute_const__ __u16 ___arch__swab16(__u16 x) |
| 29 | { | 29 | { |
| 30 | __asm__( | 30 | __asm__( |
| 31 | #ifdef CONFIG_SUPERH32 | 31 | #ifdef __SH5__ |
| 32 | "swap.b %0, %0" | ||
| 33 | #else | ||
| 34 | "byterev %0, %0\n\t" | 32 | "byterev %0, %0\n\t" |
| 35 | "shari %0, 32, %0" | 33 | "shari %0, 32, %0" |
| 36 | 34 | #else | |
| 35 | "swap.b %0, %0" | ||
| 37 | #endif | 36 | #endif |
| 38 | : "=r" (x) | 37 | : "=r" (x) |
| 39 | : "0" (x)); | 38 | : "0" (x)); |
diff --git a/include/asm-sh/posix_types.h b/include/asm-sh/posix_types.h index 4b9d11c9fc77..4eeb723aee7e 100644 --- a/include/asm-sh/posix_types.h +++ b/include/asm-sh/posix_types.h | |||
| @@ -4,4 +4,10 @@ | |||
| 4 | # else | 4 | # else |
| 5 | # include "posix_types_64.h" | 5 | # include "posix_types_64.h" |
| 6 | # endif | 6 | # endif |
| 7 | #else | ||
| 8 | # ifdef __SH5__ | ||
| 9 | # include "posix_types_64.h" | ||
| 10 | # else | ||
| 11 | # include "posix_types_32.h" | ||
| 12 | # endif | ||
| 7 | #endif /* __KERNEL__ */ | 13 | #endif /* __KERNEL__ */ |
