|
@@ -69,6 +69,7 @@
|
|
|
#include <wlan_scan_ucfg_api.h>
|
|
|
#include <wlan_blm_api.h>
|
|
|
#include <lim_assoc_utils.h>
|
|
|
+#include "wlan_mlme_ucfg_api.h"
|
|
|
|
|
|
/** -------------------------------------------------------------
|
|
|
\fn lim_delete_dialogue_token_list
|
|
@@ -7370,6 +7371,33 @@ void lim_set_he_caps(struct mac_context *mac, struct pe_session *session,
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+static void lim_intersect_he_ch_width_2g(struct mac_context *mac,
|
|
|
+ struct he_capability_info *he_cap)
|
|
|
+{
|
|
|
+ struct wlan_objmgr_psoc *psoc;
|
|
|
+ uint32_t cbm_24ghz;
|
|
|
+ QDF_STATUS ret;
|
|
|
+
|
|
|
+ psoc = mac->psoc;
|
|
|
+ if (!psoc)
|
|
|
+ return;
|
|
|
+
|
|
|
+ ret = ucfg_mlme_get_channel_bonding_24ghz(psoc, &cbm_24ghz);
|
|
|
+ if (QDF_IS_STATUS_ERROR(ret))
|
|
|
+ return;
|
|
|
+
|
|
|
+ pe_debug("channel bonding mode 2.4GHz %d", cbm_24ghz);
|
|
|
+
|
|
|
+ if (!cbm_24ghz) {
|
|
|
+ /* B0: 40Mhz channel width in the 2.4GHz band */
|
|
|
+ he_cap->chan_width = HE_CH_WIDTH_CLR_BIT(he_cap->chan_width, 0);
|
|
|
+ he_cap->he_ppdu_20_in_40Mhz_2G = 0;
|
|
|
+ }
|
|
|
+
|
|
|
+ pe_debug("HE cap: chan_width: 0x%07x he_ppdu_20_in_40Mhz_2G %d",
|
|
|
+ he_cap->chan_width, he_cap->he_ppdu_20_in_40Mhz_2G);
|
|
|
+}
|
|
|
+
|
|
|
QDF_STATUS lim_send_he_caps_ie(struct mac_context *mac_ctx,
|
|
|
struct pe_session *session,
|
|
|
enum QDF_OPMODE device_mode,
|
|
@@ -7409,6 +7437,8 @@ QDF_STATUS lim_send_he_caps_ie(struct mac_context *mac_ctx,
|
|
|
pe_err("Unable send HE Cap IE for 5GHZ band, status: %d",
|
|
|
status_5g);
|
|
|
|
|
|
+ lim_intersect_he_ch_width_2g(mac_ctx, he_cap);
|
|
|
+
|
|
|
status_2g = lim_send_ie(mac_ctx, vdev_id, DOT11F_EID_HE_CAP,
|
|
|
CDS_BAND_2GHZ, &he_caps[2],
|
|
|
he_caps[1] + 1);
|