From 065691e299eeba4f01dc6574e560aef618bad22c Mon Sep 17 00:00:00 2001 From: Eric Engestrom Date: Wed, 27 Jul 2022 16:49:18 +0100 Subject: [PATCH] nouveau: use existing list_first_entry() macro instead of re-writing it Signed-off-by: Eric Engestrom Acked-by: David Heidelberg Reviewed-by: Yonggang Luo Part-of: --- src/gallium/drivers/nouveau/nv30/nv30_query.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/gallium/drivers/nouveau/nv30/nv30_query.c b/src/gallium/drivers/nouveau/nv30/nv30_query.c index 6a4665e5f51..1335cb99b12 100644 --- a/src/gallium/drivers/nouveau/nv30/nv30_query.c +++ b/src/gallium/drivers/nouveau/nv30/nv30_query.c @@ -28,9 +28,6 @@ #include "nv30/nv30_screen.h" #include "nv30/nv30_context.h" -#define LIST_FIRST_ENTRY(__item, __type, __field) \ - list_entry((__item)->next, __type, __field) - struct nv30_query_object { struct list_head list; struct nouveau_heap *hw; @@ -76,7 +73,7 @@ nv30_query_object_new(struct nv30_screen *screen) * spin waiting for one to become free */ while (nouveau_heap_alloc(screen->query_heap, 32, NULL, &qo->hw)) { - oq = LIST_FIRST_ENTRY(&screen->queries, struct nv30_query_object, list); + oq = list_first_entry(&screen->queries, struct nv30_query_object, list); nv30_query_object_del(screen, &oq); }