Anssi Hannula wrote:[...]
Hi!
There seem to be changes in sysfs input structure between 2.6.22 and
2.6.23-rc5 which cause some breakage.
There is no longer:
/sys/class/input/eventX => /sys/class/input/inputX/eventX
instead there is:
/sys/class/inputX/input:eventX => /sys/class/input/eventX
Notice the added "input:". I don't know if any software depends on this,
though.
However, the change that broke id_path of udev is that
/sys/class/input/event5/device is now a symlink to the inputX directory
instead of being the same as the device symlink in inputX directory,
i.e. to ../../../devices/platform/pcspkr in this case.
Udev id_path uses that directory to construct the ID_PATH variable.
Should the sysfs structure be reverted or should udev be adapted to
handle traversing /device symlink twice? I think the former, as there
should be considerably more time to adapt udev for coming changes in
sysfs.
I am using 2.6.23-rc5 in current cooker
and I did not notice any breakage; could you please show example of wrong path? E.g. I have
{pts/0}% LC_ALL=C ll /dev/input/by-path
total 0
lrwxrwxrwx 1 root root 9 Sep 2 15:00
platform-i8042-serio-0-event-kbd -> ../event0
lrwxrwxrwx 1 root root 9 Sep 2 15:00
platform-i8042-serio-1-event-mouse -> ../event1
lrwxrwxrwx 1 root root 9 Sep 2 15:00
platform-i8042-serio-1-mouse -> ../mouse0
and it looks pretty sane for me.
Oh, and I do not have CONFIG_SYSFS_DEPRECATED which probably explains why it
works for me :)
{pts/0}% LC_ALL=C ll /sys/class/input/input2/
total 0
drwxr-xr-x 2 root root 0 Sep 8 22:25 capabilities/
drwxr-xr-x 3 root root 0 Sep 8 22:22 event2/
drwxr-xr-x 2 root root 0 Sep 8 22:25 id/
-r--r--r-- 1 root root 4096 Sep 8 22:25 modalias
-r--r--r-- 1 root root 4096 Sep 8 22:25 name
-r--r--r-- 1 root root 4096 Sep 8 22:25 phys
drwxr-xr-x 2 root root 0 Sep 8 22:25 power/
lrwxrwxrwx 1 root root 0 Sep 8 22:25
subsystem -> ../../../../class/input/
-rw-r--r-- 1 root root 4096 Sep 8 22:25 uevent
-r--r--r-- 1 root root 4096 Sep 8 22:25 uniq
this implies that SYSFS_DEPRECATED may be broken w.r.t. udev; OTOH it *is*
deprecated, is not it?