[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20250902090511.2447679-1-xialonglong@kylinos.cn>
Date: Tue, 2 Sep 2025 17:05:11 +0800
From: Longlong Xia <xialonglong@...inos.cn>
To: yuq825@...il.com,
maarten.lankhorst@...ux.intel.com
Cc: dri-devel@...ts.freedesktop.org,
lima@...ts.freedesktop.org,
linux-kernel@...r.kernel.org,
Longlong Xia <xialonglong@...inos.cn>
Subject: [PATCH 1/1] drm/sched: Use KMEM_CACHE instead of kmem_cache_create
Use KMEM_CACHE() instead of kmem_cache_create() to simplify the code.
Signed-off-by: Longlong Xia <xialonglong@...inos.cn>
---
drivers/gpu/drm/lima/lima_sched.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/lima/lima_sched.c b/drivers/gpu/drm/lima/lima_sched.c
index 739e8c6c6d90..b079ac198d59 100644
--- a/drivers/gpu/drm/lima/lima_sched.c
+++ b/drivers/gpu/drm/lima/lima_sched.c
@@ -28,9 +28,7 @@ static int lima_fence_slab_refcnt;
int lima_sched_slab_init(void)
{
if (!lima_fence_slab) {
- lima_fence_slab = kmem_cache_create(
- "lima_fence", sizeof(struct lima_fence), 0,
- SLAB_HWCACHE_ALIGN, NULL);
+ lima_fence_slab = KMEM_CACHE(lima_fence, SLAB_HWCACHE_ALIGN);
if (!lima_fence_slab)
return -ENOMEM;
}
--
2.43.0
Powered by blists - more mailing lists