Mailinglist Archive: opensuse (4343 mails)

< Previous Next >
how to configure wireless cards to be other than "eth#"?
  • From: Tom Emerson <osnut@xxxxxxxxxxx>
  • Date: Thu, 07 Nov 2002 11:48:15 -0800
  • Message-id: <200211071148.15982.osnut@xxxxxxxxxxx>
Actually, I think I already know the answer to this, and the short version is
"you can't" [without patching the source].

Here's the problem: I have a laptop and two network interfaces: one wired, the
other wireless. They both configure themselves as an "ethX" device, which
means the order I insert them and/or which slots I place them in becomes
important -- for instance, some programs "expect" the wireless card to be
"eth1", but if I start the system with only the wireless card installed (or
in the "lower" slot), the system configures it as "eth0".

Digging through the source, I found that the particular card's driver
(orinoco_cs.c) makes a call to "register_netdev", which (per the nearby
comments) is what actually allocates an "ethX" device name. This leads to a
potential solution: the structure passed to register_netdev has a "name"
field which can be used to specify a name other than "eth" as the base name
of the device(s) allocated. By using a non-default name (such as "wlan")
instead of "eth", I can then keep the wired and wireless devices "consistent"
no matter which ones are actually installed or in which slots.

But, as implied here, this is a "patch to the source", not a trivial
/etc/sysconfig parameter adjustment. Further, changing the name *may* break
the way SuSE "recognizes" the device for configuration (then again, it may
help -- at one point I tried the "wlan-ng" drivers, which uses the name
"wlanX" instead of "ethX", and SuSE complained that it didn't have a "ifcfg"
file with "wlan" as part of the name)

So, what to do? Patching the orinoco_cs file only helps *me* -- from digging
around, this "patch" would have to be applied to EVERY wireless card driver
AND "fixing" all the subordinate programs to recognize that "from now on",
the name would be something other than "eth..." [which, as implied, might not
be a bad thing] However, I do think SuSE has "optimized" their configuration
scripts to use the name "eth" regardless of whether or not the card is
wireless, but as you can see, this is what lead to the problem in the first
place...



< Previous Next >
This Thread
  • No further messages