> lockdev implements a library interface around the SYSV-style UUCP > device locks for TTY devices. However, this type of locking is > deprecated and unnecessary, at least on Linux. The recommended > alternative is direct use of flock(2) on the corresponding device > node.
This deprecation isn't widely known, I don't think. A search for serial locking is likely to end up at the Linux "Serial HOWTO: Locking Out Others" on TLDP. That recommends use of lock-files, and doesn't mention flock(). The Filesystem Hierarchy Standard v2.3 also describes UUCP style lock files under /var/lock, and doesn't mention anything about deprecation. So far I haven't found anything that describes UUCP style lock file deprecation in Linux, other than this Debian bug. It would be helpful if flock() is indeed the "best practices" for locking serial ports and other devices, to widely disseminate that knowledge to the broad Linux community, via appropriate documentation. -- Craig McQueen -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org