Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drm/xe/pmu: Assert max gt

XE_PMU_MAX_GT needs to be used due to a circular dependency, but we
should make sure it doesn't go out of sync with XE_PMU_MAX_GT. Add a
compile check for that.

Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20250124050411.2189060-2-lucas.demarchi@intel.com
Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>

+2
+2
drivers/gpu/drm/xe/xe_pmu.c
··· 249 249 int ret = -ENOMEM; 250 250 char *name; 251 251 252 + BUILD_BUG_ON(XE_MAX_GT_PER_TILE != XE_PMU_MAX_GT); 253 + 252 254 if (IS_SRIOV_VF(xe)) 253 255 return 0; 254 256