hc
2024-02-20 102a0743326a03cd1a1202ceda21e175b7d3575c
kernel/arch/powerpc/kernel/hw_breakpoint.c
....@@ -479,11 +479,13 @@
479479 struct arch_hw_breakpoint *info;
480480 int i;
481481
482
+ preempt_disable();
483
+
482484 for (i = 0; i < nr_wp_slots(); i++) {
483485 if (unlikely(tsk->thread.last_hit_ubp[i]))
484486 goto reset;
485487 }
486
- return;
488
+ goto out;
487489
488490 reset:
489491 regs->msr &= ~MSR_SE;
....@@ -492,6 +494,9 @@
492494 __set_breakpoint(i, info);
493495 tsk->thread.last_hit_ubp[i] = NULL;
494496 }
497
+
498
+out:
499
+ preempt_enable();
495500 }
496501
497502 static bool is_larx_stcx_instr(int type)