From 68de550090e4990552aeff3f443c93320a0c8535 Mon Sep 17 00:00:00 2001 From: Stefan Kalkowski Date: Wed, 24 Apr 2024 15:59:30 +0200 Subject: [PATCH] hw: ignore stale data in fresh signal When a new signal arrives, which means a formerly non-pending one, we should ignore old signal numbers of that context, but only evaluate newly received data by the last kernel-call. Fix #5193 --- repos/base-hw/src/lib/base/signal_receiver.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/repos/base-hw/src/lib/base/signal_receiver.cc b/repos/base-hw/src/lib/base/signal_receiver.cc index e7040347ce..bb3415deda 100644 --- a/repos/base-hw/src/lib/base/signal_receiver.cc +++ b/repos/base-hw/src/lib/base/signal_receiver.cc @@ -146,7 +146,7 @@ void Signal_receiver::block_for_signal() if (!context->_pending) { /* update signal context */ Mutex::Guard context_guard(context->_mutex); - unsigned const num = context->_curr_signal.num + data->num; + unsigned const num = data->num; context->_pending = true; context->_curr_signal = Signal::Data(context, num); }