Subject: changing wi(4) MAC address
To: None <tech-net@NetBSD.org>
From: Lord Isildur <mrfusion@vaxpower.org>
List: tech-net
Date: 08/09/2005 15:39:28
so, i finally got tired of not being able
to set the mac address on wi devices... so i fixed it.
it's just a few lines, but now e.g. wiconfig -m works again.
here's a diff from the -current sources of /sys/dev/ic/wi.c :
15:29:35 vinyalonde $ diff wi.c wi.c.new
2307a2308,2312
> case WI_RID_MAC_NODE:
> memcpy(ic->ic_myaddr, wreq.wi_val, ETHER_ADDR_LEN);
> IEEE80211_ADDR_COPY(LLADDR(ifp->if_sadl),ic->ic_myaddr);
> wi_write_rid(sc, WI_RID_MAC_NODE, ic->ic_myaddr,
IEEE80211_ADDR_LEN);
> break;
a full copy of my updated wi.c is here:
http://www.vaxpower.org/~isildur/wi.c.new
http://www.vaxpower.org/~isildur/wi.c.new.MD5
happy hacking,
isildur