diff options
author | Russell King <rmk+kernel@armlinux.org.uk> | 2018-07-30 11:52:34 +0100 |
---|---|---|
committer | Russell King <rmk+kernel@armlinux.org.uk> | 2018-07-30 11:52:34 +0100 |
commit | 9c41467c9aa5b3916ff559b8c2b3725d6290e5ec (patch) | |
tree | 6f785cee3fb98664d879b28fd8a624c18b983497 /drivers/gpu/drm/armada | |
parent | 47dc413b0025e96eaa43bdd808233763e4080a10 (diff) | |
download | linux-stable-9c41467c9aa5b3916ff559b8c2b3725d6290e5ec.tar.gz linux-stable-9c41467c9aa5b3916ff559b8c2b3725d6290e5ec.tar.bz2 linux-stable-9c41467c9aa5b3916ff559b8c2b3725d6290e5ec.zip |
drm/armada: remove temporary crtc state
Now that we have the CRTC using the atomic modeset transitional helper,
there is no need to build a temporary crtc state anymore - we can use
the CRTC atomic state directly.
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Diffstat (limited to 'drivers/gpu/drm/armada')
-rw-r--r-- | drivers/gpu/drm/armada/armada_crtc.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/gpu/drm/armada/armada_crtc.c b/drivers/gpu/drm/armada/armada_crtc.c index 5bb097b75b44..056673911818 100644 --- a/drivers/gpu/drm/armada/armada_crtc.c +++ b/drivers/gpu/drm/armada/armada_crtc.c @@ -1099,13 +1099,13 @@ int armada_drm_plane_atomic_check(struct drm_plane *plane, { if (state->fb && !WARN_ON(!state->crtc)) { struct drm_crtc *crtc = state->crtc; - struct drm_crtc_state crtc_state = { - .crtc = crtc, - .enable = crtc->enabled, - .mode = crtc->mode, - }; + struct drm_crtc_state *crtc_state; - return drm_atomic_helper_check_plane_state(state, &crtc_state, + if (state->state) + crtc_state = drm_atomic_get_existing_crtc_state(state->state, crtc); + else + crtc_state = crtc->state; + return drm_atomic_helper_check_plane_state(state, crtc_state, 0, INT_MAX, true, false); } else { |