diff options
Diffstat (limited to 'arch/parisc')
| -rw-r--r-- | arch/parisc/configs/712_defconfig | 2 | ||||
| -rw-r--r-- | arch/parisc/configs/a500_defconfig | 2 | ||||
| -rw-r--r-- | arch/parisc/configs/b180_defconfig | 3 | ||||
| -rw-r--r-- | arch/parisc/configs/c3000_defconfig | 3 | ||||
| -rw-r--r-- | arch/parisc/configs/c8000_defconfig | 2 | ||||
| -rw-r--r-- | arch/parisc/configs/default_defconfig | 2 | ||||
| -rw-r--r-- | arch/parisc/include/asm/traps.h | 2 | ||||
| -rw-r--r-- | arch/parisc/kernel/head.S | 4 | ||||
| -rw-r--r-- | arch/parisc/kernel/smp.c | 8 | ||||
| -rw-r--r-- | arch/parisc/kernel/traps.c | 11 | ||||
| -rw-r--r-- | arch/parisc/lib/memcpy.c | 15 | ||||
| -rw-r--r-- | arch/parisc/mm/fault.c | 18 |
12 files changed, 49 insertions, 23 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 | |||
| 40 | CONFIG_LLC2=m | 40 | CONFIG_LLC2=m |
| 41 | CONFIG_NET_PKTGEN=m | 41 | CONFIG_NET_PKTGEN=m |
| 42 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" | 42 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" |
| 43 | CONFIG_DEVTMPFS=y | ||
| 44 | CONFIG_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 |
| 45 | CONFIG_PARPORT=y | 47 | CONFIG_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 | |||
| 79 | CONFIG_LLC2=m | 79 | CONFIG_LLC2=m |
| 80 | CONFIG_NET_PKTGEN=m | 80 | CONFIG_NET_PKTGEN=m |
| 81 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" | 81 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" |
| 82 | CONFIG_DEVTMPFS=y | ||
| 83 | CONFIG_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 |
| 84 | CONFIG_BLK_DEV_UMEM=m | 86 | CONFIG_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 | |||
| 4 | CONFIG_IKCONFIG_PROC=y | 4 | CONFIG_IKCONFIG_PROC=y |
| 5 | CONFIG_LOG_BUF_SHIFT=16 | 5 | CONFIG_LOG_BUF_SHIFT=16 |
| 6 | CONFIG_SYSFS_DEPRECATED_V2=y | 6 | CONFIG_SYSFS_DEPRECATED_V2=y |
| 7 | CONFIG_BLK_DEV_INITRD=y | ||
| 7 | CONFIG_SLAB=y | 8 | CONFIG_SLAB=y |
| 8 | CONFIG_MODULES=y | 9 | CONFIG_MODULES=y |
| 9 | CONFIG_MODVERSIONS=y | 10 | CONFIG_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 |
| 28 | CONFIG_IPV6=y | 29 | CONFIG_IPV6=y |
| 29 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" | 30 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" |
| 31 | CONFIG_DEVTMPFS=y | ||
| 32 | CONFIG_DEVTMPFS_MOUNT=y | ||
| 30 | # CONFIG_PREVENT_FIRMWARE_BUILD is not set | 33 | # CONFIG_PREVENT_FIRMWARE_BUILD is not set |
| 31 | CONFIG_PARPORT=y | 34 | CONFIG_PARPORT=y |
| 32 | CONFIG_PARPORT_PC=y | 35 | CONFIG_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 | |||
| 5 | CONFIG_IKCONFIG_PROC=y | 5 | CONFIG_IKCONFIG_PROC=y |
| 6 | CONFIG_LOG_BUF_SHIFT=16 | 6 | CONFIG_LOG_BUF_SHIFT=16 |
| 7 | CONFIG_SYSFS_DEPRECATED_V2=y | 7 | CONFIG_SYSFS_DEPRECATED_V2=y |
| 8 | CONFIG_BLK_DEV_INITRD=y | ||
| 8 | # CONFIG_CC_OPTIMIZE_FOR_SIZE is not set | 9 | # CONFIG_CC_OPTIMIZE_FOR_SIZE is not set |
| 9 | CONFIG_EXPERT=y | 10 | CONFIG_EXPERT=y |
| 10 | CONFIG_KALLSYMS_ALL=y | 11 | CONFIG_KALLSYMS_ALL=y |
| @@ -39,6 +40,8 @@ CONFIG_NETFILTER_DEBUG=y | |||
| 39 | CONFIG_IP_NF_QUEUE=m | 40 | CONFIG_IP_NF_QUEUE=m |
| 40 | CONFIG_NET_PKTGEN=m | 41 | CONFIG_NET_PKTGEN=m |
| 41 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" | 42 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" |
| 43 | CONFIG_DEVTMPFS=y | ||
| 44 | CONFIG_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 |
| 44 | CONFIG_BLK_DEV_UMEM=m | 47 | CONFIG_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 | |||
| 62 | CONFIG_LLC2=m | 62 | CONFIG_LLC2=m |
| 63 | CONFIG_DNS_RESOLVER=y | 63 | CONFIG_DNS_RESOLVER=y |
| 64 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" | 64 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" |
| 65 | CONFIG_DEVTMPFS=y | ||
| 66 | CONFIG_DEVTMPFS_MOUNT=y | ||
| 65 | # CONFIG_STANDALONE is not set | 67 | # CONFIG_STANDALONE is not set |
| 66 | CONFIG_PARPORT=y | 68 | CONFIG_PARPORT=y |
| 67 | CONFIG_PARPORT_PC=y | 69 | CONFIG_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 | |||
| 49 | CONFIG_INET6_IPCOMP=y | 49 | CONFIG_INET6_IPCOMP=y |
| 50 | CONFIG_LLC2=m | 50 | CONFIG_LLC2=m |
| 51 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" | 51 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" |
| 52 | CONFIG_DEVTMPFS=y | ||
| 53 | CONFIG_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 |
| 54 | CONFIG_PARPORT=y | 56 | CONFIG_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 */ |
| 8 | void parisc_terminate(char *msg, struct pt_regs *regs, | 8 | void 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 */ |
| 12 | void do_page_fault(struct pt_regs *regs, unsigned long code, | 12 | void 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 | ||
| 205 | stext_pdc_ret: | 207 | stext_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 | ||
| 261 | void arch_send_call_function_single_ipi(int cpu) | 255 | void 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 | ||
| 294 | int 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 |
| 301 | static void handle_gdb_break(struct pt_regs *regs, int wot) | 296 | static 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); | |||
| 524 | EXPORT_SYMBOL(copy_from_user); | 524 | EXPORT_SYMBOL(copy_from_user); |
| 525 | EXPORT_SYMBOL(copy_in_user); | 525 | EXPORT_SYMBOL(copy_in_user); |
| 526 | EXPORT_SYMBOL(memcpy); | 526 | EXPORT_SYMBOL(memcpy); |
| 527 | |||
| 528 | long 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 d10d27a720c0..0293588d5b8c 100644 --- a/arch/parisc/mm/fault.c +++ b/arch/parisc/mm/fault.c | |||
| @@ -171,17 +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; |
| 191 | |||
| 192 | acc_type = parisc_acctyp(code, regs->iir); | ||
| 185 | if (acc_type & VM_WRITE) | 193 | if (acc_type & VM_WRITE) |
| 186 | flags |= FAULT_FLAG_WRITE; | 194 | flags |= FAULT_FLAG_WRITE; |
| 187 | retry: | 195 | retry: |
| @@ -196,8 +204,6 @@ retry: | |||
| 196 | 204 | ||
| 197 | good_area: | 205 | good_area: |
| 198 | 206 | ||
| 199 | acc_type = parisc_acctyp(code,regs->iir); | ||
| 200 | |||
| 201 | if ((vma->vm_flags & acc_type) != acc_type) | 207 | if ((vma->vm_flags & acc_type) != acc_type) |
| 202 | goto bad_area; | 208 | goto bad_area; |
| 203 | 209 | ||
