qcacld-3.0: Conditionally disable channel 144 in wiphy

If channel 144 is disabled in service ready event, host is only
disabling the channel in corestack. Fix that by also disabling the
channel in wiphy, which is used by kernel and user-space.

Change-Id: I4222aef646ede78d97b554faaf7f0c5b627feec0
CRs-Fixed: 1054102
diff --git a/core/hdd/src/wlan_hdd_regulatory.c b/core/hdd/src/wlan_hdd_regulatory.c
index c96f8ef..69218fb 100644
--- a/core/hdd/src/wlan_hdd_regulatory.c
+++ b/core/hdd/src/wlan_hdd_regulatory.c
@@ -365,8 +365,8 @@
 {
 	int band_num;
 	int chan_num;
-	int chan_enum = 0;
-	struct ieee80211_channel *wiphy_chan;
+	enum channel_enum chan_enum = CHAN_ENUM_1;
+	struct ieee80211_channel *wiphy_chan, *wiphy_chan_144 = NULL;
 	struct regulatory_channel *cds_chan;
 	uint8_t band_capability;
 
@@ -385,6 +385,8 @@
 			wiphy_chan =
 				&(wiphy->bands[band_num]->channels[chan_num]);
 			cds_chan = &(reg_channels[chan_enum]);
+			if (CHAN_ENUM_144 == chan_enum)
+				wiphy_chan_144 = wiphy_chan;
 
 			chan_enum++;
 
@@ -426,6 +428,8 @@
 		  (1 << WHAL_REG_EXT_FCC_CH_144))) {
 		cds_chan = &(reg_channels[CHAN_ENUM_144]);
 		cds_chan->state = CHANNEL_STATE_DISABLE;
+		if (NULL != wiphy_chan_144)
+			wiphy_chan_144->flags |= IEEE80211_CHAN_DISABLED;
 	}
 
 	wlan_hdd_cfg80211_update_band(wiphy, band_capability);