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/cmd.c4
-rw-r--r--drivers/net/wireless/libertas/scan.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/wireless/libertas/cmd.c b/drivers/net/wireless/libertas/cmd.c
index 8542d85f36af..d45b07cf6a62 100644
--- a/drivers/net/wireless/libertas/cmd.c
+++ b/drivers/net/wireless/libertas/cmd.c
@@ -604,9 +604,9 @@ int lbs_get_tx_power(struct lbs_private *priv, s16 *curlevel, s16 *minlevel,
604 if (ret == 0) { 604 if (ret == 0) {
605 *curlevel = le16_to_cpu(cmd.curlevel); 605 *curlevel = le16_to_cpu(cmd.curlevel);
606 if (minlevel) 606 if (minlevel)
607 *minlevel = le16_to_cpu(cmd.minlevel); 607 *minlevel = cmd.minlevel;
608 if (maxlevel) 608 if (maxlevel)
609 *maxlevel = le16_to_cpu(cmd.maxlevel); 609 *maxlevel = cmd.maxlevel;
610 } 610 }
611 611
612 lbs_deb_leave(LBS_DEB_CMD); 612 lbs_deb_leave(LBS_DEB_CMD);
diff --git a/drivers/net/wireless/libertas/scan.c b/drivers/net/wireless/libertas/scan.c
index fcaef38d5df9..351b3f6e5664 100644
--- a/drivers/net/wireless/libertas/scan.c
+++ b/drivers/net/wireless/libertas/scan.c
@@ -596,8 +596,8 @@ static int lbs_process_bss(struct bss_descriptor *bss,
596 596
597 switch (elem->id) { 597 switch (elem->id) {
598 case MFIE_TYPE_SSID: 598 case MFIE_TYPE_SSID:
599 bss->ssid_len = elem->len; 599 bss->ssid_len = min_t(int, 32, elem->len);
600 memcpy(bss->ssid, elem->data, elem->len); 600 memcpy(bss->ssid, elem->data, bss->ssid_len);
601 lbs_deb_scan("got SSID IE: '%s', len %u\n", 601 lbs_deb_scan("got SSID IE: '%s', len %u\n",
602 escape_essid(bss->ssid, bss->ssid_len), 602 escape_essid(bss->ssid, bss->ssid_len),
603 bss->ssid_len); 603 bss->ssid_len);