summaryrefslogtreecommitdiffstats
path: root/discover/udev.h
diff options
context:
space:
mode:
authorJeremy Kerr <jk@ozlabs.org>2008-12-15 15:22:34 +1100
committerJeremy Kerr <jk@ozlabs.org>2008-12-15 15:22:34 +1100
commit32e6a41f33e5576716b351bd473a27939fe94fa1 (patch)
tree0d6b75ac0a02d2496416095405cb9498777c3beb /discover/udev.h
parent000a92b4fa909c432732ac3ed8f28eeeaeac70ee (diff)
downloadtalos-petitboot-32e6a41f33e5576716b351bd473a27939fe94fa1.tar.gz
talos-petitboot-32e6a41f33e5576716b351bd473a27939fe94fa1.zip
Initial support for multiple UIs
Move the device discovery code from separate udev helpers to a single process to listen on two sockets: one SOCK_DGRAM for incoming udev events, and one SOCK_STREAM for UIs to connect. Initial support for client/server infrastructure, still need to wire-up the udev messages. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Diffstat (limited to 'discover/udev.h')
-rw-r--r--discover/udev.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/discover/udev.h b/discover/udev.h
new file mode 100644
index 0000000..c30adc9
--- /dev/null
+++ b/discover/udev.h
@@ -0,0 +1,26 @@
+#ifndef _UDEV_H
+#define _UDEV_H
+
+enum udev_action {
+ UDEV_ACTION_ADD,
+ UDEV_ACTION_REMOVE,
+};
+
+struct udev_event {
+ enum udev_action action;
+ char *device;
+
+ struct param {
+ char *name;
+ char *value;
+ } *params;
+ int n_params;
+};
+
+struct udev;
+
+struct udev *udev_init(void);
+
+void udev_destroy(struct udev *udev);
+
+#endif /* _UDEV_H */
OpenPOWER on IntegriCloud