summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/toshiba/ps3_gelic_wireless.c
diff options
context:
space:
mode:
authorChristophe Jaillet <christophe.jaillet@wanadoo.fr>2016-04-26 04:33:43 +0200
committerDavid S. Miller <davem@davemloft.net>2016-04-28 16:37:56 -0400
commiteb63efb4f263f1f4c2375731d3a9e2040030bc6a (patch)
tree18ee7bf0ac93e95b7ccc56d7071d586cb2dc418c /drivers/net/ethernet/toshiba/ps3_gelic_wireless.c
parent14437e3fa284f465dbbc8611fd4331ca8d60e986 (diff)
downloadlinux-eb63efb4f263f1f4c2375731d3a9e2040030bc6a.tar.gz
linux-eb63efb4f263f1f4c2375731d3a9e2040030bc6a.tar.xz
ps3_gelic: fix memcpy parameter
The size allocated for target->hwinfo and the number of bytes copied in it should be consistent. Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/toshiba/ps3_gelic_wireless.c')
-rw-r--r--drivers/net/ethernet/toshiba/ps3_gelic_wireless.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/toshiba/ps3_gelic_wireless.c b/drivers/net/ethernet/toshiba/ps3_gelic_wireless.c
index 13214a6492ac..743b18266a7c 100644
--- a/drivers/net/ethernet/toshiba/ps3_gelic_wireless.c
+++ b/drivers/net/ethernet/toshiba/ps3_gelic_wireless.c
@@ -1622,7 +1622,7 @@ static void gelic_wl_scan_complete_event(struct gelic_wl_info *wl)
continue;
/* copy hw scan info */
- memcpy(target->hwinfo, scan_info, scan_info->size);
+ memcpy(target->hwinfo, scan_info, be16_to_cpu(scan_info->size));
target->essid_len = strnlen(scan_info->essid,
sizeof(scan_info->essid));
target->rate_len = 0;