On Wed, 2 Dec 2009, Alan Cox wrote:You're still missing the point. O_NODE is like a hard link, exceptI don't think I am missing the point here. You have a reference to an
the reference doesn't come from the filesystem but from a file
descriptor. From udev's perspective there's no difference.
object in the fs but you don't have a reference to the driver underneath
s the driver can change on you *while* you have the O_NODE open and fd
live. That cannot happen with a hard link and open.
It isn't the same thing as far as I can see. You don't have the barrier
between the operations that occurs in the real open/close case because
they lock the driver.
The file descriptor opened with O_NODE allows exaclactly the same
operations that a hard link to the device would, nothing more. It's
just a link to the *node*, except it doesn't increment the link count,
the driver is irrelevant.