]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
drm/xe/pat: Introduce xe_cache_pat_idx() macro helper
authorXin Wang <x.wang@intel.com>
Thu, 16 Apr 2026 04:55:26 +0000 (21:55 -0700)
committerMatt Roper <matthew.d.roper@intel.com>
Tue, 21 Apr 2026 17:20:17 +0000 (10:20 -0700)
commitdc9ccf14dc2ad44e3df4928015923735f0101bfd
tree30267ee07b5456daf3b2f610e60976b8bd1f0382
parent369738a43a62c6ee46033ed1a26ed7d08c0e4b68
drm/xe/pat: Introduce xe_cache_pat_idx() macro helper

Wrap pat.idx[] reads with xe_cache_pat_idx() so invalid PAT index use
is caught by xe_assert() in debug builds.

Suggested-by: Matthew Auld <matthew.auld@intel.com>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
Signed-off-by: Xin Wang <x.wang@intel.com>
Link: https://patch.msgid.link/20260416045526.536497-4-x.wang@intel.com
Signed-off-by: Matt Roper <matthew.d.roper@intel.com>
drivers/gpu/drm/xe/display/xe_fb_pin.c
drivers/gpu/drm/xe/tests/xe_migrate.c
drivers/gpu/drm/xe/xe_ggtt.c
drivers/gpu/drm/xe/xe_migrate.c
drivers/gpu/drm/xe/xe_pat.h
drivers/gpu/drm/xe/xe_pt.c
drivers/gpu/drm/xe/xe_vm.c