diff options
author | James <> | 2013-03-17 12:16:37 +0000 |
---|---|---|
committer | James <> | 2013-03-17 12:16:37 +0000 |
commit | 27b76ab0671089c47506615a796a261e993896a7 (patch) | |
tree | 61213d67e7fa87b20356b23798558e2c4212c42f /package/acx-mac80211/patches/.svn/text-base/200-initial-macaddr.patch.svn-base | |
download | trunk-36060-27b76ab0671089c47506615a796a261e993896a7.tar.gz trunk-36060-27b76ab0671089c47506615a796a261e993896a7.tar.bz2 trunk-36060-27b76ab0671089c47506615a796a261e993896a7.zip |
Diffstat (limited to 'package/acx-mac80211/patches/.svn/text-base/200-initial-macaddr.patch.svn-base')
-rw-r--r-- | package/acx-mac80211/patches/.svn/text-base/200-initial-macaddr.patch.svn-base | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/package/acx-mac80211/patches/.svn/text-base/200-initial-macaddr.patch.svn-base b/package/acx-mac80211/patches/.svn/text-base/200-initial-macaddr.patch.svn-base new file mode 100644 index 0000000..cc82fec --- /dev/null +++ b/package/acx-mac80211/patches/.svn/text-base/200-initial-macaddr.patch.svn-base @@ -0,0 +1,31 @@ +--- a/cardsetting.c ++++ b/cardsetting.c +@@ -710,12 +710,27 @@ static int acx1xx_get_station_id(acx_dev + u8 stationID[4 + acx_ie_descs[ACX1xx_IE_DOT11_STATION_ID].len]; + const u8 *paddr; + int i, res; ++ const char *prom_addr; ++ char *prom_getenv(const char *name); + + + + res = acx_interrogate(adev, &stationID, ACX1xx_IE_DOT11_STATION_ID); + paddr = &stationID[4]; +- for (i = 0; i < ETH_ALEN; i++) { ++ prom_addr = NULL; ++#ifdef CONFIG_VLYNQ ++ prom_addr = prom_getenv("macwlan"); ++ if (prom_addr == NULL) ++ prom_addr = prom_getenv("mac_ap"); ++#endif ++ if (prom_addr) ++ sscanf(prom_addr, "%hhx:%hhx:%hhx:%hhx:%hhx:%hhx", adev->dev_addr, ++ adev->dev_addr + 1, ++ adev->dev_addr + 2, ++ adev->dev_addr + 3, ++ adev->dev_addr + 4, ++ adev->dev_addr + 5); ++ else for (i = 0; i < ETH_ALEN; i++) { + /* we copy the MAC address (reversed in the card) to + * the netdevice's MAC address, and on ifup it will be + * copied into iwadev->dev_addr */ |