aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@woody.linux-foundation.org>2007-06-26 19:50:48 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-06-26 19:50:48 -0400
commit6cd236e0057704d1f5c77908374079e021c83928 (patch)
tree302e002d62dcd4663aef7e9a98ca4b019e3e5c98
parent2c9dbda360d96819456f845ea92e20e4e9d0ed36 (diff)
parent8e15a0e35fdaf19e1aeb7923571e928bd6123cfd (diff)
Merge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus
* 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus: [MIPS] Count timer interrupts correctly. [MIPS] SMTC and non-SMTC kernel and modules are incompatible [MIPS] EMMA2RH: Disable GEN_RTC, it can't possibly work. [MIPS] Remove a duplicated local variable in test_and_clear_bit() [MIPS] use compat_siginfo in rt_sigframe_n32 [MIPS] 20K: Handle WAIT related bugs according to errata information [MIPS] AP/SP requires shadow registers, auto enable support. [MIPS] Fix pb1500 reg B access [MIPS] Alchemy: Fix wrong cast [MIPS] remove "support for" from system type entry [MIPS] add io_map_base to pci_controller on Cobalt [MIPS] __ucmpdi2 arguments are unsigned long long.
-rw-r--r--arch/mips/Kconfig5
-rw-r--r--arch/mips/au1000/pb1100/init.c2
-rw-r--r--arch/mips/au1000/pb1500/board_setup.c2
-rw-r--r--arch/mips/cobalt/pci.c1
-rw-r--r--arch/mips/configs/emma2rh_defconfig3
-rw-r--r--arch/mips/kernel/cpu-probe.c12
-rw-r--r--arch/mips/kernel/signal32.c62
-rw-r--r--arch/mips/kernel/signal_n32.c6
-rw-r--r--arch/mips/kernel/smtc.c2
-rw-r--r--arch/mips/lib/ucmpdi2.c2
-rw-r--r--include/asm-mips/bitops.h2
-rw-r--r--include/asm-mips/compat-signal.h62
-rw-r--r--include/asm-mips/module.h9
13 files changed, 94 insertions, 76 deletions
diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
index 9528ee90640a..73455389257a 100644
--- a/arch/mips/Kconfig
+++ b/arch/mips/Kconfig
@@ -317,7 +317,7 @@ config PNX8550_JBS
317 select SYS_SUPPORTS_LITTLE_ENDIAN 317 select SYS_SUPPORTS_LITTLE_ENDIAN
318 318
319config PNX8550_STB810 319config PNX8550_STB810
320 bool "Support for Philips PNX8550 based STB810 board" 320 bool "Philips PNX8550 based STB810 board"
321 select PNX8550 321 select PNX8550
322 select SYS_SUPPORTS_LITTLE_ENDIAN 322 select SYS_SUPPORTS_LITTLE_ENDIAN
323 323
@@ -392,7 +392,7 @@ config QEMU
392 can be found at http://www.linux-mips.org/wiki/Qemu. 392 can be found at http://www.linux-mips.org/wiki/Qemu.
393 393
394config MARKEINS 394config MARKEINS
395 bool "Support for NEC EMMA2RH Mark-eins" 395 bool "NEC EMMA2RH Mark-eins"
396 select DMA_NONCOHERENT 396 select DMA_NONCOHERENT
397 select HW_HAS_PCI 397 select HW_HAS_PCI
398 select IRQ_CPU 398 select IRQ_CPU
@@ -1392,6 +1392,7 @@ config MIPS_VPE_LOADER
1392 depends on SYS_SUPPORTS_MULTITHREADING 1392 depends on SYS_SUPPORTS_MULTITHREADING
1393 select CPU_MIPSR2_IRQ_VI 1393 select CPU_MIPSR2_IRQ_VI
1394 select CPU_MIPSR2_IRQ_EI 1394 select CPU_MIPSR2_IRQ_EI
1395 select CPU_MIPSR2_SRS
1395 select MIPS_MT 1396 select MIPS_MT
1396 help 1397 help
1397 Includes a loader for loading an elf relocatable object 1398 Includes a loader for loading an elf relocatable object
diff --git a/arch/mips/au1000/pb1100/init.c b/arch/mips/au1000/pb1100/init.c
index 1fae39a608cf..6131b56f41b5 100644
--- a/arch/mips/au1000/pb1100/init.c
+++ b/arch/mips/au1000/pb1100/init.c
@@ -53,7 +53,7 @@ void __init prom_init(void)
53 53
54 prom_argc = fw_arg0; 54 prom_argc = fw_arg0;
55 prom_argv = (char **) fw_arg1; 55 prom_argv = (char **) fw_arg1;
56 prom_envp = (int *) fw_arg3; 56 prom_envp = (char **) fw_arg3;
57 57
58 mips_machgroup = MACH_GROUP_ALCHEMY; 58 mips_machgroup = MACH_GROUP_ALCHEMY;
59 mips_machtype = MACH_PB1100; 59 mips_machtype = MACH_PB1100;
diff --git a/arch/mips/au1000/pb1500/board_setup.c b/arch/mips/au1000/pb1500/board_setup.c
index 0ffdb4fd575b..c9b655616fb3 100644
--- a/arch/mips/au1000/pb1500/board_setup.c
+++ b/arch/mips/au1000/pb1500/board_setup.c
@@ -125,7 +125,7 @@ void __init board_setup(void)
125 au_writel((au_readl(0xac000028) | 0x20), 0xac000028); 125 au_writel((au_readl(0xac000028) | 0x20), 0xac000028);
126 } 126 }
127 /* Put the clock in BCD mode */ 127 /* Put the clock in BCD mode */
128 if (readl(0xac00002C) & 0x4) { /* reg B */ 128 if (au_readl(0xac00002C) & 0x4) { /* reg B */
129 au_writel(au_readl(0xac00002c) & ~0x4, 0xac00002c); 129 au_writel(au_readl(0xac00002c) & ~0x4, 0xac00002c);
130 au_sync(); 130 au_sync();
131 } 131 }
diff --git a/arch/mips/cobalt/pci.c b/arch/mips/cobalt/pci.c
index d91027f43de6..cfce7af1bca9 100644
--- a/arch/mips/cobalt/pci.c
+++ b/arch/mips/cobalt/pci.c
@@ -35,6 +35,7 @@ static struct pci_controller cobalt_pci_controller = {
35 .mem_resource = &cobalt_mem_resource, 35 .mem_resource = &cobalt_mem_resource,
36 .io_resource = &cobalt_io_resource, 36 .io_resource = &cobalt_io_resource,
37 .io_offset = 0 - GT_DEF_PCI0_IO_BASE, 37 .io_offset = 0 - GT_DEF_PCI0_IO_BASE,
38 .io_map_base = CKSEG1ADDR(GT_DEF_PCI0_IO_BASE),
38}; 39};
39 40
40static int __init cobalt_pci_init(void) 41static int __init cobalt_pci_init(void)
diff --git a/arch/mips/configs/emma2rh_defconfig b/arch/mips/configs/emma2rh_defconfig
index 3044579f171a..2e3e155b4c55 100644
--- a/arch/mips/configs/emma2rh_defconfig
+++ b/arch/mips/configs/emma2rh_defconfig
@@ -951,8 +951,7 @@ CONFIG_LEGACY_PTY_COUNT=256
951# CONFIG_WATCHDOG is not set 951# CONFIG_WATCHDOG is not set
952# CONFIG_HW_RANDOM is not set 952# CONFIG_HW_RANDOM is not set
953CONFIG_RTC=m 953CONFIG_RTC=m
954CONFIG_GEN_RTC=m 954# CONFIG_GEN_RTC is not set
955CONFIG_GEN_RTC_X=y
956# CONFIG_DTLK is not set 955# CONFIG_DTLK is not set
957# CONFIG_R3964 is not set 956# CONFIG_R3964 is not set
958# CONFIG_APPLICOM is not set 957# CONFIG_APPLICOM is not set
diff --git a/arch/mips/kernel/cpu-probe.c b/arch/mips/kernel/cpu-probe.c
index ab755ea26c6a..0fc90ba16ae1 100644
--- a/arch/mips/kernel/cpu-probe.c
+++ b/arch/mips/kernel/cpu-probe.c
@@ -137,7 +137,6 @@ static inline void check_wait(void)
137 case CPU_4KEC: 137 case CPU_4KEC:
138 case CPU_4KSC: 138 case CPU_4KSC:
139 case CPU_5KC: 139 case CPU_5KC:
140/* case CPU_20KC:*/
141 case CPU_24K: 140 case CPU_24K:
142 case CPU_25KF: 141 case CPU_25KF:
143 case CPU_34K: 142 case CPU_34K:
@@ -156,6 +155,17 @@ static inline void check_wait(void)
156 if (allow_au1k_wait) 155 if (allow_au1k_wait)
157 cpu_wait = au1k_wait; 156 cpu_wait = au1k_wait;
158 break; 157 break;
158 case CPU_20KC:
159 /*
160 * WAIT on Rev1.0 has E1, E2, E3 and E16.
161 * WAIT on Rev2.0 and Rev3.0 has E16.
162 * Rev3.1 WAIT is nop, why bother
163 */
164 if ((c->processor_id & 0xff) <= 0x64)
165 break;
166
167 cpu_wait = r4k_wait;
168 break;
159 case CPU_RM9000: 169 case CPU_RM9000:
160 if ((c->processor_id & 0x00ff) >= 0x40) 170 if ((c->processor_id & 0x00ff) >= 0x40)
161 cpu_wait = r4k_wait; 171 cpu_wait = r4k_wait;
diff --git a/arch/mips/kernel/signal32.c b/arch/mips/kernel/signal32.c
index 003f8152b9ed..486b8e5f52d0 100644
--- a/arch/mips/kernel/signal32.c
+++ b/arch/mips/kernel/signal32.c
@@ -36,68 +36,6 @@
36 36
37#include "signal-common.h" 37#include "signal-common.h"
38 38
39#define SI_PAD_SIZE32 ((SI_MAX_SIZE/sizeof(int)) - 3)
40
41typedef struct compat_siginfo {
42 int si_signo;
43 int si_code;
44 int si_errno;
45
46 union {
47 int _pad[SI_PAD_SIZE32];
48
49 /* kill() */
50 struct {
51 compat_pid_t _pid; /* sender's pid */
52 compat_uid_t _uid; /* sender's uid */
53 } _kill;
54
55 /* SIGCHLD */
56 struct {
57 compat_pid_t _pid; /* which child */
58 compat_uid_t _uid; /* sender's uid */
59 int _status; /* exit code */
60 compat_clock_t _utime;
61 compat_clock_t _stime;
62 } _sigchld;
63
64 /* IRIX SIGCHLD */
65 struct {
66 compat_pid_t _pid; /* which child */
67 compat_clock_t _utime;
68 int _status; /* exit code */
69 compat_clock_t _stime;
70 } _irix_sigchld;
71
72 /* SIGILL, SIGFPE, SIGSEGV, SIGBUS */
73 struct {
74 s32 _addr; /* faulting insn/memory ref. */
75 } _sigfault;
76
77 /* SIGPOLL, SIGXFSZ (To do ...) */
78 struct {
79 int _band; /* POLL_IN, POLL_OUT, POLL_MSG */
80 int _fd;
81 } _sigpoll;
82
83 /* POSIX.1b timers */
84 struct {
85 timer_t _tid; /* timer id */
86 int _overrun; /* overrun count */
87 compat_sigval_t _sigval;/* same as below */
88 int _sys_private; /* not to be passed to user */
89 } _timer;
90
91 /* POSIX.1b signals */
92 struct {
93 compat_pid_t _pid; /* sender's pid */
94 compat_uid_t _uid; /* sender's uid */
95 compat_sigval_t _sigval;
96 } _rt;
97
98 } _sifields;
99} compat_siginfo_t;
100
101/* 39/*
102 * Including <asm/unistd.h> would give use the 64-bit syscall numbers ... 40 * Including <asm/unistd.h> would give use the 64-bit syscall numbers ...
103 */ 41 */
diff --git a/arch/mips/kernel/signal_n32.c b/arch/mips/kernel/signal_n32.c
index 4cf9ff24d1f7..eb7e05926ebe 100644
--- a/arch/mips/kernel/signal_n32.c
+++ b/arch/mips/kernel/signal_n32.c
@@ -72,7 +72,7 @@ struct ucontextn32 {
72struct rt_sigframe_n32 { 72struct rt_sigframe_n32 {
73 u32 rs_ass[4]; /* argument save space for o32 */ 73 u32 rs_ass[4]; /* argument save space for o32 */
74 u32 rs_code[2]; /* signal trampoline */ 74 u32 rs_code[2]; /* signal trampoline */
75 struct siginfo rs_info; 75 struct compat_siginfo rs_info;
76 struct ucontextn32 rs_uc; 76 struct ucontextn32 rs_uc;
77}; 77};
78 78
@@ -81,7 +81,7 @@ struct rt_sigframe_n32 {
81struct rt_sigframe_n32 { 81struct rt_sigframe_n32 {
82 u32 rs_ass[4]; /* argument save space for o32 */ 82 u32 rs_ass[4]; /* argument save space for o32 */
83 u32 rs_pad[2]; 83 u32 rs_pad[2];
84 struct siginfo rs_info; 84 struct compat_siginfo rs_info;
85 struct ucontextn32 rs_uc; 85 struct ucontextn32 rs_uc;
86 u32 rs_code[8] ____cacheline_aligned; /* signal trampoline */ 86 u32 rs_code[8] ____cacheline_aligned; /* signal trampoline */
87}; 87};
@@ -187,7 +187,7 @@ static int setup_rt_frame_n32(struct k_sigaction * ka,
187 install_sigtramp(frame->rs_code, __NR_N32_rt_sigreturn); 187 install_sigtramp(frame->rs_code, __NR_N32_rt_sigreturn);
188 188
189 /* Create siginfo. */ 189 /* Create siginfo. */
190 err |= copy_siginfo_to_user(&frame->rs_info, info); 190 err |= copy_siginfo_to_user32(&frame->rs_info, info);
191 191
192 /* Create the ucontext. */ 192 /* Create the ucontext. */
193 err |= __put_user(0, &frame->rs_uc.uc_flags); 193 err |= __put_user(0, &frame->rs_uc.uc_flags);
diff --git a/arch/mips/kernel/smtc.c b/arch/mips/kernel/smtc.c
index 2e011470c347..046b03b1705a 100644
--- a/arch/mips/kernel/smtc.c
+++ b/arch/mips/kernel/smtc.c
@@ -822,7 +822,7 @@ void ipi_decode(struct smtc_ipi *pipi)
822 switch (type_copy) { 822 switch (type_copy) {
823 case SMTC_CLOCK_TICK: 823 case SMTC_CLOCK_TICK:
824 irq_enter(); 824 irq_enter();
825 kstat_this_cpu.irqs[MIPS_CPU_IRQ_BASE + cp0_perfcount_irq]++; 825 kstat_this_cpu.irqs[MIPS_CPU_IRQ_BASE + cp0_compare_irq]++;
826 /* Invoke Clock "Interrupt" */ 826 /* Invoke Clock "Interrupt" */
827 ipi_timer_latch[dest_copy] = 0; 827 ipi_timer_latch[dest_copy] = 0;
828#ifdef CONFIG_SMTC_IDLE_HOOK_DEBUG 828#ifdef CONFIG_SMTC_IDLE_HOOK_DEBUG
diff --git a/arch/mips/lib/ucmpdi2.c b/arch/mips/lib/ucmpdi2.c
index e9ff258ef028..e2ff6072b5a3 100644
--- a/arch/mips/lib/ucmpdi2.c
+++ b/arch/mips/lib/ucmpdi2.c
@@ -2,7 +2,7 @@
2 2
3#include "libgcc.h" 3#include "libgcc.h"
4 4
5word_type __ucmpdi2 (unsigned long a, unsigned long b) 5word_type __ucmpdi2 (unsigned long long a, unsigned long long b)
6{ 6{
7 const DWunion au = {.ll = a}; 7 const DWunion au = {.ll = a};
8 const DWunion bu = {.ll = b}; 8 const DWunion bu = {.ll = b};
diff --git a/include/asm-mips/bitops.h b/include/asm-mips/bitops.h
index ffe245b4258f..d9e81af53f78 100644
--- a/include/asm-mips/bitops.h
+++ b/include/asm-mips/bitops.h
@@ -310,7 +310,7 @@ static inline int test_and_clear_bit(unsigned long nr,
310 310
311 if (cpu_has_llsc && R10000_LLSC_WAR) { 311 if (cpu_has_llsc && R10000_LLSC_WAR) {
312 unsigned long *m = ((unsigned long *) addr) + (nr >> SZLONG_LOG); 312 unsigned long *m = ((unsigned long *) addr) + (nr >> SZLONG_LOG);
313 unsigned long temp, res; 313 unsigned long temp;
314 314
315 __asm__ __volatile__( 315 __asm__ __volatile__(
316 " .set mips3 \n" 316 " .set mips3 \n"
diff --git a/include/asm-mips/compat-signal.h b/include/asm-mips/compat-signal.h
index 6599a901b63e..368a99e5c3e1 100644
--- a/include/asm-mips/compat-signal.h
+++ b/include/asm-mips/compat-signal.h
@@ -10,6 +10,68 @@
10 10
11#include <asm/uaccess.h> 11#include <asm/uaccess.h>
12 12
13#define SI_PAD_SIZE32 ((SI_MAX_SIZE/sizeof(int)) - 3)
14
15typedef struct compat_siginfo {
16 int si_signo;
17 int si_code;
18 int si_errno;
19
20 union {
21 int _pad[SI_PAD_SIZE32];
22
23 /* kill() */
24 struct {
25 compat_pid_t _pid; /* sender's pid */
26 compat_uid_t _uid; /* sender's uid */
27 } _kill;
28
29 /* SIGCHLD */
30 struct {
31 compat_pid_t _pid; /* which child */
32 compat_uid_t _uid; /* sender's uid */
33 int _status; /* exit code */
34 compat_clock_t _utime;
35 compat_clock_t _stime;
36 } _sigchld;
37
38 /* IRIX SIGCHLD */
39 struct {
40 compat_pid_t _pid; /* which child */
41 compat_clock_t _utime;
42 int _status; /* exit code */
43 compat_clock_t _stime;
44 } _irix_sigchld;
45
46 /* SIGILL, SIGFPE, SIGSEGV, SIGBUS */
47 struct {
48 s32 _addr; /* faulting insn/memory ref. */
49 } _sigfault;
50
51 /* SIGPOLL, SIGXFSZ (To do ...) */
52 struct {
53 int _band; /* POLL_IN, POLL_OUT, POLL_MSG */
54 int _fd;
55 } _sigpoll;
56
57 /* POSIX.1b timers */
58 struct {
59 timer_t _tid; /* timer id */
60 int _overrun; /* overrun count */
61 compat_sigval_t _sigval;/* same as below */
62 int _sys_private; /* not to be passed to user */
63 } _timer;
64
65 /* POSIX.1b signals */
66 struct {
67 compat_pid_t _pid; /* sender's pid */
68 compat_uid_t _uid; /* sender's uid */
69 compat_sigval_t _sigval;
70 } _rt;
71
72 } _sifields;
73} compat_siginfo_t;
74
13static inline int __copy_conv_sigset_to_user(compat_sigset_t __user *d, 75static inline int __copy_conv_sigset_to_user(compat_sigset_t __user *d,
14 const sigset_t *s) 76 const sigset_t *s)
15{ 77{
diff --git a/include/asm-mips/module.h b/include/asm-mips/module.h
index 399d03f1c4fc..c5ef324fd69f 100644
--- a/include/asm-mips/module.h
+++ b/include/asm-mips/module.h
@@ -122,6 +122,13 @@ search_module_dbetables(unsigned long addr)
122#define MODULE_KERNEL_TYPE "64BIT " 122#define MODULE_KERNEL_TYPE "64BIT "
123#endif 123#endif
124 124
125#define MODULE_ARCH_VERMAGIC MODULE_PROC_FAMILY MODULE_KERNEL_TYPE 125#ifdef CONFIG_MIPS_MT_SMTC
126#define MODULE_KERNEL_SMTC "MT_SMTC "
127#else
128#define MODULE_KERNEL_SMTC ""
129#endif
130
131#define MODULE_ARCH_VERMAGIC \
132 MODULE_PROC_FAMILY MODULE_KERNEL_TYPE MODULE_KERNEL_SMTC
126 133
127#endif /* _ASM_MODULE_H */ 134#endif /* _ASM_MODULE_H */