staging: wlan-ng: prism2mgmt.c: fixed a double endian conversion before calling hfa38...
authorAndrea della Porta <sfaragnaus@gmail.com>
Sat, 29 Apr 2017 06:30:23 +0000 (07:30 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 15 May 2017 05:43:55 +0000 (07:43 +0200)
commitdea20579a69ab68cdca6adf79bb7c0c162eb9b72
treeb6be25f3bd26022d27be8bc695f377b4f2aa3885
parent9bbf84e6041fb0d7f67208ec8557473ffcd7157c
staging: wlan-ng: prism2mgmt.c: fixed a double endian conversion before calling hfa384x_drvr_setconfig16, also fixes relative sparse warning

staging: wlan-ng: prism2mgmt.c: This patches fixes a double endian conversion.
cpu_to_le16() was called twice first in prism2mgmt_scan and again inside
hfa384x_drvr_setconfig16() for the same variable, hence it was swapped
twice. Incidentally, it also fixed the following sparse warning:

drivers/staging/wlan-ng/prism2mgmt.c:173:30: warning: incorrect type in assignment (different base types)
drivers/staging/wlan-ng/prism2mgmt.c:173:30:    expected unsigned short [unsigned] [usertype] word
drivers/staging/wlan-ng/prism2mgmt.c:173:30:    got restricted __le16 [usertype] <noident>

Unfortunately, only compile tested.

Signed-off-by: Andrea della Porta <sfaragnaus@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/wlan-ng/prism2mgmt.c