diff options
Diffstat (limited to 'arch/um')
-rw-r--r-- | arch/um/include/os.h | 4 | ||||
-rw-r--r-- | arch/um/kernel/um_arch.c | 2 |
2 files changed, 6 insertions, 0 deletions
diff --git a/arch/um/include/os.h b/arch/um/include/os.h index 583329d0a539..6f766e1faecc 100644 --- a/arch/um/include/os.h +++ b/arch/um/include/os.h | |||
@@ -157,6 +157,10 @@ extern int os_lock_file(int fd, int excl); | |||
157 | extern void os_early_checks(void); | 157 | extern void os_early_checks(void); |
158 | extern int can_do_skas(void); | 158 | extern int can_do_skas(void); |
159 | 159 | ||
160 | /* Make sure they are clear when running in TT mode. Required by | ||
161 | * SEGV_MAYBE_FIXABLE */ | ||
162 | #define clear_can_do_skas() do { ptrace_faultinfo = proc_mm = 0; } while (0) | ||
163 | |||
160 | /* mem.c */ | 164 | /* mem.c */ |
161 | extern int create_mem_file(unsigned long len); | 165 | extern int create_mem_file(unsigned long len); |
162 | 166 | ||
diff --git a/arch/um/kernel/um_arch.c b/arch/um/kernel/um_arch.c index f0a275947d34..93dc782dc1cc 100644 --- a/arch/um/kernel/um_arch.c +++ b/arch/um/kernel/um_arch.c | |||
@@ -334,6 +334,8 @@ int linux_main(int argc, char **argv) | |||
334 | add_arg(DEFAULT_COMMAND_LINE); | 334 | add_arg(DEFAULT_COMMAND_LINE); |
335 | 335 | ||
336 | os_early_checks(); | 336 | os_early_checks(); |
337 | if (force_tt) | ||
338 | clear_can_do_skas(); | ||
337 | mode_tt = force_tt ? 1 : !can_do_skas(); | 339 | mode_tt = force_tt ? 1 : !can_do_skas(); |
338 | #ifndef CONFIG_MODE_TT | 340 | #ifndef CONFIG_MODE_TT |
339 | if (mode_tt) { | 341 | if (mode_tt) { |