drm_atomic_helper_plane_reset() is no longer used: all callers now go through drm_atomic_helper_plane_create_state(). Remove it.
Signed-off-by: Maxime Ripard <[email protected]> --- drivers/gpu/drm/drm_atomic_state_helper.c | 19 ------------------- include/drm/drm_atomic_state_helper.h | 1 - include/drm/drm_plane.h | 3 --- 3 files changed, 23 deletions(-) diff --git a/drivers/gpu/drm/drm_atomic_state_helper.c b/drivers/gpu/drm/drm_atomic_state_helper.c index d90d1d7c9cf9..f184ce76e090 100644 --- a/drivers/gpu/drm/drm_atomic_state_helper.c +++ b/drivers/gpu/drm/drm_atomic_state_helper.c @@ -344,29 +344,10 @@ void __drm_atomic_helper_plane_reset(struct drm_plane *plane, plane->state = plane_state; } EXPORT_SYMBOL(__drm_atomic_helper_plane_reset); -/** - * drm_atomic_helper_plane_reset - default &drm_plane_funcs.reset hook for planes - * @plane: drm plane - * - * Resets the atomic state for @plane by freeing the state pointer (which might - * be NULL, e.g. at driver load time) and allocating a new empty state object. - */ -void drm_atomic_helper_plane_reset(struct drm_plane *plane) -{ - if (plane->state) - __drm_atomic_helper_plane_destroy_state(plane->state); - - kfree(plane->state); - plane->state = kzalloc_obj(*plane->state); - if (plane->state) - __drm_atomic_helper_plane_reset(plane, plane->state); -} -EXPORT_SYMBOL(drm_atomic_helper_plane_reset); - /** * drm_atomic_helper_plane_create_state - default &drm_plane_funcs.atomic_create_state hook for planes * @plane: plane object * * Allocates and initializes pristine @drm_plane_state. diff --git a/include/drm/drm_atomic_state_helper.h b/include/drm/drm_atomic_state_helper.h index 34a599c3d86d..60635eb34758 100644 --- a/include/drm/drm_atomic_state_helper.h +++ b/include/drm/drm_atomic_state_helper.h @@ -59,11 +59,10 @@ void __drm_atomic_helper_plane_state_init(struct drm_plane_state *state, struct drm_plane *plane); struct drm_plane_state * drm_atomic_helper_plane_create_state(struct drm_plane *plane); void __drm_atomic_helper_plane_reset(struct drm_plane *plane, struct drm_plane_state *state); -void drm_atomic_helper_plane_reset(struct drm_plane *plane); void __drm_atomic_helper_plane_duplicate_state(struct drm_plane *plane, struct drm_plane_state *state); struct drm_plane_state * drm_atomic_helper_plane_duplicate_state(struct drm_plane *plane); void __drm_atomic_helper_plane_destroy_state(struct drm_plane_state *state); diff --git a/include/drm/drm_plane.h b/include/drm/drm_plane.h index 2c5a5a70a71b..e757e9dbf132 100644 --- a/include/drm/drm_plane.h +++ b/include/drm/drm_plane.h @@ -363,13 +363,10 @@ struct drm_plane_funcs { * @reset: * * Reset plane hardware and software state to off. This function isn't * called by the core directly, only through drm_mode_config_reset(). * It's not a helper hook only for historical reasons. - * - * Atomic drivers can use drm_atomic_helper_plane_reset() to reset - * atomic state using this hook. */ void (*reset)(struct drm_plane *plane); /** * @set_property: -- 2.55.0
