From e8effb194eb35716aac3859b0fd217b3f4064dfc Mon Sep 17 00:00:00 2001 From: Michael Shaw Date: Wed, 12 Aug 2026 15:38:24 -0400 Subject: [PATCH] list: switch lock to mtx Signed-off-by: Michael Shaw --- include/lib/list.h | 2 +- lib/list.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/include/lib/list.h b/include/lib/list.h index 6d9128b..d8fbaee 100644 --- a/include/lib/list.h +++ b/include/lib/list.h @@ -17,7 +17,7 @@ typedef struct _list_item { typedef struct _list_head { struct _list_item *head; struct _list_item *tail; - spinlock_t lock; + mtx_t lock; } list_t; void list_create(list_t *list); diff --git a/lib/list.c b/lib/list.c index fb6a542..2e830cf 100644 --- a/lib/list.c +++ b/lib/list.c @@ -1,5 +1,5 @@ /* SPDX-License-Identifier: GPL-2.0-only */ -#include +#include #include #include #include @@ -67,12 +67,12 @@ void list_remove(list_item_t *item) void list_lock(list_t *list) { - spinlock_acquire(&list->lock); + mtx_lock(&list->lock); } void list_unlock(list_t *list) { - spinlock_release(&list->lock); + mtx_unlock(&list->lock); } void list_init()