[PATCH 2/2] drm/xe/client: Skip show_run_ticks if unable to read timestamp

K V P, Satyanarayana satyanarayana.k.v.p at intel.com
Mon Feb 10 07:58:01 UTC 2025


Hi.
> -----Original Message-----
> From: Intel-xe <intel-xe-bounces at lists.freedesktop.org> On Behalf Of Marcin
> Bernatowicz
> Sent: Thursday, February 6, 2025 12:47 AM
> To: intel-xe at lists.freedesktop.org
> Cc: Marcin Bernatowicz <marcin.bernatowicz at linux.intel.com>; De Marchi,
> Lucas <lucas.demarchi at intel.com>; Wajdeczko, Michal
> <Michal.Wajdeczko at intel.com>; Winiarski, Michal
> <michal.winiarski at intel.com>; Nerlige Ramappa, Umesh
> <umesh.nerlige.ramappa at intel.com>
> Subject: [PATCH 2/2] drm/xe/client: Skip show_run_ticks if unable to read
> timestamp
> 
> RING_TIMESTAMP registers are inaccessible in VF mode.
> Without drm-total-cycles-*, other keys provide little value.
> Skip all optional "run_ticks" keys in this case.
> 
> Signed-off-by: Marcin Bernatowicz <marcin.bernatowicz at linux.intel.com>
> Cc: Lucas De Marchi <lucas.demarchi at intel.com>
> Cc: Michal Wajdeczko <michal.wajdeczko at intel.com>
> Cc: Michał Winiarski <michal.winiarski at intel.com>
> Cc: Umesh Nerlige Ramappa <umesh.nerlige.ramappa at intel.com>
> ---
LGTM.
Reviewed-by: Satyanarayana K V P <satyanarayana.k.v.p at intel.com>
>  drivers/gpu/drm/xe/xe_drm_client.c | 8 ++++++++
>  1 file changed, 8 insertions(+)
> 
> diff --git a/drivers/gpu/drm/xe/xe_drm_client.c
> b/drivers/gpu/drm/xe/xe_drm_client.c
> index 63f30b6df70b..848dc08beace 100644
> --- a/drivers/gpu/drm/xe/xe_drm_client.c
> +++ b/drivers/gpu/drm/xe/xe_drm_client.c
> @@ -324,6 +324,14 @@ static void show_run_ticks(struct drm_printer *p,
> struct drm_file *file)
>  	u64 gpu_timestamp;
>  	unsigned int fw_ref;
> 
> +	/*
> +	 * RING_TIMESTAMP registers are inaccessible in VF mode.
> +	 * Without drm-total-cycles-*, other keys provide little value.
> +	 * Show all or none of the optional "run_ticks" keys in this case.
> +	 */
> +	if (IS_SRIOV_VF(xe))
> +		return;
> +
>  	/*
>  	 * Wait for any exec queue going away: their cycles will get updated on
>  	 * context switch out, so wait for that to happen
> --
> 2.31.1



More information about the Intel-xe mailing list