From ee7d2e0a8ef882c1d4e0e77a0148b54dcfbf4236 Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Fri, 6 Jun 2014 12:00:35 +0100 Subject: sna: MST topologies may change on any hotplug event As the kernel does not send out an explicit DISCOVER event, we have to reinspect every connector after every hotplug event to detect topology changes. Signed-off-by: Chris Wilson --- src/sna/sna_driver.c | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) (limited to 'src/sna/sna_driver.c') diff --git a/src/sna/sna_driver.c b/src/sna/sna_driver.c index 00759367..4df93eb4 100644 --- a/src/sna/sna_driver.c +++ b/src/sna/sna_driver.c @@ -759,21 +759,12 @@ sna_handle_uevents(int fd, void *closure) return; } - str = udev_device_get_property_value(dev, "DISCOVER"); - if (str && atoi(str) == 1) { - DBG(("%s: discover event (vtSema?=%d)\n", - __FUNCTION__, sna->scrn->vtSema)); - if (sna->scrn->vtSema) - sna_mode_discover(sna); - else - sna->flags |= SNA_REDISCOVER; - } - str = udev_device_get_property_value(dev, "HOTPLUG"); if (str && atoi(str) == 1) { DBG(("%s: hotplug event (vtSema?=%d)\n", __FUNCTION__, sna->scrn->vtSema)); if (sna->scrn->vtSema) { + sna_mode_discover(sna); sna_mode_check(sna); RRGetInfo(xf86ScrnToScreen(scrn), TRUE); } else @@ -1178,16 +1169,10 @@ static Bool sna_enter_vt(VT_FUNC_ARGS_DECL) if (intel_get_master(scrn)) return FALSE; - if (sna->flags & SNA_REDISCOVER) { - DBG(("%s: reporting deferred discover event\n", - __FUNCTION__)); - sna_mode_discover(sna); - sna->flags &= ~SNA_REDISCOVER; - } - if (sna->flags & SNA_REPROBE) { DBG(("%s: reporting deferred hotplug event\n", __FUNCTION__)); + sna_mode_discover(sna); RRGetInfo(xf86ScrnToScreen(scrn), TRUE); sna->flags &= ~SNA_REPROBE; } -- cgit v1.2.3