[PATCH 15/16] use-regular-eth-suffix.diff

From: Jan Engelhardt
Date: Sun Apr 01 2007 - 14:20:40 EST



Some radio adapter drivers wrongly(?) name their devices "wlan%d"
instead of "eth%d" (if you ask me, it should be %u - but not today).

Technically, they operate like Ethernet, and in fact, running
`/sbin/ip a` shows "link/ether" instead of "link/ieee80211".
This patch renames them back, but I would appreciate some comment,
explanation or at least link why they actually have wlan%d there.

Signed-off-by: Jan Engelhardt <jengelh@xxxxxx>
Cc: Jouni Malinen <jkmaline@xxxxxxxxx> (hostap)
Cc: Jeroen Vreeken <pe1rxq@xxxxxxxxx> (zd1201)

hostap/hostap_hw.c | 4 ++--
zd1201.c | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)

Index: linux-2.6.21-rc5/drivers/net/wireless/hostap/hostap_hw.c
===================================================================
--- linux-2.6.21-rc5.orig/drivers/net/wireless/hostap/hostap_hw.c
+++ linux-2.6.21-rc5/drivers/net/wireless/hostap/hostap_hw.c
@@ -81,10 +81,10 @@ static int dtim_period[MAX_PARM_DEVICES]
module_param_array(dtim_period, int, NULL, 0444);
MODULE_PARM_DESC(dtim_period, "DTIM period");

-static char dev_template[16] = "wlan%d";
+static char dev_template[16] = "eth%d";
module_param_string(dev_template, dev_template, sizeof(dev_template), 0444);
MODULE_PARM_DESC(dev_template, "Prefix for network device name (default: "
- "wlan%d)");
+ "eth%d)");

#ifdef final_version
#define EXTRA_EVENTS_WTERR 0
Index: linux-2.6.21-rc5/drivers/net/wireless/zd1201.c
===================================================================
--- linux-2.6.21-rc5.orig/drivers/net/wireless/zd1201.c
+++ linux-2.6.21-rc5/drivers/net/wireless/zd1201.c
@@ -1787,7 +1787,7 @@ static int zd1201_probe(struct usb_inter
zd->dev->tx_timeout = zd1201_tx_timeout;
zd->dev->set_multicast_list = zd1201_set_multicast;
zd->dev->set_mac_address = zd1201_set_mac_address;
- strcpy(zd->dev->name, "wlan%d");
+ strcpy(zd->dev->name, "eth%d");

err = zd1201_getconfig(zd, ZD1201_RID_CNFOWNMACADDR,
zd->dev->dev_addr, zd->dev->addr_len);
#<EOF>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/