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

Commit 922db7a3 authored by Bapiraju Alla's avatar Bapiraju Alla Committed by Madan Koyyalamudi
Browse files

qcacld-3.0: Reject LL stats request for SAP mode

LL stats request is not supported for SAP mode. But driver is not checking
for device mode for LL stats request. Instead it is depending on LL stats
request set flag which won't be set for SAP mode. In case of mode switch
from STA to SAP, it is possible that LL stats request set flag will be set
for STA mode and LL stats are requested after switching to SAP mode. This
will bypass the mode SAP.

To avoid this, reject LL stats request for SAP mode.

Change-Id: I8c680288991126f0b349584f502b22e18af72287
CRs-Fixed: 3081453
parent 4717c039
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
/*
 * Copyright (c) 2012-2021 The Linux Foundation. All rights reserved.
 * Copyright (c) 2021 Qualcomm Innovation Center, Inc. All rights reserved.
 * Copyright (c) 2021-2022 Qualcomm Innovation Center, Inc. All rights reserved.
 *
 * Permission to use, copy, modify, and/or distribute this software for
 * any purpose with or without fee is hereby granted, provided that the
@@ -2140,6 +2140,11 @@ __wlan_hdd_cfg80211_ll_stats_get(struct wiphy *wiphy,
		return -EINVAL;
	}

	if (adapter->device_mode == QDF_SAP_MODE) {
		hdd_nofl_debug("LL_STATS get is not supported for SAP mode");
		return -EINVAL;
	}

	if (hddstactx->hdd_reassoc_scenario) {
		hdd_err("Roaming in progress, cannot process the request");
		return -EBUSY;