Remove unusued scan stats
This is now part of BatteryStats Change-Id: I7e16207276e28eea3be8666990ae958b8ea7a17a
This commit is contained in:
@@ -111,10 +111,6 @@ public class WifiService extends IWifiManager.Stub {
|
||||
private int mScanLocksAcquired;
|
||||
private int mScanLocksReleased;
|
||||
|
||||
/* A mapping from UID to scan count */
|
||||
private HashMap<Integer, Integer> mScanCount =
|
||||
new HashMap<Integer, Integer>();
|
||||
|
||||
private final List<Multicaster> mMulticasters =
|
||||
new ArrayList<Multicaster>();
|
||||
private int mMulticastEnabled;
|
||||
@@ -585,15 +581,6 @@ public class WifiService extends IWifiManager.Stub {
|
||||
*/
|
||||
public void startScan(boolean forceActive) {
|
||||
enforceChangePermission();
|
||||
|
||||
int uid = Binder.getCallingUid();
|
||||
int count = 0;
|
||||
synchronized (mScanCount) {
|
||||
if (mScanCount.containsKey(uid)) {
|
||||
count = mScanCount.get(uid);
|
||||
}
|
||||
mScanCount.put(uid, ++count);
|
||||
}
|
||||
mWifiStateMachine.startScan(forceActive);
|
||||
noteScanStart();
|
||||
}
|
||||
@@ -1056,12 +1043,6 @@ public class WifiService extends IWifiManager.Stub {
|
||||
mAlarmManager.set(AlarmManager.RTC_WAKEUP, triggerTime, mIdleIntent);
|
||||
}
|
||||
|
||||
//Start scan stats tracking when device unplugged
|
||||
if (pluggedType == 0) {
|
||||
synchronized (mScanCount) {
|
||||
mScanCount.clear();
|
||||
}
|
||||
}
|
||||
mPluggedType = pluggedType;
|
||||
} else if (action.equals(BluetoothAdapter.ACTION_CONNECTION_STATE_CHANGED)) {
|
||||
int state = intent.getIntExtra(BluetoothAdapter.EXTRA_CONNECTION_STATE,
|
||||
@@ -1252,13 +1233,6 @@ public class WifiService extends IWifiManager.Stub {
|
||||
pw.println("Locks held:");
|
||||
mLocks.dump(pw);
|
||||
|
||||
pw.println("Scan count since last plugged in");
|
||||
synchronized (mScanCount) {
|
||||
for(int sc : mScanCount.keySet()) {
|
||||
pw.println("UID: " + sc + " Scan count: " + mScanCount.get(sc));
|
||||
}
|
||||
}
|
||||
|
||||
pw.println();
|
||||
pw.println("WifiWatchdogStateMachine dump");
|
||||
mWifiWatchdogStateMachine.dump(pw);
|
||||
|
||||
Reference in New Issue
Block a user