On 2026-09-21 10:30, James Lin wrote: > Return early when the plane has neither a CRTC nor a > framebuffer to avoid redundant disabled plane commits. > > Signed-off-by: James Lin <[email protected]> Makes sense to me, __drm_atomic_helper_disable_plane clears CRTC and FB so this can avoid redundant calls. Reviewed-by: Leo Li <[email protected]> > --- > drivers/gpu/drm/drm_atomic_helper.c | 5 +++++ > 1 file changed, 5 insertions(+) > > diff --git a/drivers/gpu/drm/drm_atomic_helper.c > b/drivers/gpu/drm/drm_atomic_helper.c > index 51f39edc31ed..30cc9c07f455 100644 > --- a/drivers/gpu/drm/drm_atomic_helper.c > +++ b/drivers/gpu/drm/drm_atomic_helper.c > @@ -3470,6 +3470,11 @@ int drm_atomic_helper_disable_plane(struct drm_plane > *plane, > goto fail; > } > > + if (!plane_state->crtc && !plane_state->fb) { > + ret = 0; > + goto fail; > + } > + > if (plane_state->crtc && plane_state->crtc->cursor == plane) > plane_state->state->legacy_cursor_update = true; >
