[Intel-xe] [PATCH 15/15] drm/xe/lnl: Hook up MOCS table

Matt Roper matthew.d.roper at intel.com
Fri Aug 11 16:22:18 UTC 2023


On Fri, Aug 11, 2023 at 09:06:18AM -0700, Lucas De Marchi wrote:
> From: Balasubramani Vivekanandan <balasubramani.vivekanandan at intel.com>
> 
> LNL uses the Xe2 MOCS table introduced in an earlier patch.
> 
> Bspec: 71582
> Cc: Matt Roper <matthew.d.roper at intel.com>
> Signed-off-by: Balasubramani Vivekanandan <balasubramani.vivekanandan at intel.com>
> Signed-off-by: Lucas De Marchi <lucas.demarchi at intel.com>

Reviewed-by: Matt Roper <matthew.d.roper at intel.com>

> ---
>  drivers/gpu/drm/xe/xe_mocs.c | 8 ++++++++
>  1 file changed, 8 insertions(+)
> 
> diff --git a/drivers/gpu/drm/xe/xe_mocs.c b/drivers/gpu/drm/xe/xe_mocs.c
> index d779ab8466d32..38d3e4ec9f445 100644
> --- a/drivers/gpu/drm/xe/xe_mocs.c
> +++ b/drivers/gpu/drm/xe/xe_mocs.c
> @@ -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;
> -- 
> 2.40.1
> 

-- 
Matt Roper
Graphics Software Engineer
Linux GPU Platform Enablement
Intel Corporation


More information about the Intel-xe mailing list