Andreas Kling
b2e502e533
Kernel: Add Thread::block_until(Condition).
...
Replace the class-based snooze alarm mechanism with a per-thread callback.
This makes it easy to block the current thread on an arbitrary condition:
void SomeDevice::wait_for_irq() {
m_interrupted = false;
current->block_until([this] { return m_interrupted; });
}
void SomeDevice::handle_irq() {
m_interrupted = true;
}
Use this in the SB16 driver, and in NetworkTask :^)
2019-07-14 14:54:54 +02:00
..
2019-07-09 15:04:45 +02:00
2019-06-02 09:53:42 +02:00
2019-07-14 14:54:54 +02:00
2019-07-11 15:40:04 +02:00
2019-07-14 14:54:54 +02:00
2019-07-03 21:20:13 +02:00
2019-07-11 15:40:04 +02:00
2019-03-27 13:02:29 +01:00
2019-06-30 10:41:26 +02:00
2019-05-28 17:31:20 +02:00
2019-06-07 20:02:01 +02:00
2019-06-04 07:15:44 -07:00
2019-07-03 16:57:37 +02:00
2019-07-13 17:05:16 +02:00
2019-07-03 21:20:13 +02:00
2019-07-03 21:20:13 +02:00
2019-07-03 21:20:13 +02:00
2019-07-03 21:20:13 +02:00
2019-07-03 21:20:13 +02:00
2019-07-03 21:20:13 +02:00
2019-06-04 07:14:40 -07:00
2019-07-13 08:00:24 +02:00
2019-05-17 21:59:48 +02:00
2019-07-13 08:00:24 +02:00
2019-07-09 15:04:43 +02:00
2019-07-03 21:20:13 +02:00
2019-07-03 21:20:13 +02:00
2019-07-03 21:20:13 +02:00
2019-07-03 21:20:13 +02:00
2019-06-04 07:08:07 -07:00
2019-06-07 11:43:58 +02:00
2019-06-22 22:45:16 +02:00
2019-06-14 06:24:02 +02:00
2019-06-22 21:21:57 +02:00
2019-07-03 21:20:13 +02:00
2019-07-03 21:20:13 +02:00
2019-04-01 21:43:07 +02:00
2019-07-03 21:20:13 +02:00
2019-07-13 22:58:36 +02:00
2019-07-13 08:00:24 +02:00
2019-04-30 14:47:22 +02:00
2019-07-03 21:20:13 +02:00
2019-07-03 21:20:13 +02:00
2019-07-03 21:20:13 +02:00
2019-07-03 21:20:13 +02:00
2019-07-14 11:35:49 +02:00
2019-07-14 11:35:49 +02:00
2019-07-03 21:20:13 +02:00
2019-07-09 15:04:45 +02:00
2019-07-03 21:20:13 +02:00
2019-05-28 17:31:20 +02:00
2019-07-13 08:00:24 +02:00
2019-07-14 14:54:54 +02:00
2019-07-03 21:20:13 +02:00
2019-07-03 21:20:13 +02:00
2019-07-03 21:20:13 +02:00
2019-06-04 07:15:44 -07:00
2019-07-08 20:01:49 +02:00
2019-07-08 20:01:49 +02:00
2019-07-14 14:54:54 +02:00
2019-07-14 14:54:54 +02:00
2019-07-14 11:35:49 +02:00