From 61716a2c77dfde9addf6b41a6d72d26a8584150e Mon Sep 17 00:00:00 2001 From: Kenny Levinsen Date: Fri, 31 Jul 2020 00:22:18 +0200 Subject: Initial implementation of seatd and libseat --- common/evdev.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 common/evdev.c (limited to 'common/evdev.c') diff --git a/common/evdev.c b/common/evdev.c new file mode 100644 index 0000000..fe6922d --- /dev/null +++ b/common/evdev.c @@ -0,0 +1,15 @@ +#include +#include +#include +#include +#include + +#include "evdev.h" + +int evdev_revoke(int fd) { + return ioctl(fd, EVIOCREVOKE, NULL); +} + +int dev_is_evdev(dev_t device) { + return major(device) == 13; +} -- cgit v1.2.3