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

Commit 81d0325f authored by Todd Kennedy's avatar Todd Kennedy Committed by Android Git Automerger
Browse files

am 5983ae7b: Merge "Allow extra slop in battery stats" into mnc-dev

* commit '5983ae7b':
  Allow extra slop in battery stats
parents 9b7a4ac5 5983ae7b
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -1263,8 +1263,8 @@ public final class BatteryStatsService extends IBatteryStats.Stub
                    Slog.v(TAG, "WiFi energy data was reset, new WiFi energy data is " + result);
                }

                // There is some accuracy error in reports so allow 30 milliseconds of error.
                final long SAMPLE_ERROR_MILLIS = 30;
                // There is some accuracy error in reports so allow some slop in the results.
                final long SAMPLE_ERROR_MILLIS = 750;
                final long totalTimeMs = result.mControllerIdleTimeMs + result.mControllerRxTimeMs +
                        result.mControllerTxTimeMs;
                if (totalTimeMs > timePeriodMs + SAMPLE_ERROR_MILLIS) {