aboutsummaryrefslogtreecommitdiffstats
path: root/arch/parisc
diff options
context:
space:
mode:
authorIngo Molnar <mingo@kernel.org>2013-11-01 03:10:58 -0400
committerIngo Molnar <mingo@kernel.org>2013-11-01 03:24:41 -0400
commitfb10d5b7efbcc0aa9e46a9aa5ad86772c7bacb9a (patch)
treeea284fe7b9c17a85b8d3c4ba999d6e26d51a12f6 /arch/parisc
parentf9f9ffc237dd924f048204e8799da74f9ecf40cf (diff)
parent52469b4fcd4fc433ffc78cec4cf94368e9052890 (diff)
Merge branch 'linus' into sched/core
Resolve cherry-picking conflicts: Conflicts: mm/huge_memory.c mm/memory.c mm/mprotect.c See this upstream merge commit for more details: 52469b4fcd4f Merge branch 'core-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'arch/parisc')
-rw-r--r--arch/parisc/configs/712_defconfig2
-rw-r--r--arch/parisc/configs/a500_defconfig2
-rw-r--r--arch/parisc/configs/b180_defconfig3
-rw-r--r--arch/parisc/configs/c3000_defconfig3
-rw-r--r--arch/parisc/configs/c8000_defconfig2
-rw-r--r--arch/parisc/configs/default_defconfig2
-rw-r--r--arch/parisc/include/asm/traps.h2
-rw-r--r--arch/parisc/kernel/head.S4
-rw-r--r--arch/parisc/kernel/smp.c8
-rw-r--r--arch/parisc/kernel/traps.c11
-rw-r--r--arch/parisc/lib/memcpy.c15
-rw-r--r--arch/parisc/mm/fault.c15
12 files changed, 47 insertions, 22 deletions
diff --git a/arch/parisc/configs/712_defconfig b/arch/parisc/configs/712_defconfig
index 0f90569b9d85..9387cc2693f6 100644
--- a/arch/parisc/configs/712_defconfig
+++ b/arch/parisc/configs/712_defconfig
@@ -40,6 +40,8 @@ CONFIG_IP_NF_QUEUE=m
40CONFIG_LLC2=m 40CONFIG_LLC2=m
41CONFIG_NET_PKTGEN=m 41CONFIG_NET_PKTGEN=m
42CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" 42CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
43CONFIG_DEVTMPFS=y
44CONFIG_DEVTMPFS_MOUNT=y
43# CONFIG_STANDALONE is not set 45# CONFIG_STANDALONE is not set
44# CONFIG_PREVENT_FIRMWARE_BUILD is not set 46# CONFIG_PREVENT_FIRMWARE_BUILD is not set
45CONFIG_PARPORT=y 47CONFIG_PARPORT=y
diff --git a/arch/parisc/configs/a500_defconfig b/arch/parisc/configs/a500_defconfig
index b647b182dacc..90025322b75e 100644
--- a/arch/parisc/configs/a500_defconfig
+++ b/arch/parisc/configs/a500_defconfig
@@ -79,6 +79,8 @@ CONFIG_IP_DCCP=m
79CONFIG_LLC2=m 79CONFIG_LLC2=m
80CONFIG_NET_PKTGEN=m 80CONFIG_NET_PKTGEN=m
81CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" 81CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
82CONFIG_DEVTMPFS=y
83CONFIG_DEVTMPFS_MOUNT=y
82# CONFIG_STANDALONE is not set 84# CONFIG_STANDALONE is not set
83# CONFIG_PREVENT_FIRMWARE_BUILD is not set 85# CONFIG_PREVENT_FIRMWARE_BUILD is not set
84CONFIG_BLK_DEV_UMEM=m 86CONFIG_BLK_DEV_UMEM=m
diff --git a/arch/parisc/configs/b180_defconfig b/arch/parisc/configs/b180_defconfig
index e289f5bf3148..f1a0c25bef8d 100644
--- a/arch/parisc/configs/b180_defconfig
+++ b/arch/parisc/configs/b180_defconfig
@@ -4,6 +4,7 @@ CONFIG_IKCONFIG=y
4CONFIG_IKCONFIG_PROC=y 4CONFIG_IKCONFIG_PROC=y
5CONFIG_LOG_BUF_SHIFT=16 5CONFIG_LOG_BUF_SHIFT=16
6CONFIG_SYSFS_DEPRECATED_V2=y 6CONFIG_SYSFS_DEPRECATED_V2=y
7CONFIG_BLK_DEV_INITRD=y
7CONFIG_SLAB=y 8CONFIG_SLAB=y
8CONFIG_MODULES=y 9CONFIG_MODULES=y
9CONFIG_MODVERSIONS=y 10CONFIG_MODVERSIONS=y
@@ -27,6 +28,8 @@ CONFIG_IP_PNP_BOOTP=y
27# CONFIG_INET_LRO is not set 28# CONFIG_INET_LRO is not set
28CONFIG_IPV6=y 29CONFIG_IPV6=y
29CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" 30CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
31CONFIG_DEVTMPFS=y
32CONFIG_DEVTMPFS_MOUNT=y
30# CONFIG_PREVENT_FIRMWARE_BUILD is not set 33# CONFIG_PREVENT_FIRMWARE_BUILD is not set
31CONFIG_PARPORT=y 34CONFIG_PARPORT=y
32CONFIG_PARPORT_PC=y 35CONFIG_PARPORT_PC=y
diff --git a/arch/parisc/configs/c3000_defconfig b/arch/parisc/configs/c3000_defconfig
index 311ca367b622..ec1b014952b6 100644
--- a/arch/parisc/configs/c3000_defconfig
+++ b/arch/parisc/configs/c3000_defconfig
@@ -5,6 +5,7 @@ CONFIG_IKCONFIG=y
5CONFIG_IKCONFIG_PROC=y 5CONFIG_IKCONFIG_PROC=y
6CONFIG_LOG_BUF_SHIFT=16 6CONFIG_LOG_BUF_SHIFT=16
7CONFIG_SYSFS_DEPRECATED_V2=y 7CONFIG_SYSFS_DEPRECATED_V2=y
8CONFIG_BLK_DEV_INITRD=y
8# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set 9# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set
9CONFIG_EXPERT=y 10CONFIG_EXPERT=y
10CONFIG_KALLSYMS_ALL=y 11CONFIG_KALLSYMS_ALL=y
@@ -39,6 +40,8 @@ CONFIG_NETFILTER_DEBUG=y
39CONFIG_IP_NF_QUEUE=m 40CONFIG_IP_NF_QUEUE=m
40CONFIG_NET_PKTGEN=m 41CONFIG_NET_PKTGEN=m
41CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" 42CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
43CONFIG_DEVTMPFS=y
44CONFIG_DEVTMPFS_MOUNT=y
42# CONFIG_STANDALONE is not set 45# CONFIG_STANDALONE is not set
43# CONFIG_PREVENT_FIRMWARE_BUILD is not set 46# CONFIG_PREVENT_FIRMWARE_BUILD is not set
44CONFIG_BLK_DEV_UMEM=m 47CONFIG_BLK_DEV_UMEM=m
diff --git a/arch/parisc/configs/c8000_defconfig b/arch/parisc/configs/c8000_defconfig
index f11006361297..e1c8d2015c89 100644
--- a/arch/parisc/configs/c8000_defconfig
+++ b/arch/parisc/configs/c8000_defconfig
@@ -62,6 +62,8 @@ CONFIG_TIPC=m
62CONFIG_LLC2=m 62CONFIG_LLC2=m
63CONFIG_DNS_RESOLVER=y 63CONFIG_DNS_RESOLVER=y
64CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" 64CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
65CONFIG_DEVTMPFS=y
66CONFIG_DEVTMPFS_MOUNT=y
65# CONFIG_STANDALONE is not set 67# CONFIG_STANDALONE is not set
66CONFIG_PARPORT=y 68CONFIG_PARPORT=y
67CONFIG_PARPORT_PC=y 69CONFIG_PARPORT_PC=y
diff --git a/arch/parisc/configs/default_defconfig b/arch/parisc/configs/default_defconfig
index dfe88f6c95c4..ba61495e1fa4 100644
--- a/arch/parisc/configs/default_defconfig
+++ b/arch/parisc/configs/default_defconfig
@@ -49,6 +49,8 @@ CONFIG_INET6_ESP=y
49CONFIG_INET6_IPCOMP=y 49CONFIG_INET6_IPCOMP=y
50CONFIG_LLC2=m 50CONFIG_LLC2=m
51CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" 51CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
52CONFIG_DEVTMPFS=y
53CONFIG_DEVTMPFS_MOUNT=y
52# CONFIG_STANDALONE is not set 54# CONFIG_STANDALONE is not set
53# CONFIG_PREVENT_FIRMWARE_BUILD is not set 55# CONFIG_PREVENT_FIRMWARE_BUILD is not set
54CONFIG_PARPORT=y 56CONFIG_PARPORT=y
diff --git a/arch/parisc/include/asm/traps.h b/arch/parisc/include/asm/traps.h
index 1945f995f2df..4736020ba5ea 100644
--- a/arch/parisc/include/asm/traps.h
+++ b/arch/parisc/include/asm/traps.h
@@ -6,7 +6,7 @@ struct pt_regs;
6 6
7/* traps.c */ 7/* traps.c */
8void parisc_terminate(char *msg, struct pt_regs *regs, 8void parisc_terminate(char *msg, struct pt_regs *regs,
9 int code, unsigned long offset); 9 int code, unsigned long offset) __noreturn __cold;
10 10
11/* mm/fault.c */ 11/* mm/fault.c */
12void do_page_fault(struct pt_regs *regs, unsigned long code, 12void do_page_fault(struct pt_regs *regs, unsigned long code,
diff --git a/arch/parisc/kernel/head.S b/arch/parisc/kernel/head.S
index 37aabd772fbb..d2d58258aea6 100644
--- a/arch/parisc/kernel/head.S
+++ b/arch/parisc/kernel/head.S
@@ -195,6 +195,8 @@ common_stext:
195 ldw MEM_PDC_HI(%r0),%r6 195 ldw MEM_PDC_HI(%r0),%r6
196 depd %r6, 31, 32, %r3 /* move to upper word */ 196 depd %r6, 31, 32, %r3 /* move to upper word */
197 197
198 mfctl %cr30,%r6 /* PCX-W2 firmware bug */
199
198 ldo PDC_PSW(%r0),%arg0 /* 21 */ 200 ldo PDC_PSW(%r0),%arg0 /* 21 */
199 ldo PDC_PSW_SET_DEFAULTS(%r0),%arg1 /* 2 */ 201 ldo PDC_PSW_SET_DEFAULTS(%r0),%arg1 /* 2 */
200 ldo PDC_PSW_WIDE_BIT(%r0),%arg2 /* 2 */ 202 ldo PDC_PSW_WIDE_BIT(%r0),%arg2 /* 2 */
@@ -203,6 +205,8 @@ common_stext:
203 copy %r0,%arg3 205 copy %r0,%arg3
204 206
205stext_pdc_ret: 207stext_pdc_ret:
208 mtctl %r6,%cr30 /* restore task thread info */
209
206 /* restore rfi target address*/ 210 /* restore rfi target address*/
207 ldd TI_TASK-THREAD_SZ_ALGN(%sp), %r10 211 ldd TI_TASK-THREAD_SZ_ALGN(%sp), %r10
208 tophys_r1 %r10 212 tophys_r1 %r10
diff --git a/arch/parisc/kernel/smp.c b/arch/parisc/kernel/smp.c
index 8a252f2d6c08..2b96602e812f 100644
--- a/arch/parisc/kernel/smp.c
+++ b/arch/parisc/kernel/smp.c
@@ -72,7 +72,6 @@ enum ipi_message_type {
72 IPI_NOP=0, 72 IPI_NOP=0,
73 IPI_RESCHEDULE=1, 73 IPI_RESCHEDULE=1,
74 IPI_CALL_FUNC, 74 IPI_CALL_FUNC,
75 IPI_CALL_FUNC_SINGLE,
76 IPI_CPU_START, 75 IPI_CPU_START,
77 IPI_CPU_STOP, 76 IPI_CPU_STOP,
78 IPI_CPU_TEST 77 IPI_CPU_TEST
@@ -164,11 +163,6 @@ ipi_interrupt(int irq, void *dev_id)
164 generic_smp_call_function_interrupt(); 163 generic_smp_call_function_interrupt();
165 break; 164 break;
166 165
167 case IPI_CALL_FUNC_SINGLE:
168 smp_debug(100, KERN_DEBUG "CPU%d IPI_CALL_FUNC_SINGLE\n", this_cpu);
169 generic_smp_call_function_single_interrupt();
170 break;
171
172 case IPI_CPU_START: 166 case IPI_CPU_START:
173 smp_debug(100, KERN_DEBUG "CPU%d IPI_CPU_START\n", this_cpu); 167 smp_debug(100, KERN_DEBUG "CPU%d IPI_CPU_START\n", this_cpu);
174 break; 168 break;
@@ -260,7 +254,7 @@ void arch_send_call_function_ipi_mask(const struct cpumask *mask)
260 254
261void arch_send_call_function_single_ipi(int cpu) 255void arch_send_call_function_single_ipi(int cpu)
262{ 256{
263 send_IPI_single(cpu, IPI_CALL_FUNC_SINGLE); 257 send_IPI_single(cpu, IPI_CALL_FUNC);
264} 258}
265 259
266/* 260/*
diff --git a/arch/parisc/kernel/traps.c b/arch/parisc/kernel/traps.c
index 04e47c6a4562..1cd1d0c83b6d 100644
--- a/arch/parisc/kernel/traps.c
+++ b/arch/parisc/kernel/traps.c
@@ -291,11 +291,6 @@ void die_if_kernel(char *str, struct pt_regs *regs, long err)
291 do_exit(SIGSEGV); 291 do_exit(SIGSEGV);
292} 292}
293 293
294int syscall_ipi(int (*syscall) (struct pt_regs *), struct pt_regs *regs)
295{
296 return syscall(regs);
297}
298
299/* gdb uses break 4,8 */ 294/* gdb uses break 4,8 */
300#define GDB_BREAK_INSN 0x10004 295#define GDB_BREAK_INSN 0x10004
301static void handle_gdb_break(struct pt_regs *regs, int wot) 296static void handle_gdb_break(struct pt_regs *regs, int wot)
@@ -805,14 +800,14 @@ void notrace handle_interruption(int code, struct pt_regs *regs)
805 else { 800 else {
806 801
807 /* 802 /*
808 * The kernel should never fault on its own address space. 803 * The kernel should never fault on its own address space,
804 * unless pagefault_disable() was called before.
809 */ 805 */
810 806
811 if (fault_space == 0) 807 if (fault_space == 0 && !in_atomic())
812 { 808 {
813 pdc_chassis_send_status(PDC_CHASSIS_DIRECT_PANIC); 809 pdc_chassis_send_status(PDC_CHASSIS_DIRECT_PANIC);
814 parisc_terminate("Kernel Fault", regs, code, fault_address); 810 parisc_terminate("Kernel Fault", regs, code, fault_address);
815
816 } 811 }
817 } 812 }
818 813
diff --git a/arch/parisc/lib/memcpy.c b/arch/parisc/lib/memcpy.c
index ac4370b1ca40..b5507ec06b84 100644
--- a/arch/parisc/lib/memcpy.c
+++ b/arch/parisc/lib/memcpy.c
@@ -56,7 +56,7 @@
56#ifdef __KERNEL__ 56#ifdef __KERNEL__
57#include <linux/module.h> 57#include <linux/module.h>
58#include <linux/compiler.h> 58#include <linux/compiler.h>
59#include <asm/uaccess.h> 59#include <linux/uaccess.h>
60#define s_space "%%sr1" 60#define s_space "%%sr1"
61#define d_space "%%sr2" 61#define d_space "%%sr2"
62#else 62#else
@@ -524,4 +524,17 @@ EXPORT_SYMBOL(copy_to_user);
524EXPORT_SYMBOL(copy_from_user); 524EXPORT_SYMBOL(copy_from_user);
525EXPORT_SYMBOL(copy_in_user); 525EXPORT_SYMBOL(copy_in_user);
526EXPORT_SYMBOL(memcpy); 526EXPORT_SYMBOL(memcpy);
527
528long probe_kernel_read(void *dst, const void *src, size_t size)
529{
530 unsigned long addr = (unsigned long)src;
531
532 if (size < 0 || addr < PAGE_SIZE)
533 return -EFAULT;
534
535 /* check for I/O space F_EXTEND(0xfff00000) access as well? */
536
537 return __probe_kernel_read(dst, src, size);
538}
539
527#endif 540#endif
diff --git a/arch/parisc/mm/fault.c b/arch/parisc/mm/fault.c
index 00c0ed333a3d..0293588d5b8c 100644
--- a/arch/parisc/mm/fault.c
+++ b/arch/parisc/mm/fault.c
@@ -171,20 +171,25 @@ void do_page_fault(struct pt_regs *regs, unsigned long code,
171 unsigned long address) 171 unsigned long address)
172{ 172{
173 struct vm_area_struct *vma, *prev_vma; 173 struct vm_area_struct *vma, *prev_vma;
174 struct task_struct *tsk = current; 174 struct task_struct *tsk;
175 struct mm_struct *mm = tsk->mm; 175 struct mm_struct *mm;
176 unsigned long acc_type; 176 unsigned long acc_type;
177 int fault; 177 int fault;
178 unsigned int flags = FAULT_FLAG_ALLOW_RETRY | FAULT_FLAG_KILLABLE; 178 unsigned int flags;
179 179
180 if (in_atomic() || !mm) 180 if (in_atomic())
181 goto no_context; 181 goto no_context;
182 182
183 tsk = current;
184 mm = tsk->mm;
185 if (!mm)
186 goto no_context;
187
188 flags = FAULT_FLAG_ALLOW_RETRY | FAULT_FLAG_KILLABLE;
183 if (user_mode(regs)) 189 if (user_mode(regs))
184 flags |= FAULT_FLAG_USER; 190 flags |= FAULT_FLAG_USER;
185 191
186 acc_type = parisc_acctyp(code, regs->iir); 192 acc_type = parisc_acctyp(code, regs->iir);
187
188 if (acc_type & VM_WRITE) 193 if (acc_type & VM_WRITE)
189 flags |= FAULT_FLAG_WRITE; 194 flags |= FAULT_FLAG_WRITE;
190retry: 195retry: