I have 2 identical USB devices. Only one persistent symlink is created:
/dev/v4l/by-id/usb-fushicai_usbtv007_300000000002-video-index0
I think it's because /usr/lib/udev/rules.d/60-persistent-v4l.rules uses ATTR{index}
to distinguish them, but it's always zero:
for d in /dev/video*; do echo $d; udevadm info -a $d | grep 'ATTRS.manufacturer\|ATTR.index\|ATTR.name'; echo ; done
/dev/video0
ATTR{index}=="0"
ATTR{name}=="Loopback video device 0"
/dev/video1
ATTR{index}=="0"
ATTR{name}=="Loopback video device 1"
/dev/video2
ATTR{index}=="0"
ATTR{name}=="Loopback video device 2"
/dev/video3
ATTR{index}=="0"
ATTR{name}=="Loopback video device 3"
/dev/video4
ATTR{index}=="0"
ATTR{name}=="usbtv"
ATTRS{manufacturer}=="fushicai"
ATTRS{manufacturer}=="Linux 4.2.5-1-ARCH ehci_hcd"
/dev/video5
ATTR{index}=="0"
ATTR{name}=="usbtv"
ATTRS{manufacturer}=="fushicai"
ATTRS{manufacturer}=="Linux 4.2.5-1-ARCH ehci_hcd"
/dev/video6
ATTR{index}=="0"
ATTR{name}=="stk1160"
ATTRS{manufacturer}=="Syntek Semiconductor"
ATTRS{manufacturer}=="Linux 4.2.5-1-ARCH xhci-hcd"
Who assigns this attribute? How to fix this?
full output for comparison. http://pastebin.com/0zcf7Szk http://pastebin.com/UgWgqpJz
As you can see, the only difference is the plugged usb port.
for d in /dev/video*; do echo $d; udevadm info -a $d; done
here paste.ubuntu.com