[PATCH 1/3] drm/xe/guc: Rename CT state change helper
Cavitt, Jonathan
jonathan.cavitt at intel.com
Wed Jul 9 19:07:17 UTC 2025
-----Original Message-----
From: Intel-xe <intel-xe-bounces at lists.freedesktop.org> On Behalf Of Michal Wajdeczko
Sent: Wednesday, July 9, 2025 10:41 AM
To: intel-xe at lists.freedesktop.org
Cc: Wajdeczko, Michal <Michal.Wajdeczko at intel.com>; Brost, Matthew <matthew.brost at intel.com>
Subject: [PATCH 1/3] drm/xe/guc: Rename CT state change helper
>
> In this helper we are already doing much more than just setting
> a new CT state and its name was little misleading. Rename it.
>
> Signed-off-by: Michal Wajdeczko <michal.wajdeczko at intel.com>
> Cc: Matthew Brost <matthew.brost at intel.com>
LGTM. I don't know if it's quite right to remove the xe_ tag from the
function here, but I'll trust your judgement on this because it doesn't
hurt any.
Reviewed-by: Jonathan Cavitt <jonathan.cavitt at intel.com>
-Jonathan Cavitt
> ---
> drivers/gpu/drm/xe/xe_guc_ct.c | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/gpu/drm/xe/xe_guc_ct.c b/drivers/gpu/drm/xe/xe_guc_ct.c
> index 23e8c155025e..2a052dc22ff2 100644
> --- a/drivers/gpu/drm/xe/xe_guc_ct.c
> +++ b/drivers/gpu/drm/xe/xe_guc_ct.c
> @@ -384,7 +384,7 @@ static int guc_ct_control_toggle(struct xe_guc_ct *ct, bool enable)
> return ret > 0 ? -EPROTO : ret;
> }
>
> -static void xe_guc_ct_set_state(struct xe_guc_ct *ct,
> +static void guc_ct_change_state(struct xe_guc_ct *ct,
> enum xe_guc_ct_state state)
> {
> mutex_lock(&ct->lock); /* Serialise dequeue_one_g2h() */
> @@ -469,7 +469,7 @@ int xe_guc_ct_enable(struct xe_guc_ct *ct)
> if (err)
> goto err_out;
>
> - xe_guc_ct_set_state(ct, XE_GUC_CT_STATE_ENABLED);
> + guc_ct_change_state(ct, XE_GUC_CT_STATE_ENABLED);
>
> smp_mb();
> wake_up_all(&ct->wq);
> @@ -514,7 +514,7 @@ static void stop_g2h_handler(struct xe_guc_ct *ct)
> */
> void xe_guc_ct_disable(struct xe_guc_ct *ct)
> {
> - xe_guc_ct_set_state(ct, XE_GUC_CT_STATE_DISABLED);
> + guc_ct_change_state(ct, XE_GUC_CT_STATE_DISABLED);
> ct_exit_safe_mode(ct);
> stop_g2h_handler(ct);
> }
> @@ -530,7 +530,7 @@ void xe_guc_ct_stop(struct xe_guc_ct *ct)
> if (!xe_guc_ct_initialized(ct))
> return;
>
> - xe_guc_ct_set_state(ct, XE_GUC_CT_STATE_STOPPED);
> + guc_ct_change_state(ct, XE_GUC_CT_STATE_STOPPED);
> stop_g2h_handler(ct);
> }
>
> --
> 2.47.1
>
>
More information about the Intel-xe
mailing list