hm I thought there was a blog or rant or kernel documentation page about persistent device naming, similar to stable kernel abi nonsense from @gregkh but I can't find it, was I dreaming?
https://www.kernel.org/doc/Documentation/process/stable-api-nonsense.rst
@lanodan @sima @sourcejedi @gregkh I had modules loaded in different order, and got different interface names. Switched to persistent naming after that.
(Though when drivers were built-in rather than modules, ordering was stable.)
@gregkh @sima @sourcejedi I really wish that the kernel never reused /dev
nodes or major:minor numbers. RIght now, one must do verification after calling open()
if one wants to avoid race conditions. Of course, lots of programs do not do that.
@gregkh @sima Some more questions:
/sys/devices
?@gregkh @sima @sourcejedi Even if the path is never reused, the device major and minor number can still be reused. Right now I think one needs a custom FUSE filesystem if one wants opening e.g. /dev/disk/by-diskseq/1
to be race-free, and that’s bad.
@gregkh @sima @sourcejedi Is this because dev_t
was 32 bits back then?