Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

m68k: switch to generic extable.h

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>

Al Viro 68acfdcb d597580d

+11 -51
+1
arch/m68k/include/asm/Kbuild
··· 5 5 generic-y += emergency-restart.h 6 6 generic-y += errno.h 7 7 generic-y += exec.h 8 + generic-y += extable.h 8 9 generic-y += futex.h 9 10 generic-y += hw_irq.h 10 11 generic-y += ioctl.h
-10
arch/m68k/include/asm/processor.h
··· 122 122 wrusp(usp); 123 123 } 124 124 125 - #ifdef CONFIG_MMU 126 - extern int handle_kernel_fault(struct pt_regs *regs); 127 - #else 128 - static inline int handle_kernel_fault(struct pt_regs *regs) 129 - { 130 - /* Any fault in kernel is fatal on non-mmu */ 131 - return 0; 132 - } 133 - #endif 134 - 135 125 /* Forward declaration, a strange C thing */ 136 126 struct task_struct; 137 127
+1
arch/m68k/include/asm/uaccess.h
··· 4 4 #include <asm/uaccess_mm.h> 5 5 #endif 6 6 7 + #include <asm/extable.h> 7 8 #ifdef CONFIG_CPU_HAS_NO_UNALIGNED 8 9 #include <asm-generic/uaccess-unaligned.h> 9 10 #else
-18
arch/m68k/include/asm/uaccess_mm.h
··· 31 31 #define MOVES "move" 32 32 #endif 33 33 34 - /* 35 - * The exception table consists of pairs of addresses: the first is the 36 - * address of an instruction that is allowed to fault, and the second is 37 - * the address at which the program should continue. No registers are 38 - * modified, so it is entirely up to the continuation code to figure out 39 - * what to do. 40 - * 41 - * All the routines below use bits of fixup code that are out of line 42 - * with the main instruction path. This means when everything is well, 43 - * we don't even have to jump over them. Further, they do not intrude 44 - * on our cache or tlb entries. 45 - */ 46 - 47 - struct exception_table_entry 48 - { 49 - unsigned long insn, fixup; 50 - }; 51 - 52 34 extern int __put_user_bad(void); 53 35 extern int __get_user_bad(void); 54 36
-19
arch/m68k/include/asm/uaccess_no.h
··· 23 23 } 24 24 25 25 /* 26 - * The exception table consists of pairs of addresses: the first is the 27 - * address of an instruction that is allowed to fault, and the second is 28 - * the address at which the program should continue. No registers are 29 - * modified, so it is entirely up to the continuation code to figure out 30 - * what to do. 31 - * 32 - * All the routines below use bits of fixup code that are out of line 33 - * with the main instruction path. This means when everything is well, 34 - * we don't even have to jump over them. Further, they do not intrude 35 - * on our cache or tlb entries. 36 - */ 37 - 38 - struct exception_table_entry 39 - { 40 - unsigned long insn, fixup; 41 - }; 42 - 43 - 44 - /* 45 26 * These are the main single-value transfer routines. They automatically 46 27 * use the right size if we just have the right pointer type. 47 28 */
+1 -1
arch/m68k/kernel/signal.c
··· 88 88 return frame_size_change[f]; 89 89 } 90 90 91 - int handle_kernel_fault(struct pt_regs *regs) 91 + int fixup_exception(struct pt_regs *regs) 92 92 { 93 93 const struct exception_table_entry *fixup; 94 94 struct pt_regs *tregs;
+7 -2
arch/m68k/kernel/traps.c
··· 1016 1016 /* traced a trapping instruction on a 68020/30, 1017 1017 * real exception will be executed afterwards. 1018 1018 */ 1019 - } else if (!handle_kernel_fault(&fp->ptregs)) 1020 - bad_super_trap(fp); 1019 + return; 1020 + } 1021 + #ifdef CONFIG_MMU 1022 + if (fixup_exception(&fp->ptregs)) 1023 + return; 1024 + #endif 1025 + bad_super_trap(fp); 1021 1026 return; 1022 1027 } 1023 1028
+1 -1
arch/m68k/mm/fault.c
··· 32 32 force_sig_info(siginfo.si_signo, 33 33 &siginfo, current); 34 34 } else { 35 - if (handle_kernel_fault(regs)) 35 + if (fixup_exception(regs)) 36 36 return -1; 37 37 38 38 //if (siginfo.si_signo == SIGBUS)