diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2014-10-13 09:26:12 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2014-10-13 09:26:12 +0100 |
commit | 2c227f391a1727f7bcfd0f03c2c75e01bf893383 (patch) | |
tree | 5724d12fd929d8c63b4d8307e56667e0448a7944 /src/sna/sna_driver.c | |
parent | 49376ba3bddd15e62df55928198160d9970dc1c6 (diff) |
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 <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/sna/sna_driver.c')
-rw-r--r-- | src/sna/sna_driver.c | 2 |
1 files changed, 1 insertions, 1 deletions
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; |