]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/blobdiff - arch/arm64/kernel/process.c
arm64: cleanup {COMPAT_,}SET_PERSONALITY() macro
[mirror_ubuntu-artful-kernel.git] / arch / arm64 / kernel / process.c
index 659ae8094ed5b1bc3f0f1ae6c6b4297062725864..e6bf19c1dddb1d21fc3293ec8ed9e725a5c19466 100644 (file)
@@ -382,15 +382,12 @@ unsigned long get_wchan(struct task_struct *p)
                return 0;
 
        frame.fp = thread_saved_fp(p);
-       frame.sp = thread_saved_sp(p);
        frame.pc = thread_saved_pc(p);
 #ifdef CONFIG_FUNCTION_GRAPH_TRACER
        frame.graph = p->curr_ret_stack;
 #endif
        do {
-               if (frame.sp < stack_page ||
-                   frame.sp >= stack_page + THREAD_SIZE ||
-                   unwind_frame(p, &frame))
+               if (unwind_frame(p, &frame))
                        goto out;
                if (!in_sched_functions(frame.pc)) {
                        ret = frame.pc;
@@ -417,3 +414,11 @@ unsigned long arch_randomize_brk(struct mm_struct *mm)
        else
                return randomize_page(mm->brk, SZ_1G);
 }
+
+/*
+ * Called from setup_new_exec() after (COMPAT_)SET_PERSONALITY.
+ */
+void arch_setup_new_exec(void)
+{
+       current->mm->context.flags = is_compat_task() ? MMCF_AARCH32 : 0;
+}