Re: usb hotplug $DEVICE empty
From: Klaus Dittrich
Date: Wed Oct 27 2004 - 07:02:45 EST
I found out why $DEVICE did not show of in /sbin/hotplug
any more. (2.6.10-rc1-bk5)
Depending on the setting of CONFIG_USB_DEVICEFS
either the environment variables DEVICE or PRODUCT
which should be passed to /sbin/hotplug become overwritten
by the environment variable SEQNUM.
This happens in kobject_hotplug() of lib/kobject_uevent.c.
The here called hotplug_ops->hotplug function usb_hotplug()
advances both, the index to envp and the pointer into buffer
but the calling function gets no notice of that.
So to add SEQNUM later on it advances index/pointer to
envp/buffer from where it has stopped before calling
usb_hotplug(), thus overwriting the first entry that
usb_hotplug() has added before.
--
Klaus
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/