On Tue, Jun 04, 2024 at 06:25:49PM +0300, Jani Nikula wrote:
> Avoid the implicit dev_priv local variable use, and pass dev_priv
> explicitly to the CHV_BLEND register macro.

Reviewed-by: Rodrigo Vivi <[email protected]>

> 
> Signed-off-by: Jani Nikula <[email protected]>
> ---
>  drivers/gpu/drm/i915/display/intel_display.c | 3 ++-
>  drivers/gpu/drm/i915/i915_reg.h              | 2 +-
>  2 files changed, 3 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/display/intel_display.c 
> b/drivers/gpu/drm/i915/display/intel_display.c
> index 48ee8aee21be..a6d7928fbe37 100644
> --- a/drivers/gpu/drm/i915/display/intel_display.c
> +++ b/drivers/gpu/drm/i915/display/intel_display.c
> @@ -2108,7 +2108,8 @@ static void valleyview_crtc_enable(struct 
> intel_atomic_state *state,
>       intel_de_write(dev_priv, VLV_PIPE_MSA_MISC(pipe), 0);
>  
>       if (IS_CHERRYVIEW(dev_priv) && pipe == PIPE_B) {
> -             intel_de_write(dev_priv, CHV_BLEND(pipe), CHV_BLEND_LEGACY);
> +             intel_de_write(dev_priv, CHV_BLEND(dev_priv, pipe),
> +                            CHV_BLEND_LEGACY);
>               intel_de_write(dev_priv, CHV_CANVAS(pipe), 0);
>       }
>  
> diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h
> index 5d9429bf17a8..ddfa77231426 100644
> --- a/drivers/gpu/drm/i915/i915_reg.h
> +++ b/drivers/gpu/drm/i915/i915_reg.h
> @@ -2271,7 +2271,7 @@
>  #define   CHV_CANVAS_GREEN_MASK      REG_GENMASK(19, 10)
>  #define   CHV_CANVAS_BLUE_MASK       REG_GENMASK(9, 0)
>  
> -#define CHV_BLEND(pipe)              _MMIO_TRANS2(dev_priv, pipe, 
> _CHV_BLEND_A)
> +#define CHV_BLEND(dev_priv, pipe)            _MMIO_TRANS2(dev_priv, pipe, 
> _CHV_BLEND_A)
>  #define CHV_CANVAS(pipe)     _MMIO_TRANS2(dev_priv, pipe, _CHV_CANVAS_A)
>  
>  /* Display/Sprite base address macros */
> -- 
> 2.39.2
> 

Reply via email to