qcacld-3.0: Remove excessive logging
Lot of info logs are periodic and cause log spam.
Add changes to remove excessive logging.
Change-Id: I1ae4f366f359fd90856743b4c2689ad9aad3417b
CRs-Fixed: 1093093
diff --git a/core/hdd/src/wlan_hdd_power.c b/core/hdd/src/wlan_hdd_power.c
index f0e6480..fe3c4b4 100644
--- a/core/hdd/src/wlan_hdd_power.c
+++ b/core/hdd/src/wlan_hdd_power.c
@@ -2144,12 +2144,10 @@
*/
static int __wlan_hdd_cfg80211_get_txpower(struct wiphy *wiphy,
struct wireless_dev *wdev,
- int *dbm)
+ int *dbm, hdd_adapter_t *adapter)
{
hdd_context_t *pHddCtx = (hdd_context_t *) wiphy_priv(wiphy);
- struct net_device *ndev = wdev->netdev;
- hdd_adapter_t *adapter = WLAN_HDD_GET_PRIV_PTR(ndev);
int status;
ENTER();
@@ -2159,11 +2157,6 @@
return -EINVAL;
}
- if (wlan_hdd_validate_session_id(adapter->sessionId)) {
- hdd_err("invalid session id: %d", adapter->sessionId);
- return -EINVAL;
- }
-
status = wlan_hdd_validate_context(pHddCtx);
if (0 != status) {
*dbm = 0;
@@ -2212,12 +2205,15 @@
struct wireless_dev *wdev,
int *dbm)
{
- int ret;
+ int ret = -ENOTSUPP;
+ struct net_device *ndev = wdev->netdev;
+ hdd_adapter_t *adapter = WLAN_HDD_GET_PRIV_PTR(ndev);
cds_ssr_protect(__func__);
- ret = __wlan_hdd_cfg80211_get_txpower(wiphy,
+ if (adapter->sessionId != HDD_SESSION_ID_INVALID)
+ ret = __wlan_hdd_cfg80211_get_txpower(wiphy,
wdev,
- dbm);
+ dbm, adapter);
cds_ssr_unprotect(__func__);
return ret;