summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--arch/tile/mm/fault.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/arch/tile/mm/fault.c b/arch/tile/mm/fault.c
index a1da473c855..22e58f51ed2 100644
--- a/arch/tile/mm/fault.c
+++ b/arch/tile/mm/fault.c
@@ -342,9 +342,12 @@ static int handle_page_fault(struct pt_regs *regs,
/*
* If we're trying to touch user-space addresses, we must
* be either at PL0, or else with interrupts enabled in the
- * kernel, so either way we can re-enable interrupts here.
+ * kernel, so either way we can re-enable interrupts here
+ * unless we are doing atomic access to user space with
+ * interrupts disabled.
*/
- local_irq_enable();
+ if (!(regs->flags & PT_FLAGS_DISABLE_IRQ))
+ local_irq_enable();
mm = tsk->mm;