[PATCH v2 2/2] lib: sbi: pmu: Remove MIP clearing from pmu_sse_enable()

Clément Léger cleger at rivosinc.com
Mon May 19 01:39:49 PDT 2025


Clearing MIP at that point means that we can probably lose a pending
interrupt. This should not happen, remove MIP clearing from there.

Signed-off-by: Clément Léger <cleger at rivosinc.com>
---
 lib/sbi/sbi_pmu.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/lib/sbi/sbi_pmu.c b/lib/sbi/sbi_pmu.c
index dee50b9b..50476d7a 100644
--- a/lib/sbi/sbi_pmu.c
+++ b/lib/sbi/sbi_pmu.c
@@ -1099,7 +1099,6 @@ static void pmu_sse_enable(uint32_t event_id)
 {
 	unsigned long irq_mask = sbi_pmu_irq_mask();
 
-	csr_clear(CSR_MIP, irq_mask);
 	csr_set(CSR_MIE, irq_mask);
 }
 
-- 
2.49.0




More information about the opensbi mailing list