drm/rockchip: Use drm_atomic_helper_commit_tail_rpm
authorSean Paul <seanpaul@chromium.org>
Tue, 11 Jun 2019 16:08:25 +0000 (12:08 -0400)
committerSean Paul <seanpaul@chromium.org>
Fri, 26 Jul 2019 18:48:03 +0000 (14:48 -0400)
Now that we use the drm psr helpers, we no longer need to hand-roll our
atomic_commit_tail implementation. So use the helper

Changes in v2:
- None
Changes in v3:
- None
Changes in v4:
- None
Changes in v5:
- None

Link to v1: https://patchwork.freedesktop.org/patch/msgid/20190228210939.83386-6-sean@poorly.run
Link to v2: https://patchwork.freedesktop.org/patch/msgid/20190326204509.96515-5-sean@poorly.run
Link to v3: https://patchwork.freedesktop.org/patch/msgid/20190502194956.218441-11-sean@poorly.run
Link to v4: https://patchwork.freedesktop.org/patch/msgid/20190508160920.144739-12-sean@poorly.run

Cc: Zain Wang <wzz@rock-chips.com>
Cc: Tomasz Figa <tfiga@chromium.org>
Tested-by: Heiko Stuebner <heiko@sntech.de>
Reviewed-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Sean Paul <seanpaul@chromium.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20190611160844.257498-12-sean@poorly.run
drivers/gpu/drm/rockchip/rockchip_drm_fb.c

index dba352ec0ee3f29aa970440106544f655b57355d..ca01234c037c3eed38fdd39fb06c79f0f6eecaa5 100644 (file)
@@ -105,27 +105,8 @@ err_gem_object_unreference:
        return ERR_PTR(ret);
 }
 
-static void
-rockchip_atomic_helper_commit_tail_rpm(struct drm_atomic_state *old_state)
-{
-       struct drm_device *dev = old_state->dev;
-
-       drm_atomic_helper_commit_modeset_disables(dev, old_state);
-
-       drm_atomic_helper_commit_modeset_enables(dev, old_state);
-
-       drm_atomic_helper_commit_planes(dev, old_state,
-                                       DRM_PLANE_COMMIT_ACTIVE_ONLY);
-
-       drm_atomic_helper_commit_hw_done(old_state);
-
-       drm_atomic_helper_wait_for_vblanks(dev, old_state);
-
-       drm_atomic_helper_cleanup_planes(dev, old_state);
-}
-
 static const struct drm_mode_config_helper_funcs rockchip_mode_config_helpers = {
-       .atomic_commit_tail = rockchip_atomic_helper_commit_tail_rpm,
+       .atomic_commit_tail = drm_atomic_helper_commit_tail_rpm,
 };
 
 static const struct drm_mode_config_funcs rockchip_drm_mode_config_funcs = {