]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
drm/panthor: Simplify getting the GPU model name
authorKarunika Choo <karunika.choo@arm.com>
Thu, 7 Aug 2025 16:26:28 +0000 (17:26 +0100)
committerSteven Price <steven.price@arm.com>
Fri, 15 Aug 2025 09:50:56 +0000 (10:50 +0100)
commitc012663b178c4e6fb0179c2816fb0a270f080b59
tree67bbc5c3462822e38e60e9cf29a4d121d67e93ab
parent94332524b5ccf9cfcb3c6184f1b9d6be65c6aad6
drm/panthor: Simplify getting the GPU model name

This patch replaces the panthor_model structure with a simple switch
case based on the product_id which is in the format of:
        ((arch_major << 24) | product_major)

This simplifies comparison and allows extending of the function to
accommodate naming differences based on supported GPU features.

Reviewed-by: Steven Price <steven.price@arm.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Liviu Dudau <liviu.dudau@arm.com>
Signed-off-by: Karunika Choo <karunika.choo@arm.com>
Signed-off-by: Steven Price <steven.price@arm.com>
Link: https://lore.kernel.org/r/20250807162633.3666310-3-karunika.choo@arm.com
drivers/gpu/drm/panthor/panthor_hw.c