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

Commit 4e75951e authored by Utkarsh Bhatnagar's avatar Utkarsh Bhatnagar Committed by snandini
Browse files

qcacmn: update SAP and P2P Go dwell time seperately

For SAP, the dwell time cannot exceed 32 ms as it can't go
offchannel more than 32 ms. For Go, since it advertise NOA
to annouce the absense period, it can have regular dwell
time which is 40 ms.
This was done increased scan latency was seen across
different targets.

Change-Id: I59a827380dbd76780eaebd8fff25a2eff2ef5107
CRs-Fixed: 2730638
parent 541bbd3a
Loading
Loading
Loading
Loading
+16 −6
Original line number Diff line number Diff line
@@ -633,14 +633,24 @@ static void scm_req_update_concurrency_params(struct wlan_objmgr_vdev *vdev,
	 * 2.if DBS is supported and SAP is not on 2g,
	 * do not reset active dwell time for 2g.
	 */

	/*
	 * For SAP, the dwell time cannot exceed 32 ms as it can't go
	 * offchannel more than 32 ms. For Go, since we
	 * advertise NOA, GO can have regular dwell time which is 40 ms.
	 */
	if ((ap_present && sap_peer_count) ||
	    (go_present && go_peer_count)) {
		if (policy_mgr_is_hw_dbs_capable(psoc) &&
		    policy_mgr_is_sap_go_on_2g(psoc)) {
		if ((policy_mgr_is_hw_dbs_capable(psoc) &&
		     policy_mgr_is_sap_go_on_2g(psoc)) ||
		     !policy_mgr_is_hw_dbs_capable(psoc)) {
			if (ap_present)
				req->scan_req.dwell_time_active_2g =
					QDF_MIN(req->scan_req.dwell_time_active,
						(SCAN_CTS_DURATION_MS_MAX -
						SCAN_ROAM_SCAN_CHANNEL_SWITCH_TIME));
			else
				req->scan_req.dwell_time_active_2g = 0;
		}
		req->scan_req.min_rest_time = req->scan_req.max_rest_time;
	}