Driver: ISL9237: Monitor system power consumption

Added code to enable the system power monitoring functionality to get the
details of the system power consumption.
And also added EC console command "psys" to get the system power consumption.

BUG=none
TEST=Manually tested on Kunimitsu.
     Power = Voltage * Current, reading is equal to the power readings
     from the psys command.
BRANCH=none

Change-Id: I62519ac96800363b67cab23cd9eb0dcac229cb47
Signed-off-by: Vijay Hiremath <vijay.p.hiremath@intel.com>
Reviewed-on: https://chromium-review.googlesource.com/302472
Commit-Ready: Vijay P Hiremath <vijay.p.hiremath@intel.com>
Tested-by: Vijay P Hiremath <vijay.p.hiremath@intel.com>
Reviewed-by: Shawn N <shawnn@chromium.org>
This commit is contained in:
Vijay Hiremath
2015-09-23 17:19:19 -07:00
committed by chrome-bot
parent 58540e90a5
commit 5cbd9fa7bb
5 changed files with 106 additions and 6 deletions

View File

@@ -341,6 +341,9 @@
*/
#undef CONFIG_CHARGER_CURRENT_LIMIT
/* Enable/disable system power monitor PSYS function */
#undef CONFIG_CHARGER_PSYS
/*
* Board specific charging current termination limit, in mA. If defined and
* charger supports setting termination current it should be set during charger
@@ -502,6 +505,7 @@
#define CONFIG_CMD_POWER_AP
#define CONFIG_CMD_POWERINDEBUG
#undef CONFIG_CMD_POWERLED
#undef CONFIG_CMD_PSYS
#undef CONFIG_CMD_RTC_ALARM
#undef CONFIG_CMD_SCRATCHPAD
#define CONFIG_CMD_SHMEM