]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
drm/xe: Introduce IF_ARGS macro utility
authorMichal Wajdeczko <michal.wajdeczko@intel.com>
Wed, 17 Dec 2025 22:40:18 +0000 (23:40 +0100)
committerMichal Wajdeczko <michal.wajdeczko@intel.com>
Wed, 17 Dec 2025 22:42:40 +0000 (23:42 +0100)
commitce5971773651ad5c7e26aea29d72ea8887428774
treeed611728f5d70a08abadb2b11a5fc47fb0c7e845
parent2f9405aaa4297f95b42c39779e24f74587a0b6bc
drm/xe: Introduce IF_ARGS macro utility

We want to extend our macro-based KLV list definitions with new
information about the version from which given KLV is supported.
Add utility IF_ARGS macro that can be used in code generators to
emit different code based on the presence of additional arguments.

Introduce macro itself and extend our kunit tests to cover it.
We will use this macro in next patch.

Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
Reviewed-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Acked-by: Matthew Brost <matthew.brost@intel.com>
Link: https://patch.msgid.link/20251217224018.3490-1-michal.wajdeczko@intel.com
drivers/gpu/drm/xe/tests/xe_args_test.c
drivers/gpu/drm/xe/xe_args.h