From 87b2bb74dffc92e9156965005bec1fd43ca3d7ac Mon Sep 17 00:00:00 2001 From: Ganesh Kondabattini Date: Fri, 22 Apr 2016 20:29:52 +0530 Subject: qcacld-2.0: Update the unsafe channel list to the platform driver Before sending the unsafe channel list to the application, first update the platform driver so that other driver who is reading the channel list from platform driver will get the correct channel list. Change-Id: I72421f80e1e354039eee2fc87b5f988592e33c9c CRs-Fixed: 998048 --- CORE/HDD/src/wlan_hdd_main.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/CORE/HDD/src/wlan_hdd_main.c b/CORE/HDD/src/wlan_hdd_main.c index bbb6c126f149..1733c0ce581d 100644 --- a/CORE/HDD/src/wlan_hdd_main.c +++ b/CORE/HDD/src/wlan_hdd_main.c @@ -16529,7 +16529,6 @@ void hdd_ch_avoid_cb } hdd_avoid_freq_list.avoidFreqRangeCount = ch_avoid_indi->avoid_range_count; - wlan_hdd_send_avoid_freq_event(hdd_ctxt, &hdd_avoid_freq_list); /* clear existing unsafe channel cache */ hdd_ctxt->unsafe_channel_count = 0; @@ -16624,10 +16623,16 @@ void hdd_ch_avoid_cb } #endif - if (0 == hdd_ctxt->unsafe_channel_count) + /* + * first update the unsafe channel list to the platform driver and + * send the avoid freq event to the application + */ + wlan_hdd_send_avoid_freq_event(hdd_ctxt, &hdd_avoid_freq_list); + + if (0 == hdd_ctxt->unsafe_channel_count) return; - hdd_unsafe_channel_restart_sap(hdd_ctxt); - return; + hdd_unsafe_channel_restart_sap(hdd_ctxt); + return; } #endif /* FEATURE_WLAN_CH_AVOID */ -- cgit v1.2.3