mirror of
https://github.com/X11Libre/xf86-video-intel.git
synced 2026-04-14 10:54:23 +00:00
intel-virtual-output: Copy existing CRTC information
If we fail to disable the remote output during initialisation, copy the current configuration in order to try and keep the bookkeeping in order. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
@@ -560,6 +560,15 @@ static int clone_update_modes__randr(struct clone *clone)
|
||||
if (disable_crtc(clone->dst.dpy, from_res, from_info->crtc)) {
|
||||
clone->dst.rr_crtc = 0;
|
||||
clone->dst.mode.id = 0;
|
||||
} else {
|
||||
XRRCrtcInfo *c = XRRGetCrtcInfo(clone->dst.dpy, from_res, from_info->crtc);
|
||||
if (c) {
|
||||
clone->dst.x = c->x;
|
||||
clone->dst.y = c->y;
|
||||
clone->dst.rotation = c->rotation;
|
||||
clone->dst.mode.id = c->mode;
|
||||
XRRFreeCrtcInfo(c);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user