diff options
author | Paul Mundt <lethal@linux-sh.org> | 2007-09-28 15:48:06 +0900 |
---|---|---|
committer | Paul Mundt <lethal@linux-sh.org> | 2007-09-28 15:48:06 +0900 |
commit | 995bb781d42441ed48517bc7ea6414c3df3386ef (patch) | |
tree | bfaa11ab14a3d230bb8502f720402608d3f818dd /arch/sh/kernel/process.c | |
parent | e5137682a1ad48bc5306070935c277e262f119ef (diff) | |
download | blackbird-op-linux-995bb781d42441ed48517bc7ea6414c3df3386ef.tar.gz blackbird-op-linux-995bb781d42441ed48517bc7ea6414c3df3386ef.zip |
sh: Follow gUSA preempt changes in __switch_to().
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh/kernel/process.c')
-rw-r--r-- | arch/sh/kernel/process.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/sh/kernel/process.c b/arch/sh/kernel/process.c index 15ae322dbd74..cd8dae16e940 100644 --- a/arch/sh/kernel/process.c +++ b/arch/sh/kernel/process.c @@ -19,6 +19,7 @@ #include <linux/tick.h> #include <linux/reboot.h> #include <linux/fs.h> +#include <linux/preempt.h> #include <asm/uaccess.h> #include <asm/mmu_context.h> #include <asm/pgalloc.h> @@ -351,10 +352,9 @@ struct task_struct *__switch_to(struct task_struct *prev, #ifdef CONFIG_PREEMPT { - unsigned long flags; struct pt_regs *regs; - local_irq_save(flags); + preempt_disable(); regs = task_pt_regs(prev); if (user_mode(regs) && regs->regs[15] >= 0xc0000000) { int offset = (int)regs->regs[15]; @@ -365,7 +365,7 @@ struct task_struct *__switch_to(struct task_struct *prev, /* Go to rewind point */ regs->pc = regs->regs[0] + offset; } - local_irq_restore(flags); + preempt_enable_no_resched(); } #endif |