[Intel-xe] [PATCH 2/4] drm/xe: Rename MEM_SET instruction

Matt Roper matthew.d.roper at intel.com
Fri Sep 29 15:58:51 UTC 2023


On Thu, Sep 28, 2023 at 09:43:49PM -0700, Lucas De Marchi wrote:
> From: Haridhar Kalvala <haridhar.kalvala at intel.com>
> 
> PVC_MS_* doesn't reflect the real name of the instruction. Rename
> it to follow the nmae used in the bspec.

s/nmae/name/

otherwise,

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

> 
> Cc: Matt Roper <matthew.d.roper at intel.com>
> Signed-off-by: Haridhar Kalvala <haridhar.kalvala at intel.com>
> Signed-off-by: Lucas De Marchi <lucas.demarchi at intel.com>
> ---
>  drivers/gpu/drm/xe/regs/xe_gpu_commands.h | 6 +++---
>  drivers/gpu/drm/xe/xe_migrate.c           | 4 ++--
>  2 files changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/gpu/drm/xe/regs/xe_gpu_commands.h b/drivers/gpu/drm/xe/regs/xe_gpu_commands.h
> index 1ee8d46d92d9..1fdf2e4f1c9f 100644
> --- a/drivers/gpu/drm/xe/regs/xe_gpu_commands.h
> +++ b/drivers/gpu/drm/xe/regs/xe_gpu_commands.h
> @@ -60,10 +60,10 @@
>  
>  #define	PVC_MEM_SET_CMD		(2 << 29 | 0x5b << 22)
>  #define   PVC_MEM_SET_CMD_LEN_DW	7
> -#define   PVC_MS_MATRIX			REG_BIT(17)
> -#define   PVC_MS_DATA_FIELD		GENMASK(31, 24)
> +#define   PVC_MEM_SET_MATRIX		REG_BIT(17)
> +#define   PVC_MEM_SET_DATA_FIELD	GENMASK(31, 24)
>  /* Bspec lists field as [6:0], but index alone is from [6:1] */
> -#define   PVC_MS_MOCS_INDEX_MASK	GENMASK(6, 1)
> +#define   PVC_MEM_SET_MOCS_INDEX_MASK	GENMASK(6, 1)
>  
>  #define GFX_OP_PIPE_CONTROL(len)	((0x3<<29)|(0x3<<27)|(0x2<<24)|((len)-2))
>  
> diff --git a/drivers/gpu/drm/xe/xe_migrate.c b/drivers/gpu/drm/xe/xe_migrate.c
> index 1d1e4076b29d..2e6ce2daf414 100644
> --- a/drivers/gpu/drm/xe/xe_migrate.c
> +++ b/drivers/gpu/drm/xe/xe_migrate.c
> @@ -809,13 +809,13 @@ static void emit_clear_link_copy(struct xe_gt *gt, struct xe_bb *bb, u64 src_ofs
>  	u32 mocs = gt->mocs.uc_index;
>  	u32 len = PVC_MEM_SET_CMD_LEN_DW;
>  
> -	*cs++ = PVC_MEM_SET_CMD | PVC_MS_MATRIX | (len - 2);
> +	*cs++ = PVC_MEM_SET_CMD | PVC_MEM_SET_MATRIX | (len - 2);
>  	*cs++ = pitch - 1;
>  	*cs++ = (size / pitch) - 1;
>  	*cs++ = pitch - 1;
>  	*cs++ = lower_32_bits(src_ofs);
>  	*cs++ = upper_32_bits(src_ofs);
> -	*cs++ = FIELD_PREP(PVC_MS_MOCS_INDEX_MASK, mocs);
> +	*cs++ = FIELD_PREP(PVC_MEM_SET_MOCS_INDEX_MASK, mocs);
>  
>  	xe_gt_assert(gt, cs - bb->cs == len + bb->len);
>  
> -- 
> 2.40.1
> 

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


More information about the Intel-xe mailing list