mirror of
https://github.com/Mathewnd/Astral.git
synced 2026-10-27 12:48:22 +00:00
dpc: make dpc queues FIFO
This commit is contained in:
@@ -5,8 +5,7 @@
|
||||
|
||||
|
||||
static void isrfn(isr_t *self, context_t *context) {
|
||||
list_node_t *node;
|
||||
while ((node = list_pop_front(¤t_cpu()->dpcqueue)) != NULL) {
|
||||
list_drain_front (¤t_cpu()->dpcqueue, node) {
|
||||
dpc_t *dpc = (dpc_t *)node;
|
||||
dpcarg_t arg = dpc->arg;
|
||||
|
||||
@@ -34,7 +33,7 @@ void dpc_enqueue(dpc_t *dpc, dpcarg_t arg) {
|
||||
|
||||
dpc->arg = arg;
|
||||
dpc->enqueued = true;
|
||||
list_push_front(¤t_cpu()->dpcqueue, &dpc->list_node);
|
||||
list_push_back(¤t_cpu()->dpcqueue, &dpc->list_node);
|
||||
interrupt_raise(current_cpu()->dpcisr);
|
||||
|
||||
cleanup:
|
||||
|
||||
Reference in New Issue
Block a user