aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/libertas
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/libertas')
-rw-r--r--drivers/net/wireless/libertas/assoc.c32
-rw-r--r--drivers/net/wireless/libertas/cmd.c5
-rw-r--r--drivers/net/wireless/libertas/debugfs.c6
-rw-r--r--drivers/net/wireless/libertas/main.c9
-rw-r--r--drivers/net/wireless/libertas/scan.c11
-rw-r--r--drivers/net/wireless/libertas/wext.c3
6 files changed, 26 insertions, 40 deletions
diff --git a/drivers/net/wireless/libertas/assoc.c b/drivers/net/wireless/libertas/assoc.c
index 92be60415d04..8b88e9544418 100644
--- a/drivers/net/wireless/libertas/assoc.c
+++ b/drivers/net/wireless/libertas/assoc.c
@@ -151,7 +151,6 @@ static int lbs_adhoc_join(struct lbs_private *priv,
151 struct cmd_ds_802_11_ad_hoc_join cmd; 151 struct cmd_ds_802_11_ad_hoc_join cmd;
152 struct bss_descriptor *bss = &assoc_req->bss; 152 struct bss_descriptor *bss = &assoc_req->bss;
153 u8 preamble = RADIO_PREAMBLE_LONG; 153 u8 preamble = RADIO_PREAMBLE_LONG;
154 DECLARE_MAC_BUF(mac);
155 u16 ratesize = 0; 154 u16 ratesize = 0;
156 int ret = 0; 155 int ret = 0;
157 156
@@ -226,8 +225,8 @@ static int lbs_adhoc_join(struct lbs_private *priv,
226 bss->capability, CAPINFO_MASK); 225 bss->capability, CAPINFO_MASK);
227 226
228 /* information on BSSID descriptor passed to FW */ 227 /* information on BSSID descriptor passed to FW */
229 lbs_deb_join("ADHOC_J_CMD: BSSID = %s, SSID = '%s'\n", 228 lbs_deb_join("ADHOC_J_CMD: BSSID = %pM, SSID = '%s'\n",
230 print_mac(mac, cmd.bss.bssid), cmd.bss.ssid); 229 cmd.bss.bssid, cmd.bss.ssid);
231 230
232 /* Only v8 and below support setting these */ 231 /* Only v8 and below support setting these */
233 if (priv->fwrelease < 0x09000000) { 232 if (priv->fwrelease < 0x09000000) {
@@ -752,17 +751,15 @@ static int assoc_helper_bssid(struct lbs_private *priv,
752{ 751{
753 int ret = 0; 752 int ret = 0;
754 struct bss_descriptor * bss; 753 struct bss_descriptor * bss;
755 DECLARE_MAC_BUF(mac);
756 754
757 lbs_deb_enter_args(LBS_DEB_ASSOC, "BSSID %s", 755 lbs_deb_enter_args(LBS_DEB_ASSOC, "BSSID %pM", assoc_req->bssid);
758 print_mac(mac, assoc_req->bssid));
759 756
760 /* Search for index position in list for requested MAC */ 757 /* Search for index position in list for requested MAC */
761 bss = lbs_find_bssid_in_list(priv, assoc_req->bssid, 758 bss = lbs_find_bssid_in_list(priv, assoc_req->bssid,
762 assoc_req->mode); 759 assoc_req->mode);
763 if (bss == NULL) { 760 if (bss == NULL) {
764 lbs_deb_assoc("ASSOC: WAP: BSSID %s not found, " 761 lbs_deb_assoc("ASSOC: WAP: BSSID %pM not found, "
765 "cannot associate.\n", print_mac(mac, assoc_req->bssid)); 762 "cannot associate.\n", assoc_req->bssid);
766 goto out; 763 goto out;
767 } 764 }
768 765
@@ -1208,7 +1205,6 @@ void lbs_association_worker(struct work_struct *work)
1208 struct assoc_request * assoc_req = NULL; 1205 struct assoc_request * assoc_req = NULL;
1209 int ret = 0; 1206 int ret = 0;
1210 int find_any_ssid = 0; 1207 int find_any_ssid = 0;
1211 DECLARE_MAC_BUF(mac);
1212 1208
1213 lbs_deb_enter(LBS_DEB_ASSOC); 1209 lbs_deb_enter(LBS_DEB_ASSOC);
1214 1210
@@ -1228,13 +1224,13 @@ void lbs_association_worker(struct work_struct *work)
1228 " chann: %d\n" 1224 " chann: %d\n"
1229 " band: %d\n" 1225 " band: %d\n"
1230 " mode: %d\n" 1226 " mode: %d\n"
1231 " BSSID: %s\n" 1227 " BSSID: %pM\n"
1232 " secinfo: %s%s%s\n" 1228 " secinfo: %s%s%s\n"
1233 " auth_mode: %d\n", 1229 " auth_mode: %d\n",
1234 assoc_req->flags, 1230 assoc_req->flags,
1235 escape_essid(assoc_req->ssid, assoc_req->ssid_len), 1231 escape_essid(assoc_req->ssid, assoc_req->ssid_len),
1236 assoc_req->channel, assoc_req->band, assoc_req->mode, 1232 assoc_req->channel, assoc_req->band, assoc_req->mode,
1237 print_mac(mac, assoc_req->bssid), 1233 assoc_req->bssid,
1238 assoc_req->secinfo.WPAenabled ? " WPA" : "", 1234 assoc_req->secinfo.WPAenabled ? " WPA" : "",
1239 assoc_req->secinfo.WPA2enabled ? " WPA2" : "", 1235 assoc_req->secinfo.WPA2enabled ? " WPA2" : "",
1240 assoc_req->secinfo.wep_enabled ? " WEP" : "", 1236 assoc_req->secinfo.wep_enabled ? " WEP" : "",
@@ -1357,8 +1353,8 @@ void lbs_association_worker(struct work_struct *work)
1357 } 1353 }
1358 1354
1359 if (success) { 1355 if (success) {
1360 lbs_deb_assoc("associated to %s\n", 1356 lbs_deb_assoc("associated to %pM\n",
1361 print_mac(mac, priv->curbssparams.bssid)); 1357 priv->curbssparams.bssid);
1362 lbs_prepare_and_send_command(priv, 1358 lbs_prepare_and_send_command(priv,
1363 CMD_802_11_RSSI, 1359 CMD_802_11_RSSI,
1364 0, CMD_OPTION_WAITFORRSP, 0, NULL); 1360 0, CMD_OPTION_WAITFORRSP, 0, NULL);
@@ -1478,7 +1474,6 @@ int lbs_cmd_80211_authenticate(struct lbs_private *priv,
1478 struct cmd_ds_802_11_authenticate *pauthenticate = &cmd->params.auth; 1474 struct cmd_ds_802_11_authenticate *pauthenticate = &cmd->params.auth;
1479 int ret = -1; 1475 int ret = -1;
1480 u8 *bssid = pdata_buf; 1476 u8 *bssid = pdata_buf;
1481 DECLARE_MAC_BUF(mac);
1482 1477
1483 lbs_deb_enter(LBS_DEB_JOIN); 1478 lbs_deb_enter(LBS_DEB_JOIN);
1484 1479
@@ -1505,8 +1500,8 @@ int lbs_cmd_80211_authenticate(struct lbs_private *priv,
1505 1500
1506 memcpy(pauthenticate->macaddr, bssid, ETH_ALEN); 1501 memcpy(pauthenticate->macaddr, bssid, ETH_ALEN);
1507 1502
1508 lbs_deb_join("AUTH_CMD: BSSID %s, auth 0x%x\n", 1503 lbs_deb_join("AUTH_CMD: BSSID %pM, auth 0x%x\n",
1509 print_mac(mac, bssid), pauthenticate->authtype); 1504 bssid, pauthenticate->authtype);
1510 ret = 0; 1505 ret = 0;
1511 1506
1512out: 1507out:
@@ -1770,7 +1765,6 @@ static int lbs_adhoc_post(struct lbs_private *priv, struct cmd_header *resp)
1770 struct cmd_ds_802_11_ad_hoc_result *adhoc_resp; 1765 struct cmd_ds_802_11_ad_hoc_result *adhoc_resp;
1771 union iwreq_data wrqu; 1766 union iwreq_data wrqu;
1772 struct bss_descriptor *bss; 1767 struct bss_descriptor *bss;
1773 DECLARE_MAC_BUF(mac);
1774 1768
1775 lbs_deb_enter(LBS_DEB_JOIN); 1769 lbs_deb_enter(LBS_DEB_JOIN);
1776 1770
@@ -1819,9 +1813,9 @@ static int lbs_adhoc_post(struct lbs_private *priv, struct cmd_header *resp)
1819 wrqu.ap_addr.sa_family = ARPHRD_ETHER; 1813 wrqu.ap_addr.sa_family = ARPHRD_ETHER;
1820 wireless_send_event(priv->dev, SIOCGIWAP, &wrqu, NULL); 1814 wireless_send_event(priv->dev, SIOCGIWAP, &wrqu, NULL);
1821 1815
1822 lbs_deb_join("ADHOC_RESP: Joined/started '%s', BSSID %s, channel %d\n", 1816 lbs_deb_join("ADHOC_RESP: Joined/started '%s', BSSID %pM, channel %d\n",
1823 escape_essid(bss->ssid, bss->ssid_len), 1817 escape_essid(bss->ssid, bss->ssid_len),
1824 print_mac(mac, priv->curbssparams.bssid), 1818 priv->curbssparams.bssid,
1825 priv->curbssparams.channel); 1819 priv->curbssparams.channel);
1826 1820
1827done: 1821done:
diff --git a/drivers/net/wireless/libertas/cmd.c b/drivers/net/wireless/libertas/cmd.c
index 297696de2da0..8542d85f36af 100644
--- a/drivers/net/wireless/libertas/cmd.c
+++ b/drivers/net/wireless/libertas/cmd.c
@@ -87,7 +87,6 @@ int lbs_update_hw_spec(struct lbs_private *priv)
87 struct cmd_ds_get_hw_spec cmd; 87 struct cmd_ds_get_hw_spec cmd;
88 int ret = -1; 88 int ret = -1;
89 u32 i; 89 u32 i;
90 DECLARE_MAC_BUF(mac);
91 90
92 lbs_deb_enter(LBS_DEB_CMD); 91 lbs_deb_enter(LBS_DEB_CMD);
93 92
@@ -110,8 +109,8 @@ int lbs_update_hw_spec(struct lbs_private *priv)
110 * CF card firmware 5.0.16p0: cap 0x00000303 109 * CF card firmware 5.0.16p0: cap 0x00000303
111 * USB dongle firmware 5.110.17p2: cap 0x00000303 110 * USB dongle firmware 5.110.17p2: cap 0x00000303
112 */ 111 */
113 lbs_pr_info("%s, fw %u.%u.%up%u, cap 0x%08x\n", 112 lbs_pr_info("%pM, fw %u.%u.%up%u, cap 0x%08x\n",
114 print_mac(mac, cmd.permanentaddr), 113 cmd.permanentaddr,
115 priv->fwrelease >> 24 & 0xff, 114 priv->fwrelease >> 24 & 0xff,
116 priv->fwrelease >> 16 & 0xff, 115 priv->fwrelease >> 16 & 0xff,
117 priv->fwrelease >> 8 & 0xff, 116 priv->fwrelease >> 8 & 0xff,
diff --git a/drivers/net/wireless/libertas/debugfs.c b/drivers/net/wireless/libertas/debugfs.c
index 0aa0ce3b2c42..5f6bee493f23 100644
--- a/drivers/net/wireless/libertas/debugfs.c
+++ b/drivers/net/wireless/libertas/debugfs.c
@@ -65,7 +65,6 @@ static ssize_t lbs_getscantable(struct file *file, char __user *userbuf,
65 int numscansdone = 0, res; 65 int numscansdone = 0, res;
66 unsigned long addr = get_zeroed_page(GFP_KERNEL); 66 unsigned long addr = get_zeroed_page(GFP_KERNEL);
67 char *buf = (char *)addr; 67 char *buf = (char *)addr;
68 DECLARE_MAC_BUF(mac);
69 struct bss_descriptor * iter_bss; 68 struct bss_descriptor * iter_bss;
70 69
71 pos += snprintf(buf+pos, len-pos, 70 pos += snprintf(buf+pos, len-pos,
@@ -77,10 +76,9 @@ static ssize_t lbs_getscantable(struct file *file, char __user *userbuf,
77 u16 privacy = (iter_bss->capability & WLAN_CAPABILITY_PRIVACY); 76 u16 privacy = (iter_bss->capability & WLAN_CAPABILITY_PRIVACY);
78 u16 spectrum_mgmt = (iter_bss->capability & WLAN_CAPABILITY_SPECTRUM_MGMT); 77 u16 spectrum_mgmt = (iter_bss->capability & WLAN_CAPABILITY_SPECTRUM_MGMT);
79 78
80 pos += snprintf(buf+pos, len-pos, 79 pos += snprintf(buf+pos, len-pos, "%02u| %03d | %04d | %pM |",
81 "%02u| %03d | %04d | %s |",
82 numscansdone, iter_bss->channel, iter_bss->rssi, 80 numscansdone, iter_bss->channel, iter_bss->rssi,
83 print_mac(mac, iter_bss->bssid)); 81 iter_bss->bssid);
84 pos += snprintf(buf+pos, len-pos, " %04x-", iter_bss->capability); 82 pos += snprintf(buf+pos, len-pos, " %04x-", iter_bss->capability);
85 pos += snprintf(buf+pos, len-pos, "%c%c%c |", 83 pos += snprintf(buf+pos, len-pos, "%c%c%c |",
86 ibss ? 'A' : 'I', privacy ? 'P' : ' ', 84 ibss ? 'A' : 'I', privacy ? 'P' : ' ',
diff --git a/drivers/net/wireless/libertas/main.c b/drivers/net/wireless/libertas/main.c
index 73dc8c72402a..34a47f692bd6 100644
--- a/drivers/net/wireless/libertas/main.c
+++ b/drivers/net/wireless/libertas/main.c
@@ -588,7 +588,6 @@ static int lbs_add_mcast_addrs(struct cmd_ds_mac_multicast_adr *cmd,
588{ 588{
589 int i = nr_addrs; 589 int i = nr_addrs;
590 struct dev_mc_list *mc_list; 590 struct dev_mc_list *mc_list;
591 DECLARE_MAC_BUF(mac);
592 591
593 if ((dev->flags & (IFF_UP|IFF_MULTICAST)) != (IFF_UP|IFF_MULTICAST)) 592 if ((dev->flags & (IFF_UP|IFF_MULTICAST)) != (IFF_UP|IFF_MULTICAST))
594 return nr_addrs; 593 return nr_addrs;
@@ -596,16 +595,16 @@ static int lbs_add_mcast_addrs(struct cmd_ds_mac_multicast_adr *cmd,
596 netif_addr_lock_bh(dev); 595 netif_addr_lock_bh(dev);
597 for (mc_list = dev->mc_list; mc_list; mc_list = mc_list->next) { 596 for (mc_list = dev->mc_list; mc_list; mc_list = mc_list->next) {
598 if (mac_in_list(cmd->maclist, nr_addrs, mc_list->dmi_addr)) { 597 if (mac_in_list(cmd->maclist, nr_addrs, mc_list->dmi_addr)) {
599 lbs_deb_net("mcast address %s:%s skipped\n", dev->name, 598 lbs_deb_net("mcast address %s:%pM skipped\n", dev->name,
600 print_mac(mac, mc_list->dmi_addr)); 599 mc_list->dmi_addr);
601 continue; 600 continue;
602 } 601 }
603 602
604 if (i == MRVDRV_MAX_MULTICAST_LIST_SIZE) 603 if (i == MRVDRV_MAX_MULTICAST_LIST_SIZE)
605 break; 604 break;
606 memcpy(&cmd->maclist[6*i], mc_list->dmi_addr, ETH_ALEN); 605 memcpy(&cmd->maclist[6*i], mc_list->dmi_addr, ETH_ALEN);
607 lbs_deb_net("mcast address %s:%s added to filter\n", dev->name, 606 lbs_deb_net("mcast address %s:%pM added to filter\n", dev->name,
608 print_mac(mac, mc_list->dmi_addr)); 607 mc_list->dmi_addr);
609 i++; 608 i++;
610 } 609 }
611 netif_addr_unlock_bh(dev); 610 netif_addr_unlock_bh(dev);
diff --git a/drivers/net/wireless/libertas/scan.c b/drivers/net/wireless/libertas/scan.c
index 8f66903641b9..fcaef38d5df9 100644
--- a/drivers/net/wireless/libertas/scan.c
+++ b/drivers/net/wireless/libertas/scan.c
@@ -359,7 +359,6 @@ int lbs_scan_networks(struct lbs_private *priv, int full_scan)
359#ifdef CONFIG_LIBERTAS_DEBUG 359#ifdef CONFIG_LIBERTAS_DEBUG
360 struct bss_descriptor *iter; 360 struct bss_descriptor *iter;
361 int i = 0; 361 int i = 0;
362 DECLARE_MAC_BUF(mac);
363#endif 362#endif
364 363
365 lbs_deb_enter_args(LBS_DEB_SCAN, "full_scan %d", full_scan); 364 lbs_deb_enter_args(LBS_DEB_SCAN, "full_scan %d", full_scan);
@@ -451,8 +450,8 @@ int lbs_scan_networks(struct lbs_private *priv, int full_scan)
451 mutex_lock(&priv->lock); 450 mutex_lock(&priv->lock);
452 lbs_deb_scan("scan table:\n"); 451 lbs_deb_scan("scan table:\n");
453 list_for_each_entry(iter, &priv->network_list, list) 452 list_for_each_entry(iter, &priv->network_list, list)
454 lbs_deb_scan("%02d: BSSID %s, RSSI %d, SSID '%s'\n", 453 lbs_deb_scan("%02d: BSSID %pM, RSSI %d, SSID '%s'\n",
455 i++, print_mac(mac, iter->bssid), iter->rssi, 454 i++, iter->bssid, iter->rssi,
456 escape_essid(iter->ssid, iter->ssid_len)); 455 escape_essid(iter->ssid, iter->ssid_len));
457 mutex_unlock(&priv->lock); 456 mutex_unlock(&priv->lock);
458#endif 457#endif
@@ -512,7 +511,6 @@ static int lbs_process_bss(struct bss_descriptor *bss,
512 struct ieeetypes_dsparamset *pDS; 511 struct ieeetypes_dsparamset *pDS;
513 struct ieeetypes_cfparamset *pCF; 512 struct ieeetypes_cfparamset *pCF;
514 struct ieeetypes_ibssparamset *pibss; 513 struct ieeetypes_ibssparamset *pibss;
515 DECLARE_MAC_BUF(mac);
516 struct ieeetypes_countryinfoset *pcountryinfo; 514 struct ieeetypes_countryinfoset *pcountryinfo;
517 uint8_t *pos, *end, *p; 515 uint8_t *pos, *end, *p;
518 uint8_t n_ex_rates = 0, got_basic_rates = 0, n_basic_rates = 0; 516 uint8_t n_ex_rates = 0, got_basic_rates = 0, n_basic_rates = 0;
@@ -544,7 +542,7 @@ static int lbs_process_bss(struct bss_descriptor *bss,
544 *bytesleft -= beaconsize; 542 *bytesleft -= beaconsize;
545 543
546 memcpy(bss->bssid, pos, ETH_ALEN); 544 memcpy(bss->bssid, pos, ETH_ALEN);
547 lbs_deb_scan("process_bss: BSSID %s\n", print_mac(mac, bss->bssid)); 545 lbs_deb_scan("process_bss: BSSID %pM\n", bss->bssid);
548 pos += ETH_ALEN; 546 pos += ETH_ALEN;
549 547
550 if ((end - pos) < 12) { 548 if ((end - pos) < 12) {
@@ -1151,7 +1149,6 @@ static int lbs_ret_80211_scan(struct lbs_private *priv, unsigned long dummy,
1151 struct bss_descriptor new; 1149 struct bss_descriptor new;
1152 struct bss_descriptor *found = NULL; 1150 struct bss_descriptor *found = NULL;
1153 struct bss_descriptor *oldest = NULL; 1151 struct bss_descriptor *oldest = NULL;
1154 DECLARE_MAC_BUF(mac);
1155 1152
1156 /* Process the data fields and IEs returned for this BSS */ 1153 /* Process the data fields and IEs returned for this BSS */
1157 memset(&new, 0, sizeof (struct bss_descriptor)); 1154 memset(&new, 0, sizeof (struct bss_descriptor));
@@ -1190,7 +1187,7 @@ static int lbs_ret_80211_scan(struct lbs_private *priv, unsigned long dummy,
1190 continue; 1187 continue;
1191 } 1188 }
1192 1189
1193 lbs_deb_scan("SCAN_RESP: BSSID %s\n", print_mac(mac, new.bssid)); 1190 lbs_deb_scan("SCAN_RESP: BSSID %pM\n", new.bssid);
1194 1191
1195 /* Copy the locally created newbssentry to the scan table */ 1192 /* Copy the locally created newbssentry to the scan table */
1196 memcpy(found, &new, offsetof(struct bss_descriptor, list)); 1193 memcpy(found, &new, offsetof(struct bss_descriptor, list));
diff --git a/drivers/net/wireless/libertas/wext.c b/drivers/net/wireless/libertas/wext.c
index 82c3e5a50ea6..04f0bf2ef0a8 100644
--- a/drivers/net/wireless/libertas/wext.c
+++ b/drivers/net/wireless/libertas/wext.c
@@ -2104,7 +2104,6 @@ static int lbs_set_wap(struct net_device *dev, struct iw_request_info *info,
2104 struct lbs_private *priv = dev->priv; 2104 struct lbs_private *priv = dev->priv;
2105 struct assoc_request * assoc_req; 2105 struct assoc_request * assoc_req;
2106 int ret = 0; 2106 int ret = 0;
2107 DECLARE_MAC_BUF(mac);
2108 2107
2109 lbs_deb_enter(LBS_DEB_WEXT); 2108 lbs_deb_enter(LBS_DEB_WEXT);
2110 2109
@@ -2114,7 +2113,7 @@ static int lbs_set_wap(struct net_device *dev, struct iw_request_info *info,
2114 if (awrq->sa_family != ARPHRD_ETHER) 2113 if (awrq->sa_family != ARPHRD_ETHER)
2115 return -EINVAL; 2114 return -EINVAL;
2116 2115
2117 lbs_deb_wext("ASSOC: WAP: sa_data %s\n", print_mac(mac, awrq->sa_data)); 2116 lbs_deb_wext("ASSOC: WAP: sa_data %pM\n", awrq->sa_data);
2118 2117
2119 mutex_lock(&priv->lock); 2118 mutex_lock(&priv->lock);
2120 2119