Power model calculation based on batterystats data.

Similar to the ActivityReport, the PowerReport contains the power
usage for a device.  To do the calculations, each of the
ComponentActivity objects are called, giving them the whole activity
info (in case they need to apportion blame) and the PowerProfile.
From that, they compute the per-component power usage, which is
then summed up into the AppPower and PowerReport objects.

Test: atest frameworks/base/tools/powermodel --host
Change-Id: Ibc9ada6f7f4a667152fc4af388f04766125ca74c
11 files changed