OSDN Git Service

wcnss: fix the race condition issue during cal data extraction
authorSarada Prasanna Garnayak <sgarna@codeaurora.org>
Mon, 17 Apr 2017 09:18:16 +0000 (14:48 +0530)
committerGerrit - the friendly Code Review server <code-review@localhost>
Mon, 24 Apr 2017 08:48:36 +0000 (01:48 -0700)
commitbf00f329747180da4201f28bb9f9a8389fe957f4
tree52cf1137c52744b78a7a73ea4c05ccac3f65c800
parent6cf6835d964a71fa857d03f8e2f28a581da3b3b2
wcnss: fix the race condition issue during cal data extraction

The wcnss platform driver update the wlan calibration data
by the user space wlan daemon. The wlan user space daemon store
the updated wlan calibration data reported by wlan firmware in
user space and write it back to the wcnss platform calibration
data buffer for the calibration data download and update.

During the wlan calibration data extraction there are some potential
race condition which leads to memory leak and buffer overflow during
the context switch. Fix the above issue by adding protection code.

CRs-Fixed: 2015791
Change-Id: I231807f6b2d8094d7138b95c659ed6272897ba2d
Signed-off-by: Sarada Prasanna Garnayak <sgarna@codeaurora.org>
drivers/net/wireless/wcnss/wcnss_wlan.c