From 0180596a8409d60ff2c216c94c1deaaa7e7930a0 Mon Sep 17 00:00:00 2001 From: Mingguang Xu Date: Tue, 22 Oct 2019 17:00:11 -0700 Subject: Wifi usability: Clear the ring buffer after adding each usability stats to the upload list. The LABEL_GOOD and LABEL_BAD data may be mixed if the ring buffer is not cleared after each addition of usability stats the upload list. Currently we rely on data post processing to sort them out. The load on data post processing can be reduced if the ring buffer is cleared. Bug: 143219266 Test: atest WifiMetricsTest Change-Id: I24bef0f7d3ce47696e9d84eb5e516c5ee2b7df50 Signed-off-by: Mingguang Xu (cherry picked from commit 12bcb71c4267d7c380c02594571f4eff99613836) --- service/java/com/android/server/wifi/WifiMetrics.java | 1 + 1 file changed, 1 insertion(+) (limited to 'service') diff --git a/service/java/com/android/server/wifi/WifiMetrics.java b/service/java/com/android/server/wifi/WifiMetrics.java index 1b7e8cdb3..27fe140a7 100644 --- a/service/java/com/android/server/wifi/WifiMetrics.java +++ b/service/java/com/android/server/wifi/WifiMetrics.java @@ -4624,6 +4624,7 @@ public class WifiMetrics { } } mWifiUsabilityStatsCounter = 0; + mWifiUsabilityStatsEntriesList.clear(); } } -- cgit v1.2.3