For that matter, what exactly was wrong with a bunch of static files in
/dev? It's apparently unsatisfactory enough for developers to have reinvented this wheel by my count 3 times now (
udev + HAL ->
udev), and now apparently it's going into the Grand Unified Init Program too, so four times.
I remember when I first started using Linux years ago being surprised that despite claims that "everything is a file", there's no
/dev/eth0 (that later made sense, since it isn't a char or block device -- though a "packet" device type would be interesting...). Given that, why is the program that handles the char and block device file tree also responsible for network devices? I've seen vague references to "flexibility", but what does this add over what, say, ifconfig(8) does by just looking in
/proc/net/dev? I know, for instance, NetworkManager won't be in Net or OpenBSD any time soon because it depends on
udev, which neither team wants to write; what I don't understand is why a program that at least nominally is there to manage the
/dev tree is apparently the only way to expose network devices that are already exposed multiple ways by the kernel (and none of them in
Is it just because of hotplugging? Were there problems with the kernel just listening to the physical buses and loading the appropriate modules on an "device added" message? Or, God forbid, the actual administrator doing so? I do remember back in the early 2000's my servers would sometimes initialize their network cards in an unexpected order, and I suppose it makes sense to have that naming be decided in userland (though it wasn't terribly hard to fix back then), but this seems like a sledgehammer for a cockroach. (Or maybe that problem hits use cases I'm not thinking about much harder than rackmounted servers or PCs, which are my experience.)
So, to state my question plainly: what problems does udev actually solve, and how did devfs, HAL, and/or a plain old file fail to solve them? Is there a particular reason for that many different things (hotplugging, general device management, network device management, device naming, driver priority, etc.) to all be one program?