소스 검색

qcacld-3.0: LLStats- Don't wait for peerstats if there is no peer

qcacld-2.0 to qcacld-3.0 propagation

Firmware indicates the number of peers connected as part of iface
stats. If there are no peers connected, don't wait for the
peerstats and indicate the stats to host.

Change-Id: I32d04a5711adb5f924d120ee61064a178e753549
CRs-Fixed: 847743
Srinivas Dasari 9 년 전
부모
커밋
faba5ff68b
1개의 변경된 파일8개의 추가작업 그리고 0개의 파일을 삭제
  1. 8 0
      core/hdd/src/wlan_hdd_stats.c

+ 8 - 0
core/hdd/src/wlan_hdd_stats.c

@@ -1226,6 +1226,14 @@ static void wlan_hdd_cfg80211_link_layer_stats_callback(void *ctx,
 				linkLayerStatsResults->num_peers);
 
 			spin_lock(&context->context_lock);
+			/* Firmware doesn't send peerstats event if no peers are
+			 * connected. HDD should not wait for any peerstats in
+			 * this case and return the status to middleware after
+			 * receiving iface stats
+			 */
+			if (!linkLayerStatsResults->num_peers)
+				context->request_bitmap &=
+					~(WMI_LINK_STATS_ALL_PEER);
 			context->request_bitmap &= ~(WMI_LINK_STATS_IFACE);
 			spin_unlock(&context->context_lock);