wlan: Synchronize the ROC cancel and completion functions
While performing cancel existing remain on channel, remain on channel
callback is scheduled due to remain on channel timeout. As
a part of remain on channel callback, the remain_on_chan_ctx is freed
and later which will be de-referenced in cancel_existing_remain_on_chan
function when shceduled, leads to crash.
To mitigate this issue, synchronize the logic of cancelling existing
ROC and ROC completion on timeout by acquiring mutex locks.
Change-Id: I25e623067083d17bc0604349f0ab734c6b379f25
CRs-Fixed: 732460
3 files changed