From 2c227f391a1727f7bcfd0f03c2c75e01bf893383 Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Mon, 13 Oct 2014 09:26:12 +0100 Subject: sna: Drain all udev events before checking output status As libudev only pulls off events one by one and we may need to process several for a MST topology change, keep polling until complete. Signed-off-by: Chris Wilson --- src/sna/sna_driver.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/sna/sna_driver.c') diff --git a/src/sna/sna_driver.c b/src/sna/sna_driver.c index 03db7606..ddb462b5 100644 --- a/src/sna/sna_driver.c +++ b/src/sna/sna_driver.c @@ -879,7 +879,7 @@ static bool sna_uevent_poll(struct sna *sna) pfd.fd = udev_monitor_get_fd(sna->uevent_monitor); pfd.events = POLLIN; - if (poll(&pfd, 1, 0) > 0) + while (poll(&pfd, 1, 0) > 0) sna_handle_uevents(pfd.fd, sna); return true; -- cgit v1.2.3