Skip to contentSkip to conversation

x86: dovetail: Drop bogus local_irq_disable_full from __bad_area_nosemaphore

PATCH Applied Jan Kiszka 2 participants 2 messages Nov 12 – Nov 18

Subsystems (2)
lore
Share & tools
lore

Jan Kiszka

author
#0 lore raw

PATCH v2 1/1 x86: dovetail: Drop bogus local_irq_disable_full from __bad_area_nosemaphore

From: Jan Kiszka <[email protected]>

Upstream commit 614da1d3d4cd ("x86: make page fault handling disable interrupts properly") moved the local_irq_disable out of __bad_area_nosemaphore into handle_page_fault. At this point, our previous conversion of local_irq_disable to local_irq_disable_full became stale. When commit 614da1d3d4cd was backported to stable trees, this was noticed and resolved, but 6.19+ still kept it, incorrectly.

---

Changes in v2:
- clarify the history of upstream and dovetail changes

 arch/x86/mm/fault.c | 2 --
 1 file changed, 2 deletions(-)
arch/x86/mm/fault.c +0 -2
index e41ed2092730c..e9a08a5d26e60 100644
@@ -886,8 +886,6 @@ __bad_area_nosemaphore(struct pt_regs *regs, unsigned long error_code,
 		force_sig_pkuerr((void __user *)address, pkey);
 	else
 		force_sig_fault(SIGSEGV, si_code, (void __user *)address);
-
-	local_irq_disable_full();
 out:
 	oob_trap_unwind(X86_TRAP_PF, regs);
 }
Signature · 1 line
2.47.3
#1 lore raw
Quoted 23 lines · Jan Kiszka

From: Jan Kiszka <[email protected]>

Upstream commit 614da1d3d4cd ("x86: make page fault handling disable interrupts properly") moved the local_irq_disable out of __bad_area_nosemaphore into handle_page_fault. At this point, our previous conversion of local_irq_disable to local_irq_disable_full became stale. When commit 614da1d3d4cd was backported to stable trees, this was noticed and resolved, but 6.19+ still kept it, incorrectly.

---

Changes in v2:
- clarify the history of upstream and dovetail changes

 arch/x86/mm/fault.c | 2 --
 1 file changed, 2 deletions(-)
arch/x86/mm/fault.c +0 -0
index e41ed2092730c..e9a08a5d26e60 100644

arch/x86/mm/fault.c __bad_area_nosemaphore(struct pt_regs *regs, unsigned long error_code, · line 891

Quoted 8 lines
arch/x86/mm/fault.c +0 -2
@@ -886,8 +886,6 @@ __bad_area_nosemaphore(struct pt_regs *regs, unsigned long error_code,
 		force_sig_pkuerr((void __user *)address, pkey);
 	else
 		force_sig_fault(SIGSEGV, si_code, (void __user *)address);
-
-	local_irq_disable_full();
 out:
 	oob_trap_unwind(X86_TRAP_PF, regs);
 }

Merged, thanks.

Signature · 1 line
Philippe.