sna: Handle failure to disable old plane when switching CRTCs
If we fail to disable the old plane, abort the PutImage and report the error. Signed-off-by: Zdenek Kabelac <zkabelac@redhat.com>
This commit is contained in:
parent
00dcb4f229
commit
af4995d74b
|
|
@ -315,7 +315,10 @@ sna_video_sprite_show(struct sna *sna,
|
|||
if (video->plane) {
|
||||
memset(&s, 0, sizeof(s));
|
||||
s.plane_id = video->plane;
|
||||
drmIoctl(video->sna->kgem.fd, DRM_IOCTL_MODE_SETPLANE, &s);
|
||||
if (drmIoctl(video->sna->kgem.fd, DRM_IOCTL_MODE_SETPLANE, &s)) {
|
||||
DBG(("SET_PLANE failed to turn off existing sprite: ret=%d\n", errno));
|
||||
return false;
|
||||
}
|
||||
}
|
||||
video->plane = s.plane_id;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue