[openbeosnetteam] Re: Interfaces
- From: Oliver Tappe <openbeos@xxxxxxxxxxxxxxx>
- To: openbeosnetteam@xxxxxxxxxxxxx
- Date: Tue, 11 Jul 2006 15:26:22 +0200
Hi Axel,
On 2006-07-11 at 02:56:47 [+0200], Axel Dörfler <axeld@xxxxxxxxxxxxxxxx>
wrote:
> Hi there,
>
> I've got a little naming problem. The current naming scheme is a bit
> confusing, and it would be nice to improve it early on.
>
> Right now, there is a:
> * net_interface - this is a structure that holds information about the
> interface as registered by the interface module, ie. the interface type
> (IFT_ETHER). In BONE and BSD, this structure is called ifnet
> * net_module_interface - (private) this is a structure that wraps
> net_interface plus a module pointer and a reference counter.
> * net_logical_interface - this structure is a logical interface that is
> bound to the net_interface and has an address in a specific domain (ie.
> 192.168.0.1 in the AF_INET domain). The BONE/BSD equivalent is called
> lognet.
> * and if that wouldn't be enough, there is a
> net_logical_interface_private structure that inherits from
> net_logical_interface, and adds some private fields that are not
> thought for public consumption. In BONE/BSD, there is no
> differentiation between public and private in this regard.
>
> The term "networking interface" is mostly bound to the logical
> interface. "ifconf" is actually configuring them, for example (but also
> creates the interface behind it).
> Do you have any idea for a better naming scheme that is less long but
> also less confusing?
>
> Examples of the net_interface modules are ethernet, loopback, ppp, ...
> (which all will implement the net_interface_module_info structure).
> It's not necessarily a device, but we could rename that lower interface
> to net_device. Transport would be another idea. But anyway, I'm open
> for input :-)
FWIW, here are my ideas:
net_interface => net_device
net_module_interface => net_interface
net_logical_interface => net_interface_configuration
net_logical_interface_private => net_interface_configuration_private
Then net_device would hold device specific info (although sometimes the
device is virtual of course).
I know this violates the general notion of a device being a piece of hardware
and an interface being the software representation of that hardware, but for
my liking there are currently to many different kinds of interfaces. That's
why I like your suggestion of using 'net_device' for the per-device
structure. Additionally, that would fit very nicely with the function
net_interface_removed() which could then be renamed to net_device_removed()
(as what has actually been removed is the device, not the interface).
I personally don't like 'net_module_interface' very much, as I don't get what
the name is trying to tell me. It sounds like the interface of a network
module, but it seems to be the interface type handled by the network stack
module, right?
Renaming net_logical_interface to net_interface_configuration (or maybe just
net_interface_config?) doesn't really help much, but I find it communicates
better the fact that it represents an interface instance as configured by
means of ifconfig.
cheers,
Oliver
- Follow-Ups:
- [openbeosnetteam] Re: Interfaces
- From: Axel Dörfler
- References:
- [openbeosnetteam] Interfaces
- From: Axel Dörfler
Other related posts:
- » [openbeosnetteam] Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- » [openbeosnetteam] Re: Interfaces
- [openbeosnetteam] Re: Interfaces
- From: Axel Dörfler
- [openbeosnetteam] Interfaces
- From: Axel Dörfler