We want to extend our macro-based KLV list definitions with new information about the version from which given KLV is supported.
Instead of using magic version like 0.0.0 for legacy KLVs, add utility IF_ARGS macro that can be used in code generators to emit different code based on the presence of any additional arguments. This series cherry-picks one patch from the EGS series [1] and can be merged separately. v1: https://patchwork.freedesktop.org/series/158874/#rev1 v2: https://patchwork.freedesktop.org/series/158874/#rev2 new patch with GUC_FIRMWARE_VER_AT_LEAST macro v3: alternate implementation of IF_ARGS macro for older GCC as kernel test robot reported errors on GCC 8.5.0 and same errors were seen locally on 9.5.0 but not on 10.1.0 Cc: Thomas Hellström <[email protected]> Cc: Rodrigo Vivi <[email protected]> Cc: Matthew Brost <[email protected]> Cc: Daniele Ceraolo Spurio <[email protected]> [1] https://patchwork.freedesktop.org/series/158142/#rev3 Daniele Ceraolo Spurio (1): drm/xe/pf: Add handling for MLRC adverse event threshold Michal Wajdeczko (3): drm/xe: Introduce IF_ARGS macro utility drm/xe/guc: Introduce GUC_FIRMWARE_VER_AT_LEAST helper drm/xe/pf: Prepare for new threshold KLVs drivers/gpu/drm/xe/abi/guc_klvs_abi.h | 9 ++++ drivers/gpu/drm/xe/tests/xe_args_test.c | 54 +++++++++++++++++++ drivers/gpu/drm/xe/xe_args.h | 27 ++++++++++ drivers/gpu/drm/xe/xe_gt_sriov_pf_config.c | 19 ++++--- drivers/gpu/drm/xe/xe_gt_sriov_pf_debugfs.c | 9 ++-- drivers/gpu/drm/xe/xe_gt_sriov_pf_migration.c | 2 +- drivers/gpu/drm/xe/xe_guc.h | 21 ++++++++ drivers/gpu/drm/xe/xe_guc_ads.c | 4 +- .../drm/xe/xe_guc_klv_thresholds_set_types.h | 6 +++ 9 files changed, 138 insertions(+), 13 deletions(-) -- 2.47.1
