mirror of
https://github.com/genodelabs/genode.git
synced 2025-03-22 03:55:26 +00:00
Defer 'wait_for_irq' until device irq is cleared
This commit is contained in:
parent
f279a1df00
commit
daf4300dcb
@ -21,6 +21,7 @@ extern "C" {
|
||||
|
||||
/* our local incarnation of sender and receiver */
|
||||
static Signal_helper *_signal = 0;
|
||||
static Genode::Lock _irq_ack_lock(Genode::Lock::LOCKED);
|
||||
|
||||
|
||||
/**
|
||||
@ -74,6 +75,8 @@ class Irq_context : public Driver_context,
|
||||
/* set context & submit signal */
|
||||
_signal->sender()->context(ctx->_ctx_cap);
|
||||
_signal->sender()->submit();
|
||||
|
||||
_irq_ack_lock.lock();
|
||||
}
|
||||
|
||||
public:
|
||||
@ -101,9 +104,10 @@ class Irq_context : public Driver_context,
|
||||
dde_kit_log(DEBUG_IRQ, "IRQ: %u ret: %u %p", _irq, rc, h->handler);
|
||||
if (rc == IRQ_HANDLED) {
|
||||
Routine::schedule_all();
|
||||
return;
|
||||
break;
|
||||
}
|
||||
}
|
||||
_irq_ack_lock.unlock();
|
||||
}
|
||||
|
||||
const char *debug() { return "Irq_context"; }
|
||||
|
Loading…
x
Reference in New Issue
Block a user