wcnss: fix the potential buffer flow issue in firmware setup

Add the check against negative or invalid firmware size passed
by the userspace thread in firmware setup sysfs write operation.
Update the datatype of the variable which holds the firmware size
passed by userspace thread during firmware setup and WLAN calibration
data update process.

CRs-Fixed: 2072966
Change-Id: I8c84ad0d1b0a5f44a39c9c5b228734b0f693e8dd
Signed-off-by: Sarada Prasanna Garnayak <sgarna@codeaurora.org>
This commit is contained in:
Sarada Prasanna Garnayak 2017-07-11 13:01:19 +05:30 committed by Gerrit - the friendly Code Review server
parent 603f4b87cd
commit 2b330892e5
1 changed files with 1 additions and 1 deletions

View File

@ -399,7 +399,7 @@ static struct {
int user_cal_read;
int user_cal_available;
u32 user_cal_rcvd;
int user_cal_exp_size;
u32 user_cal_exp_size;
int iris_xo_mode_set;
int fw_vbatt_state;
char wlan_nv_macAddr[WLAN_MAC_ADDR_SIZE];