drm/xe/lnl: Hook up MOCS table
authorBalasubramani Vivekanandan <balasubramani.vivekanandan@intel.com>
Fri, 11 Aug 2023 16:06:18 +0000 (09:06 -0700)
committerRodrigo Vivi <rodrigo.vivi@intel.com>
Thu, 21 Dec 2023 16:40:26 +0000 (11:40 -0500)
LNL uses the Xe2 MOCS table introduced in an earlier patch.

Bspec: 71582
Cc: Matt Roper <matthew.d.roper@intel.com>
Signed-off-by: Balasubramani Vivekanandan <balasubramani.vivekanandan@intel.com>
Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>
Reviewed-by: Matt Roper <matthew.d.roper@intel.com>
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
drivers/gpu/drm/xe/xe_mocs.c

index c120090ef9b40c692d789dd35cb461ec127b6a6e..75d025c54eb849d1d185cc651934c82ff1cff307 100644 (file)
@@ -395,6 +395,14 @@ static unsigned int get_mocs_settings(struct xe_device *xe,
        memset(info, 0, sizeof(struct xe_mocs_info));
 
        switch (xe->info.platform) {
+       case XE_LUNARLAKE:
+               info->size = ARRAY_SIZE(xe2_mocs_table);
+               info->table = xe2_mocs_table;
+               info->n_entries = XE2_NUM_MOCS_ENTRIES;
+               info->uc_index = 3;
+               info->wb_index = 1;
+               info->unused_entries_index = 1;
+               break;
        case XE_PVC:
                info->size = ARRAY_SIZE(pvc_mocs_desc);
                info->table = pvc_mocs_desc;