mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
* [ptxdist] [PATCH v2] udev: fix error on kernels without uevent helpers
@ 2015-06-23 14:36 Clemens Gruber
  0 siblings, 0 replies; only message in thread
From: Clemens Gruber @ 2015-06-23 14:36 UTC (permalink / raw)
  To: ptxdist; +Cc: Clemens Gruber

Current kernel docs recommend disabling CONFIG_UEVENT_HELPER.

If disabled however, the following error message is shown:
/etc/rc.d/S00udev: line 95: can't create /proc/sys/kernel/hotplug:
nonexistent directory

This patch fixes it by checking if /sys/kernel/uevent_helper exists.

Signed-off-by: Clemens Gruber <clemens.gruber@pqgruber.com>

---

Sorry for the previous mail, I made a mistake in the conditional.

---
 projectroot/etc/init.d/udev | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/projectroot/etc/init.d/udev b/projectroot/etc/init.d/udev
index 1020b40..5c1bf42 100644
--- a/projectroot/etc/init.d/udev
+++ b/projectroot/etc/init.d/udev
@@ -50,7 +50,9 @@ start)
 
 	# udev handles uevents itself, so we don't need to have
 	# the kernel call out to any binary in response to them
-	echo > /proc/sys/kernel/hotplug
+	if [ -e /sys/kernel/uevent_helper ]; then
+		echo > /proc/sys/kernel/hotplug
+	fi
 
 	echo "creating static nodes"
 	make_extra_nodes
-- 
2.4.4


-- 
ptxdist mailing list
ptxdist@pengutronix.de

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2015-06-23 14:36 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-06-23 14:36 [ptxdist] [PATCH v2] udev: fix error on kernels without uevent helpers Clemens Gruber

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox