On Tue, Nov 19, 2002 at 11:24:10AM -0800, Rich Morin wrote:
> At 10:37 AM -0800 11/19/02, Brooks Davis wrote:
> >Once the if_xname patch is in, it will be exceedingly simple to add some
> >code to ether_ifattach to do that if you really want.
> 
> Well, _I_ really want FreeBSD to move in the direction of "plug and play";
> this is merely one small contribution.  That said, I have some questions
> about your suggestion:
> 
>    *  Would it handle non-Ethernet network interfaces?  If not, perhaps it's
>       not at the right level of generality.

It depends what you mean by non-Ethernet interfaces.  If you mean
802.11b wireless, those are ethernet interfaces.  If you mean tokenring,
that would require a seperate hack, but is possiable (though it would be
a bit silly to call a tokenring interface eth0).  I suppose you could
implement an even uglier hack and rename everything to if#, but I think
that would result in a flameware of epic proportions.

Note that none of these ideas really helps my laptop since I've always
got an ethernet interface via the 3com mini-pci card, but sometimes I
want to use the wireless card.

I don't think interface renaming could be turned on by default without
a big fight, but it might be worth the effort eventualy (I don't really
have a firm opinion).

>    *  Would your change be smaller (or better in some other way) than the
>       half-dozen lines of code René has proposed?

It would be very small since it would just need to track the list of
allocated units (an int would do it) and do an snprintf into the
if_xname value.  It would also be in-kernel so you'd be able to talk
about the interface consistantly instead of using one name in rc.conf
and another everywhere else.

>    *  What is the timing on the if_xname patch?  Is it imminent or merely
>       "in the works"?  Can you provide a URL (or an explanation) of what
>       this patch is intended to do?

It's a .0 feature since it breaks the kernel API/ABI for network
drivers, but I'm hopeful that we'll ship it in 5.0.  There's been some
recent discussion of it on -hackers and cvs-all with some older
discusssion on -net.   There's a large patch at:

http://people.freebsd.org/~brooks/patches/if_xname.diff

Most if it is really just string format changes.

-- Brooks

-- 
Any statement of the form "X is the one, true Y" is FALSE.
PGP fingerprint 655D 519C 26A7 82E7 2529  9BF0 5D8E 8BE9 F238 1AD4

Attachment: msg38193/pgp00000.pgp
Description: PGP signature

Reply via email to