Commit a1850e9c authored by Richard Weinberger's avatar Richard Weinberger

um: Get rid of thread_struct->saved_task

As we have a sane show_stack() now, we can drop
the ->saved_task hack.
Signed-off-by: default avatarRichard Weinberger <richard@nod.at>
parent f72c22e4
...@@ -645,11 +645,9 @@ void mconsole_sysrq(struct mc_request *req) ...@@ -645,11 +645,9 @@ void mconsole_sysrq(struct mc_request *req)
static void stack_proc(void *arg) static void stack_proc(void *arg)
{ {
struct task_struct *from = current, *to = arg; struct task_struct *task = arg;
to->thread.saved_task = from; show_stack(task, NULL);
rcu_user_hooks_switch(from, to);
switch_to(from, to, from);
} }
/* /*
......
...@@ -19,7 +19,6 @@ struct task_struct; ...@@ -19,7 +19,6 @@ struct task_struct;
struct mm_struct; struct mm_struct;
struct thread_struct { struct thread_struct {
struct task_struct *saved_task;
struct pt_regs regs; struct pt_regs regs;
struct pt_regs *segv_regs; struct pt_regs *segv_regs;
int singlestep_syscall; int singlestep_syscall;
......
...@@ -82,19 +82,8 @@ void *__switch_to(struct task_struct *from, struct task_struct *to) ...@@ -82,19 +82,8 @@ void *__switch_to(struct task_struct *from, struct task_struct *to)
to->thread.prev_sched = from; to->thread.prev_sched = from;
set_current(to); set_current(to);
do { switch_threads(&from->thread.switch_buf, &to->thread.switch_buf);
current->thread.saved_task = NULL; arch_switch_to(current);
switch_threads(&from->thread.switch_buf,
&to->thread.switch_buf);
arch_switch_to(current);
if (current->thread.saved_task)
show_regs(&(current->thread.regs));
to = current->thread.saved_task;
from = current;
} while (current->thread.saved_task);
return current->thread.prev_sched; return current->thread.prev_sched;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment