> -----Original Message-----
> From: Intel-xe <intel-xe-boun...@lists.freedesktop.org> On Behalf Of Jani
> Nikula
> Sent: Friday, February 7, 2025 3:48 PM
> To: intel-gfx@lists.freedesktop.org; intel...@lists.freedesktop.org
> Cc: Nikula, Jani <jani.nik...@intel.com>
> Subject: [PATCH 3/3] drm/i915/pch: Remove unused i915->pch_id
> 
> With the PCH checks based on PCH types instead of IDs, the i915->pch_id
> member has become unused. Remove it.
> 
> Signed-off-by: Jani Nikula <jani.nik...@intel.com>

LGTM,
Reviewed-by: Nemesa Garg <nemesa.g...@intel.com>
> ---
>  drivers/gpu/drm/i915/i915_drv.h      | 1 -
>  drivers/gpu/drm/i915/soc/intel_pch.c | 4 ----
> drivers/gpu/drm/xe/xe_device_types.h | 1 -
>  3 files changed, 6 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/i915_drv.h
> b/drivers/gpu/drm/i915/i915_drv.h index b96b8de12756..ffc346379cc2
> 100644
> --- a/drivers/gpu/drm/i915/i915_drv.h
> +++ b/drivers/gpu/drm/i915/i915_drv.h
> @@ -274,7 +274,6 @@ struct drm_i915_private {
> 
>       /* PCH chipset type */
>       enum intel_pch pch_type;
> -     unsigned short pch_id;
> 
>       unsigned long gem_quirks;
> 
> diff --git a/drivers/gpu/drm/i915/soc/intel_pch.c
> b/drivers/gpu/drm/i915/soc/intel_pch.c
> index fa03b5068a19..82dc7fbd1a3e 100644
> --- a/drivers/gpu/drm/i915/soc/intel_pch.c
> +++ b/drivers/gpu/drm/i915/soc/intel_pch.c
> @@ -286,13 +286,11 @@ void intel_detect_pch(struct drm_i915_private
> *dev_priv)
>               pch_type = intel_pch_type(dev_priv, id);
>               if (pch_type != PCH_NONE) {
>                       dev_priv->pch_type = pch_type;
> -                     dev_priv->pch_id = id;
>                       break;
>               } else if (intel_is_virt_pch(id, pch->subsystem_vendor,
>                                            pch->subsystem_device)) {
>                       intel_virt_detect_pch(dev_priv, &id, &pch_type);
>                       dev_priv->pch_type = pch_type;
> -                     dev_priv->pch_id = id;
>                       break;
>               }
>       }
> @@ -305,12 +303,10 @@ void intel_detect_pch(struct drm_i915_private
> *dev_priv)
>               drm_dbg_kms(&dev_priv->drm,
>                           "Display disabled, reverting to NOP PCH\n");
>               dev_priv->pch_type = PCH_NOP;
> -             dev_priv->pch_id = 0;
>       } else if (!pch) {
>               if (i915_run_as_guest() && HAS_DISPLAY(dev_priv)) {
>                       intel_virt_detect_pch(dev_priv, &id, &pch_type);
>                       dev_priv->pch_type = pch_type;
> -                     dev_priv->pch_id = id;
>               } else {
>                       drm_dbg_kms(&dev_priv->drm, "No PCH found.\n");
>               }
> diff --git a/drivers/gpu/drm/xe/xe_device_types.h
> b/drivers/gpu/drm/xe/xe_device_types.h
> index c0e886bac183..c71b15897f74 100644
> --- a/drivers/gpu/drm/xe/xe_device_types.h
> +++ b/drivers/gpu/drm/xe/xe_device_types.h
> @@ -547,7 +547,6 @@ struct xe_device {
>        */
>       struct intel_display display;
>       enum intel_pch pch_type;
> -     u16 pch_id;
> 
>       struct dram_info {
>               bool wm_lv_0_adjust_needed;
> --
> 2.39.5

Reply via email to