qcacld-3.0: Reg checks either HT_40+ or HT_40- to claim no 40/80Mhz

Regulatory is currently checking if either no-HT_40+ or no-HT_40- flags
set. If one of them is set then it claims that 40Mhz BW for that channel
is not supported which creates issue for SAP where it considers channel
36 (5180Mhz) is only 20Mhz capable.

To fix the situation, check both no-HT40+ and no-HT40- flags before
claiming 40Mhz/80Mhz not supported.

CRs-Fixed: 2042420
Change-Id: I8c73ae8df21efa23f2967f17febe165cff55c43c
diff --git a/core/hdd/src/wlan_hdd_regulatory.c b/core/hdd/src/wlan_hdd_regulatory.c
index 04f0eb4..296e529 100644
--- a/core/hdd/src/wlan_hdd_regulatory.c
+++ b/core/hdd/src/wlan_hdd_regulatory.c
@@ -444,7 +444,19 @@
 				cds_chan->max_bw = 5;
 			else if (wiphy_chan->flags & IEEE80211_CHAN_NO_20MHZ)
 				cds_chan->max_bw = 10;
-			else if (wiphy_chan->flags & IEEE80211_CHAN_NO_HT40)
+			/*
+			 * IEEE80211_CHAN_NO_HT40  is defined as 0x30 in kernel
+			 * 4th BIT representing IEEE80211_CHAN_NO_HT40PLUS
+			 * 5th BIT representing IEEE80211_CHAN_NO_HT40MINUS
+			 *
+			 * In order to claim no 40Mhz support value of
+			 * wiphy_chan->flags needs to be 0x30.
+			 * 0x20 and 0x10 values shows that either HT40+ or
+			 * HT40- is not supported based on BIT set but they
+			 * can support 40Mhz Operation.
+			 */
+			else if ((wiphy_chan->flags & IEEE80211_CHAN_NO_HT40) ==
+					IEEE80211_CHAN_NO_HT40)
 				cds_chan->max_bw = 20;
 			else if (wiphy_chan->flags & IEEE80211_CHAN_NO_80MHZ)
 				cds_chan->max_bw = 40;