| Anonymous | Login | Signup for a new account | 11-10-2008 12:43 PST |
| Main | My View | View Issues | Change Log | Docs |
| Viewing Issue Simple Details [ Jump to Notes ] | [ View Advanced ] [ Issue History ] [ Print ] | ||||||||
| ID | Category | Severity | Reproducibility | Date Submitted | Last Update | ||||
| 0004714 | [BusyBox] Other | major | always | 08-23-08 14:46 | 09-08-08 11:05 | ||||
| Reporter | lucas | View Status | public | ||||||
| Assigned To | BusyBox | ||||||||
| Priority | normal | Resolution | fixed | ||||||
| Status | closed | Product Version | 1.11.x | ||||||
| Summary | 0004714: mdev can't tell the difference between /dev/lp0 and /dev/usblp0 | ||||||||
| Description | As mdev uses the basename of the device path to know the device name, situations like "/sys/class/usb/lp0" and "/sys/class/printer/lp0" get in conflict (the last hotplug event overwrites the previous device file). | ||||||||
| Additional Information |
In make_device(), at mdev.c, not even the "exec" rule can fix this, as only the device name is passed (and it has already overwritten the previous device file). A solution could be to have the mdev.conf file syntax to allow a match for alternate things, like the major/minor pair (which would work at least for devices with fixed assigned pairs). One possible syntax could be: --------- mdev.conf --------- @180,0-15 0:0 660 =usb/ ## /dev/usb/lp{0-15} @7,0-63 0:0 660 >vc/ ## /dev/vc/{vcs,vcs1,...} @7,128-191 0:0 660 >vc/ ## /dev/vc/{vcsa,vcsa1,...} @13,0-31 0:0 660 >input/ ## /dev/input/{js0,js1,...} @13,32-62 0:0 660 >input/ ## /dev/input/{mouse0,mouse1,...} @13,63 0:0 660 >input/ ## /dev/input/mice @13,64-95 0:0 660 >input/ ## /dev/input/{event0,event1,...} --------- mdev.conf --------- One possible implication of this scheme (not actually tested) is that the scan task would be faster, as there is no need for regular expression matches for most rules. Off course, the current rename of the old device would need to be fixed. I would also vote for an exec rule that would not get called with the device already created (and possibly overwriting a previous one). The major/minor and type of the device file would just get passed by env vars and the executed script/binary would then create the device if needed. |
||||||||
| Attached Files |
|
||||||||
|
|
|||||||||
| Copyright © 2000 - 2006 Mantis Group |