On Tue, Sep 02, 2025 at 11:35:35AM +0200, Maxime Ripard wrote: > The drm_atomic_get_private_obj_state() function tries to find if a > private_obj had already been allocated and was part of the given > drm_atomic_state. If one is found, it returns the existing state > pointer. > > At the point in time where drm_atomic_get_private_obj_state() can be > called (ie, during atomic_check), the existing state is the new state > and we can thus replace the hand-crafted logic by a call to > drm_atomic_get_new_private_obj_state().
This function is being used in e.g. this call stack: ingenic_drm_crtc_atomic_enable -> ingenic_drm_get_priv_state -> drm_atomic_get_private_obj_state(). Please correct me if I'm wrong, doesn't it happen already after the state switch? > > Signed-off-by: Maxime Ripard <mrip...@kernel.org> > --- > drivers/gpu/drm/drm_atomic.c | 8 ++++---- > 1 file changed, 4 insertions(+), 4 deletions(-) > -- With best wishes Dmitry