chiark / gitweb /
logind: Capability of making seats without framebuffer devices
authorOleg Samarin <osamarin68@gmail.com>
Sat, 5 Jan 2013 16:33:37 +0000 (20:33 +0400)
committerLennart Poettering <lennart@poettering.net>
Mon, 7 Jan 2013 14:43:14 +0000 (15:43 +0100)
file logind.c: The seat is now activated by any device with udev tag "seat-master"
file 71-seat.rules.in: All framebuffer devices have this tag

src/login/71-seat.rules.in
src/login/logind.c

index f554d7f..4f1a9a5 100644 (file)
@@ -10,7 +10,7 @@ ACTION=="remove", GOTO="seat_end"
 TAG=="uaccess", SUBSYSTEM!="sound", TAG+="seat"
 SUBSYSTEM=="sound", KERNEL=="card*", TAG+="seat"
 SUBSYSTEM=="input", KERNEL=="input*", TAG+="seat"
-SUBSYSTEM=="graphics", KERNEL=="fb[0-9]*", TAG+="seat"
+SUBSYSTEM=="graphics", KERNEL=="fb[0-9]*", TAG+="seat", TAG+="seat-master"
 SUBSYSTEM=="usb", ATTR{bDeviceClass}=="09", TAG+="seat"
 
 # 'Plugable' USB hub, sound, network, graphics adapter
index 6438631..6776229 100644 (file)
@@ -459,11 +459,7 @@ int manager_enumerate_devices(Manager *m) {
                 goto finish;
         }
 
-        r = udev_enumerate_add_match_subsystem(e, "graphics");
-        if (r < 0)
-                goto finish;
-
-        r = udev_enumerate_add_match_tag(e, "seat");
+        r = udev_enumerate_add_match_tag(e, "seat-master");
         if (r < 0)
                 goto finish;
 
@@ -1295,11 +1291,7 @@ static int manager_connect_udev(Manager *m) {
         if (!m->udev_seat_monitor)
                 return -ENOMEM;
 
-        r = udev_monitor_filter_add_match_tag(m->udev_seat_monitor, "seat");
-        if (r < 0)
-                return r;
-
-        r = udev_monitor_filter_add_match_subsystem_devtype(m->udev_seat_monitor, "graphics", NULL);
+        r = udev_monitor_filter_add_match_tag(m->udev_seat_monitor, "seat-master");
         if (r < 0)
                 return r;