Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 728f758d authored by Srinivas Dasari's avatar Srinivas Dasari Committed by Madan Koyyalamudi
Browse files

qcacld-3.0: Let IOT APs recover by avoiding back to back DELBA

Station sends the BA and upgrades to the next possible BA window
size upon receiving all frames successfully from the current
window. Some IOT APs go out of sync from BA window size of the
station when AP fails to receive the BA sent from station. AP
transmits the frames again with previous window sequence number
and won't be ack'ed by station hardware as BA window has already
moved ahead. So, station deletes the upgraded BA and tries
to fallback.

Ideally, AP is supposed to consider the fact that "the previous
window transmission was successful when station upgrades to next
window size". But some APs take little longer time to
recover/upgrade to next window size. Don't delete the BA
immediately and have some tolerance(3 seconds) as the previous
negotiated BA just got deleted.

Change-Id: I6b277223f02dac521316cec20bd5d958785cc2e9
CRs-Fixed: 2970714
parent e0d4866d
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -247,6 +247,9 @@ struct mscs_req_info {
 * @he_sta_obsspd: he_sta_obsspd
 * @twt_wait_for_notify: TWT session teardown received, wait for
 * notify event from firmware before next TWT setup is done.
 * @last_delba_sent_time: Last delba sent time to handle back to back delba
 *			  requests from some IOT APs
 * @ba_2k_jump_iot_ap: This is set to true if connected to the ba 2k jump IOT AP
 */
struct mlme_legacy_priv {
	bool chan_switch_in_progress;
@@ -282,6 +285,8 @@ struct mlme_legacy_priv {
	tDot11fIEhe_cap he_config;
	uint32_t he_sta_obsspd;
#endif
	qdf_time_t last_delba_sent_time;
	bool ba_2k_jump_iot_ap;
};


+39 −0
Original line number Diff line number Diff line
@@ -3117,4 +3117,43 @@ bool wlan_mlme_is_local_tpe_pref(struct wlan_objmgr_psoc *psoc);
 * operating in 2G/5G bands, false if host should always consider TPE IE values
 */
bool wlan_mlme_skip_tpe(struct wlan_objmgr_psoc *psoc);

/**
 * wlan_mlme_set_ba_2k_jump_iot_ap() - Set a flag if ba 2k jump IOT AP is found
 * @vdev: vdev pointer
 * @found: Carries the value true if ba 2k jump IOT AP is found
 *
 * Return: QDF Status
 */
QDF_STATUS
wlan_mlme_set_ba_2k_jump_iot_ap(struct wlan_objmgr_vdev *vdev, bool found);

/**
 * wlan_mlme_is_ba_2k_jump_iot_ap() - Check if ba 2k jump IOT AP is found
 * @vdev: vdev pointer
 *
 * Return: true if ba 2k jump IOT AP is found
 */
bool
wlan_mlme_is_ba_2k_jump_iot_ap(struct wlan_objmgr_vdev *vdev);

/**
 * wlan_mlme_set_last_delba_sent_time() - Cache the last delba sent ts
 * @vdev: vdev pointer
 * @delba_sent_time: Last delba sent timestamp
 *
 * Return: QDF Status
 */
QDF_STATUS
wlan_mlme_set_last_delba_sent_time(struct wlan_objmgr_vdev *vdev,
				   qdf_time_t delba_sent_time);

/**
 * wlan_mlme_get_last_delba_sent_time() - Get the last delba sent ts
 * @vdev: vdev pointer
 *
 * Return: Last delba timestamp if cached, 0 otherwise
 */
qdf_time_t
wlan_mlme_get_last_delba_sent_time(struct wlan_objmgr_vdev *vdev);
#endif /* _WLAN_MLME_API_H_ */
+60 −0
Original line number Diff line number Diff line
@@ -4785,3 +4785,63 @@ bool wlan_mlme_skip_tpe(struct wlan_objmgr_psoc *psoc)

	return mlme_obj->cfg.power.skip_tpe;
}

QDF_STATUS
wlan_mlme_set_ba_2k_jump_iot_ap(struct wlan_objmgr_vdev *vdev, bool found)
{
	struct mlme_legacy_priv *mlme_priv;

	mlme_priv = wlan_vdev_mlme_get_ext_hdl(vdev);
	if (!mlme_priv) {
		mlme_legacy_err("vdev legacy private object is NULL");
		return QDF_STATUS_E_FAILURE;
	}

	mlme_priv->ba_2k_jump_iot_ap = found;

	return QDF_STATUS_SUCCESS;
}

bool wlan_mlme_is_ba_2k_jump_iot_ap(struct wlan_objmgr_vdev *vdev)
{
	struct mlme_legacy_priv *mlme_priv;

	mlme_priv = wlan_vdev_mlme_get_ext_hdl(vdev);
	if (!mlme_priv) {
		mlme_legacy_err("vdev legacy private object is NULL");
		return false;
	}

	return mlme_priv->ba_2k_jump_iot_ap;
}

QDF_STATUS
wlan_mlme_set_last_delba_sent_time(struct wlan_objmgr_vdev *vdev,
				   qdf_time_t delba_sent_time)
{
	struct mlme_legacy_priv *mlme_priv;

	mlme_priv = wlan_vdev_mlme_get_ext_hdl(vdev);
	if (!mlme_priv) {
		mlme_legacy_err("vdev legacy private object is NULL");
		return QDF_STATUS_E_FAILURE;
	}

	mlme_priv->last_delba_sent_time = delba_sent_time;

	return QDF_STATUS_SUCCESS;
}

qdf_time_t
wlan_mlme_get_last_delba_sent_time(struct wlan_objmgr_vdev *vdev)
{
	struct mlme_legacy_priv *mlme_priv;

	mlme_priv = wlan_vdev_mlme_get_ext_hdl(vdev);
	if (!mlme_priv) {
		mlme_legacy_err("vdev legacy private object is NULL");
		return 0;
	}

	return mlme_priv->last_delba_sent_time;
}
+3 −0
Original line number Diff line number Diff line
@@ -338,6 +338,9 @@
#define SIR_MAC_VENDOR_AP_4_OUI             "\x8C\xFD\xF0"
#define SIR_MAC_VENDOR_AP_4_OUI_LEN         3

#define SIR_MAC_BA_2K_JUMP_AP_VENDOR_OUI             "\x00\x14\x6C"
#define SIR_MAC_BA_2K_JUMP_AP_VENDOR_OUI_LEN         3

/* Maximum allowable size of a beacon and probe rsp frame */
#define SIR_MAX_BEACON_SIZE    512
#define SIR_MAX_PROBE_RESP_SIZE 512
+8 −0
Original line number Diff line number Diff line
@@ -15042,6 +15042,14 @@ QDF_STATUS csr_send_join_req_msg(struct mac_context *mac, uint32_t sessionId,
							WLAN_LEGACY_MAC_ID);
		if (vdev) {
			mlme_set_follow_ap_edca_flag(vdev, follow_ap_edca);
			is_vendor_ap_present = wlan_get_vendor_ie_ptr_from_oui(
					SIR_MAC_BA_2K_JUMP_AP_VENDOR_OUI,
					SIR_MAC_BA_2K_JUMP_AP_VENDOR_OUI_LEN,
					vendor_ap_search_attr.ie_data,
					vendor_ap_search_attr.ie_length);
			wlan_mlme_set_ba_2k_jump_iot_ap(vdev,
							is_vendor_ap_present);
			wlan_objmgr_vdev_release_ref(vdev, WLAN_LEGACY_MAC_ID);
		}
Loading