[Cherry-pick] StorageDumpsysTest allows charger off on USB connection

Devices connected by ADB can typically also pull 500mA of current to
charge the device.  For devices with larger batteries it is ill
advised to charge at a rate lower than 0.05C, so they do not.

Print a warning that I/O was attributed to charger off when
ADB USB connection assumes charger on in StoragedDumpsysTest.

Fix a build warning in BatteryStatsDumpsysTest.

Test: cts
Bug: 118833202
Change-Id: I2d7d38d8d2e146c3a67df4f3ecad5e8d66600ac1
1 file changed