diff options
author | Michel Dänzer <michel.daenzer@amd.com> | 2015-11-11 17:59:14 +0900 |
---|---|---|
committer | Michel Dänzer <michel@daenzer.net> | 2015-11-19 17:19:28 +0900 |
commit | a02982b0ae0b79d2f183a1628edc05cafed8703a (patch) | |
tree | d54f2d7472b0ae59ab0877f6940dc793ecedff40 /src | |
parent | 0ddd20600d0046afd17aa47ffebe86dfd91a2215 (diff) |
Skip disabled CRTCs in amdgpu_scanout_(do_)update
The vblank / page flip ioctls don't work as expected for a disabled CRTC.
(ported from radeon commit acc11877423ecd81a6e0a7f38466f80e43efee20)
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/amdgpu_kms.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/amdgpu_kms.c b/src/amdgpu_kms.c index 2efdbf5..3993591 100644 --- a/src/amdgpu_kms.c +++ b/src/amdgpu_kms.c @@ -257,7 +257,8 @@ amdgpu_scanout_do_update(xf86CrtcPtr xf86_crtc, int scanout_id) GCPtr gc; BoxRec extents; - if (drmmode_crtc->dpms_mode != DPMSModeOn || + if (!xf86_crtc->enabled || + drmmode_crtc->dpms_mode != DPMSModeOn || !drmmode_crtc->scanout[scanout_id].pixmap) return FALSE; @@ -323,7 +324,8 @@ amdgpu_scanout_update(xf86CrtcPtr xf86_crtc) DrawablePtr pDraw; BoxRec extents; - if (drmmode_crtc->scanout_update_pending || + if (!xf86_crtc->enabled || + drmmode_crtc->scanout_update_pending || !drmmode_crtc->scanout[0].pixmap || drmmode_crtc->dpms_mode != DPMSModeOn) return; |