summaryrefslogtreecommitdiff
path: root/udevstart.c
diff options
context:
space:
mode:
authorKay Sievers <kay.sievers@suse.de>2006-01-25 02:21:07 +0100
committerKay Sievers <kay.sievers@suse.de>2006-01-25 02:21:07 +0100
commit37854ffc9ae60da66d5525225c93eb1754a780bb (patch)
treeb410a3da7e27273aa13ec08c8bee95545286c367 /udevstart.c
parentad27f5b3962d4cb1e4fcc25d3d0c7d0c81abc82a (diff)
let "ignore_device" always return the event successfully
Signed-off-by: Kay Sievers <kay.sievers@suse.de>
Diffstat (limited to 'udevstart.c')
-rw-r--r--udevstart.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/udevstart.c b/udevstart.c
index fdb2ae3808..8f8342ff48 100644
--- a/udevstart.c
+++ b/udevstart.c
@@ -108,6 +108,7 @@ static int add_device(const char *devpath)
{
struct sysfs_device *dev;
struct udevice *udev;
+ int retval;
/* clear and set environment for next event */
clearenv();
@@ -146,14 +147,14 @@ static int add_device(const char *devpath)
dbg("device event will be ignored");
goto exit;
}
- if (udev->name[0] == '\0') {
- dbg("device node creation supressed");
- goto run;
+ if (udev->name[0] != '\0')
+ retval = udev_add_device(udev);
+ else {
+ info("device node creation supressed");
+ goto exit;
}
- udev_add_device(udev);
-run:
- if (udev_run && !list_empty(&udev->run_list)) {
+ if (retval == 0 && !udev->ignore_device && udev_run) {
struct name_entry *name_loop;
dbg("executing run list");
@@ -169,9 +170,9 @@ run:
}
}
}
+
exit:
udev_device_cleanup(udev);
-
return 0;
}