]> git.hungrycats.org Git - linux/commitdiff
drm/amd/display: Fix harmless type mismatch in allocation
authorKees Cook <kees@kernel.org>
Thu, 3 Sep 2026 18:05:58 +0000 (11:05 -0700)
committerKees Cook <kees@kernel.org>
Fri, 4 Sep 2026 16:44:34 +0000 (09:44 -0700)
While converting to kmalloc_obj() API, a type assignment mismatch was
found between the desired struct dcn42_resource_pool and the allocated
struct dcn401_resource_pool. Fix the type (it is harmless: the objects
have the same contents and size).

Signed-off-by: Kees Cook <kees@kernel.org>
---
Cc: Harry Wentland <harry.wentland@amd.com>
Cc: Leo Li <sunpeng.li@amd.com>
Cc: Rodrigo Siqueira <siqueira@igalia.com>
Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: "Christian König" <christian.koenig@amd.com>
Cc: David Airlie <airlied@gmail.com>
Cc: Simona Vetter <simona@ffwll.ch>
Cc: Dan Wheeler <daniel.wheeler@amd.com>
Cc: Roman Li <Roman.Li@amd.com>
Cc: Ovidiu Bunea <ovidiu.bunea@amd.com>
Cc: Charlene Liu <Charlene.Liu@amd.com>
Cc: Leo Chen <leo.chen@amd.com>
Cc: Ivan Lipski <ivan.lipski@amd.com>
Cc: Gaghik Khachatrian <gaghik.khachatrian@amd.com>
Cc: <amd-gfx@lists.freedesktop.org>
Cc: <dri-devel@lists.freedesktop.org>
drivers/gpu/drm/amd/display/dc/resource/dcn42/dcn42_resource.c

index 6370d3903eb52f65e270049986e1ae56181c7190..b93d608b64a930cfc5a94ff4cb9030759dd15303 100644 (file)
@@ -2441,7 +2441,7 @@ struct resource_pool *dcn42_create_resource_pool(
        struct dc *dc)
 {
        struct dcn42_resource_pool *pool =
-               kzalloc(sizeof(struct dcn401_resource_pool), GFP_KERNEL);
+               kzalloc(sizeof(struct dcn42_resource_pool), GFP_KERNEL);
 
        if (!pool)
                return NULL;