Package: udev
Version: 164-3
Severity: normal
Connecting a GSM modem to USB socket creates three ttyUSB<n>, ttyUSB<n+1> and
ttyUSB<n+2> device files.
The file ttyUSB<n> denotes the first serial interface on modem.
The following rule
SUBSYSTEMS=="usb", KERNEL=="ttyUSB*", ACTION=="add", \
ATTRS{idVendor}=="12d1", ATTRS{idProduct}=="1001", \
ATTRS{bNumInterfaces}==" 3", \
PROGRAM+="/etc/udev/ttyusb plus %n", \
SYMLINK+="ttyUSBplus%c"
and the simple script (/etc/udev/ttyusb)
#!/bin/bash
# $1 plus|play
# $2 %n
[ ! -h "/dev/ttyUSB${1}0" ] &&
{ echo "0"; exit 0
}
[ ! -h "/dev/ttyUSB${1}1" ] &&
{ echo "1"; exit 0
}
[ ! -h "/dev/ttyUSB${1}2" ] &&
{ echo "2"; exit 0
}
exit 0
on Lenny makes a symlink ttyUSB<name><number> always to ttyUSB<n>. This means
works as should.
Upgrade to Squeeze has broke this. The symlink often points to other than
ttyUSB<n> file.
Simple debugging shows that the order of execution of three calls of the script
is undetermined. So symlink often points to wrong modem's interface.
The problem hasn't appeared on mixed system, Lenny's udev and Squeeze's kernel.
-- System Information:
Debian Release: squeeze/sid
APT prefers testing
APT policy: (650, 'testing')
Architecture: i386 (i686)
Kernel: Linux 2.6.32-5-686 (SMP w/1 CPU core)
Locale: LANG=C, LC_CTYPE=pl_PL.ISO-8859-2 (charmap=ISO-8859-2)
Shell: /bin/sh linked to /bin/dash
Versions of packages udev depends on:
ii debconf [debconf-2.0] 1.5.36 Debian configuration management sy
ii libc6 2.11.2-7 Embedded GNU C Library: Shared lib
ii libselinux1 2.0.96-1 SELinux runtime shared libraries
ii libudev0 164-3 libudev shared library
ii libusb-0.1-4 2:0.1.12-16 userspace USB programming library
ii lsb-base 3.2-23.1 Linux Standard Base 3.2 init scrip
ii util-linux 2.17.2-5 Miscellaneous system utilities
Versions of packages udev recommends:
pn pciutils <none> (no description available)
ii usbutils 0.87-5 Linux USB utilities
udev suggests no packages.
--
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]