qcacld-3.0: Move call to hdd power stats callback inside lock
Currently when host receives power stats from fw, before processing these stats it check for the hdd callback and processes these stats only if hdd callback is registered. This callback is checked in wma_unified_power_debug_stats_event_handler function before processing of the fw event and outside of any lock. After processing stats, this hdd cb is invoked, there is an issue with this approach that while processing these stats if timeout happens in hdd then hdd sets its callback as NULL and now after processing stats wma handler invokes this hdd cb which is already NULL, leading to null pointer dereference. To avoid above issue, add sme callback and move null check for hdd cb and call to hdd cb inside sme lock which is the same lock used while setting hdd cb to null on timeout. Change-Id: I2203083a17ca3404c5c5af98ddc48ba127e6aee2 CRs-Fixed: 2950633
Loading
Please register or sign in to comment