aboutsummaryrefslogtreecommitdiff
path: root/backend/drm/udev.c
diff options
context:
space:
mode:
authorascent12 <ascent12@hotmail.com>2017-06-01 23:10:19 +1200
committerGitHub <noreply@github.com>2017-06-01 23:10:19 +1200
commit62d612a01e10947db2c2047be528ed525e5f91be (patch)
tree0fe44a59a19c09b0a7b8673dc93de57096eb49a9 /backend/drm/udev.c
parentf9d363fece0046cabfa00ad6b72b50f45b70db60 (diff)
parentae770043460cdfca496dd6caeab55f337f3db37b (diff)
Merge branch 'master' into session
Diffstat (limited to 'backend/drm/udev.c')
-rw-r--r--backend/drm/udev.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/backend/drm/udev.c b/backend/drm/udev.c
index e5470157..79e303d6 100644
--- a/backend/drm/udev.c
+++ b/backend/drm/udev.c
@@ -147,12 +147,16 @@ static int udev_event(int fd, uint32_t mask, void *data) {
return 1;
}
+ const char *action = udev_device_get_action(dev);
const char *path = udev_device_get_devnode(dev);
+
+ wlr_log(L_DEBUG, "udev event for %s (%s)",
+ udev_device_get_sysname(dev), action);
+
if (!path || strcmp(path, udev->drm_path) != 0) {
goto out;
}
- const char *action = udev_device_get_action(dev);
if (!action || strcmp(action, "change") != 0) {
goto out;
}
@@ -189,9 +193,8 @@ bool wlr_udev_init(struct wl_display *display, struct wlr_udev *udev) {
wlr_log(L_ERROR, "Failed to create udev event source");
goto error_mon;
}
-
- udev->drm_path = NULL;
-
+
+ wlr_log(L_DEBUG, "Successfully initialized udev");
return true;
error_mon: