summaryrefslogtreecommitdiff
path: root/rcm-server-main.c
diff options
context:
space:
mode:
Diffstat (limited to 'rcm-server-main.c')
-rw-r--r--rcm-server-main.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/rcm-server-main.c b/rcm-server-main.c
index bd48c80..65c82f7 100644
--- a/rcm-server-main.c
+++ b/rcm-server-main.c
@@ -44,7 +44,11 @@ property_get(sd_bus *bus, const char *path, const char *interface,
return -EINVAL;
}
- if (!strcmp(property, "DriverName"))
+ if (!strcmp(property, "SysName"))
+ return sd_bus_message_append(reply, "s", dev->name);
+ else if (!strcmp(property, "Description"))
+ return sd_bus_message_append(reply, "s", dev->input_name);
+ else if (!strcmp(property, "DriverName"))
return sd_bus_message_append(reply, "s", dev->driver_name);
else if (!strcmp(property, "KernelKeymapName"))
return sd_bus_message_append(reply, "s", dev->keymap_name);
@@ -645,6 +649,8 @@ out:
static const sd_bus_vtable device_vtable[] = {
SD_BUS_VTABLE_START(0),
+ SD_BUS_PROPERTY("SysName", "s", property_get, 0, 0),
+ SD_BUS_PROPERTY("Description", "s", property_get, 0, 0),
SD_BUS_PROPERTY("DriverName", "s", property_get, 0, 0),
SD_BUS_PROPERTY("KernelKeymapName", "s", property_get, 0, 0),
SD_BUS_PROPERTY("HardwareType", "s", property_get, 0, 0),
@@ -776,6 +782,8 @@ add_device(struct manager *mgr, struct udev_device *udev)
printf("\tSubsystem : %s\n", udev_device_get_subsystem(udev));
printf("\tDevtype : %s\n", udev_device_get_devtype(udev));
printf("\tAction : %s\n", udev_device_get_action(udev));
+ printf("\tName : %s\n", device->name);
+ printf("\tInput name: %s\n", device->input_name);
printf("\tDriver : %s\n", device->driver_name);
printf("\tKernel map: %s\n", device->keymap_name);
printf("\tDevnode fd: %i\n", device->evdev_fd);
@@ -907,6 +915,7 @@ free_manager(struct manager *mgr) {
struct device *dev = list_first_entry(&mgr->devices, typeof(*dev), list);
list_del(&dev->list);
free(dev->path);
+ free(dev->input_name);
free(dev->driver_name);
free(dev->keymap_name);