1 |
On Mar 21, 2012 10:04 PM, "Alan Mackenzie" <acm@×××.de> wrote: |
2 |
> |
3 |
> Hello again, |
4 |
> |
5 |
> On Wed, Mar 21, 2012 at 08:12:40PM +0700, Pandu Poluan wrote: |
6 |
> > On Mar 21, 2012 8:07 PM, "Alan Mackenzie" <acm@×××.de> wrote: |
7 |
> |
8 |
> > > On Wed, Mar 21, 2012 at 07:49:02PM +0700, Pandu Poluan wrote: |
9 |
> > > > Strange... |
10 |
> |
11 |
> > > > Do you use mdev to handle hotplugs, btw? |
12 |
> |
13 |
> > > You mean, like sticking in a USB stick, or turning my printer on? |
14 |
Yes, I |
15 |
> > > do. |
16 |
> |
17 |
> |
18 |
> > No, I mean, did you do : |
19 |
> |
20 |
> > echo /bin/mdev > /proc/sys/kernel/hotplug |
21 |
> |
22 |
> No I haven't. I don't understand at all what this is about. Any chance |
23 |
> of a quick summary? |
24 |
> |
25 |
|
26 |
According to the busybox documentation, /proc/sys/kernel/hotplug contains |
27 |
the path to a program that will be invoked on hotplug events (hotplug here |
28 |
means the creation of a new device node under /dev, not necessarily |
29 |
actually plugging something onto the box). |
30 |
|
31 |
Doing the above 'echo' will result in kernel invoking mdev when a hotplug |
32 |
event fires; mdev will then act upon the newly-created device node |
33 |
according to the 'recipe' in /etc/mdev.conf, e.g., chown-ing the node, |
34 |
renaming/moving the node, making a symlink, or even triggering a script. |
35 |
|
36 |
The above line should go right after the 'mdev -s' line in linuxrc. |
37 |
|
38 |
> > (ensure beforehand that /bin/mdev is a symlink to /bin/busybox) |
39 |
> |
40 |
> my /sbin/mdev is an indirect symlink to /bin/busybox as follows: |
41 |
> ^ |
42 |
> |
43 |
> /sbin/mdev -> /bin/bb -> busybox |
44 |
> |
45 |
> Presumably this would be OK. |
46 |
> |
47 |
|
48 |
I think so... |
49 |
|
50 |
Rgds, |