-static inline char *get_seqnum(void)
-{
- char *seqnum;
-
- seqnum = getenv("SEQNUM");
- return seqnum;
-}
-
-enum query_type {
- NONE,
- NAME,
- SYMLINK,
- OWNER,
- GROUP
-};
-
-static inline int udev_user(int argc, char **argv)
-{
- static const char short_options[] = "p:q:rVh";
- int option;
- int retval = -EINVAL;
- struct udevice dev;
- int root = 0;
- enum query_type query = NONE;
- char result[NAME_SIZE] = "";
- char path[NAME_SIZE] = "";
-
- /* get command line options */
- while (1) {
- option = getopt(argc, argv, short_options);
- if (option == -1)
- break;
-
- dbg("option '%c'", option);
- switch (option) {
- case 'p':
- dbg("udev path: %s\n", optarg);
- strfieldcpy(path, optarg);
- break;
-
- case 'q':
- dbg("udev query: %s\n", optarg);
-
- if (strcmp(optarg, "name") == 0) {
- query = NAME;
- break;
- }
+/* decide if we should manage the whole hotplug event
+ * for now look if the kernel calls udevsend instead of /sbin/hotplug
+ */
+static int manage_hotplug_event(void) {
+ char helper[256];
+ int fd;
+ int len;