[RESEND 5/5] drm/i915/plane: rename intel_atomic_add_affected_planes() to intel_plane_add_affected()
Ville Syrjälä
ville.syrjala at linux.intel.com
Fri Jun 13 15:06:22 UTC 2025
On Fri, Jun 13, 2025 at 06:02:21PM +0300, Ville Syrjälä wrote:
> On Thu, Jun 12, 2025 at 02:37:11PM +0300, Jani Nikula wrote:
> > Rename to follow filename based naming.
> >
> > Signed-off-by: Jani Nikula <jani.nikula at intel.com>
> > ---
> > drivers/gpu/drm/i915/display/intel_display.c | 4 ++--
> > drivers/gpu/drm/i915/display/intel_plane.c | 4 ++--
> > drivers/gpu/drm/i915/display/intel_plane.h | 4 ++--
> > 3 files changed, 6 insertions(+), 6 deletions(-)
> >
> > diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c
> > index bd81ff9e3854..978c524546c6 100644
> > --- a/drivers/gpu/drm/i915/display/intel_display.c
> > +++ b/drivers/gpu/drm/i915/display/intel_display.c
> > @@ -5479,7 +5479,7 @@ static int intel_modeset_pipe(struct intel_atomic_state *state,
> > if (ret)
> > return ret;
> >
> > - ret = intel_atomic_add_affected_planes(state, crtc);
> > + ret = intel_plane_add_affected(state, crtc);
>
> This breaks the common naming pattern. At the very least I think
> it needs to keep the "planes" at the end to make it clear what
> it's adding.
>
> But from the "does this sentence make any sense?" POV I'd
> rather it be called intel_crtc_add_affected_planes().
If you're worried about the namespacing then I think just move it
(and intel_crtc_add_planes_to_state()) to intel_crtc.c. There's
nothing really plane specific in these, so doesnt' matter where
they live AFAICS.
>
> > if (ret)
> > return ret;
> >
> > @@ -6195,7 +6195,7 @@ static int intel_joiner_add_affected_crtcs(struct intel_atomic_state *state)
> > if (ret)
> > return ret;
> >
> > - ret = intel_atomic_add_affected_planes(state, crtc);
> > + ret = intel_plane_add_affected(state, crtc);
> > if (ret)
> > return ret;
> > }
> > diff --git a/drivers/gpu/drm/i915/display/intel_plane.c b/drivers/gpu/drm/i915/display/intel_plane.c
> > index 2ac7a4e655f5..11aeb7435b05 100644
> > --- a/drivers/gpu/drm/i915/display/intel_plane.c
> > +++ b/drivers/gpu/drm/i915/display/intel_plane.c
> > @@ -1433,8 +1433,8 @@ static int intel_crtc_add_planes_to_state(struct intel_atomic_state *state,
> > return 0;
> > }
> >
> > -int intel_atomic_add_affected_planes(struct intel_atomic_state *state,
> > - struct intel_crtc *crtc)
> > +int intel_plane_add_affected(struct intel_atomic_state *state,
> > + struct intel_crtc *crtc)
> > {
> > const struct intel_crtc_state *old_crtc_state =
> > intel_atomic_get_old_crtc_state(state, crtc);
> > diff --git a/drivers/gpu/drm/i915/display/intel_plane.h b/drivers/gpu/drm/i915/display/intel_plane.h
> > index 5cb995b2940f..4ef012c08fa4 100644
> > --- a/drivers/gpu/drm/i915/display/intel_plane.h
> > +++ b/drivers/gpu/drm/i915/display/intel_plane.h
> > @@ -83,8 +83,8 @@ void intel_plane_helper_add(struct intel_plane *plane);
> > bool intel_plane_needs_physical(struct intel_plane *plane);
> > void intel_plane_init_cursor_vblank_work(struct intel_plane_state *old_plane_state,
> > struct intel_plane_state *new_plane_state);
> > -int intel_atomic_add_affected_planes(struct intel_atomic_state *state,
> > - struct intel_crtc *crtc);
> > +int intel_plane_add_affected(struct intel_atomic_state *state,
> > + struct intel_crtc *crtc);
> > int intel_plane_atomic_check(struct intel_atomic_state *state);
> >
> > u32 intel_plane_ggtt_offset(const struct intel_plane_state *plane_state);
> > --
> > 2.39.5
>
> --
> Ville Syrjälä
> Intel
--
Ville Syrjälä
Intel
More information about the Intel-xe
mailing list