[PATCH] drm/xe/mocs: Initialize MOCS index early
Balasubramani Vivekanandan
balasubramani.vivekanandan at intel.com
Tue May 20 14:24:45 UTC 2025
MOCS uc_index is used even before it is initialized in the following
callstack
guc_prepare_xfer()
__xe_guc_upload()
xe_guc_min_load_for_hwconfig()
xe_uc_init_hwconfig()
xe_gt_init_hwconfig()
Do MOCS index initialization earlier in the device probe.
Signed-off-by: Balasubramani Vivekanandan <balasubramani.vivekanandan at intel.com>
---
drivers/gpu/drm/xe/xe_gt.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/xe/xe_gt.c b/drivers/gpu/drm/xe/xe_gt.c
index 0e5d243c9451..858b5398c01b 100644
--- a/drivers/gpu/drm/xe/xe_gt.c
+++ b/drivers/gpu/drm/xe/xe_gt.c
@@ -417,6 +417,8 @@ int xe_gt_init_early(struct xe_gt *gt)
if (err)
return err;
+ xe_mocs_init_early(gt);
+
return 0;
}
@@ -634,8 +636,6 @@ int xe_gt_init(struct xe_gt *gt)
if (err)
return err;
- xe_mocs_init_early(gt);
-
err = xe_gt_sysfs_init(gt);
if (err)
return err;
--
2.34.1
More information about the Intel-xe
mailing list