[svlug] Inits (was: On the process of picking up systemd)

Alison Chaiken alison at she-devel.com
Sat Jan 17 18:09:06 PST 2015

Akk remarks:

> In other words, how does it get from NAME="eth0" to network
> libraries getting packets through a specific piece of hardware,
> considering it's not creating a /dev node? If so ... no. I've never
> been clear how that works, and I don't think it has anything to do
> with /sys/class nodes because I'm pretty sure networking libraries
> worked pretty much like they do now long before /sys/class even
> existed in the kernel.

Sysfs is the kernel's holy ABI towards userspace, the one that the cursing
Linus is always warning developers not to break.  Kernel bits do not talk
to one another through sysfs.   They use internal kernel APIs, which are
subject to change every release.

>  why network drivers don't create a /dev node
> like nearly every other type of device driver.

The APIs that userspace applies to /dev nodes are meaningless for network
devices.     There are two kinds of devices in /dev: character devices to
whom operations like "open" and "read" apply, and block devices to whom
operations like "malloc" and "mmap" apply.   Neither of those sets of
operations make sense for networks.   Networks are addressable by files,
though: the Unix and internet domain sockets.    Those are not, by
convention, created in /dev.

Now I'm genuinely going to stop avoiding work by posting on mailing list!

-- Alison

Alison Chaiken                           alison at she-devel.com
650-279-5600                            http://{she-devel.com,
Never underestimate the cleverness of advertisers, or mischief makers, or
criminals.  -- Don Norman
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.svlug.org/archives/svlug/attachments/20150117/1d49ac50/attachment.htm

More information about the svlug mailing list