mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 03:01:39 -04:00
[PATCH] s390: in_interrupt vs. in_atomic
The condition for no context in do_exception checks for hard and soft interrupts by using in_interrupt() but not for preemption. This is bad for the users of __copy_from/to_user_inatomic because the fault handler might call schedule although the preemption count is != 0. Use in_atomic() instead in_interrupt(). Signed-off-by: Martin Schwidefsky <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
c5c3a6d8fe
commit
595bf2aaca
1 changed files with 1 additions and 1 deletions
|
|
@ -207,7 +207,7 @@ do_exception(struct pt_regs *regs, unsigned long error_code, int is_protection)
|
|||
* we are not in an interrupt and that there is a
|
||||
* user context.
|
||||
*/
|
||||
if (user_address == 0 || in_interrupt() || !mm)
|
||||
if (user_address == 0 || in_atomic() || !mm)
|
||||
goto no_context;
|
||||
|
||||
/*
|
||||
|
|
|
|||
Loading…
Reference in a new issue