diff options
author | Vic Yang <victoryang@google.com> | 2012-01-12 17:02:10 +0800 |
---|---|---|
committer | Vic Yang <victoryang@google.com> | 2012-02-04 14:37:04 +0800 |
commit | 000a6d57423e96ffaa2061bd764b8141ea46bb8e (patch) | |
tree | 528dd0d5f798101470a1d45f9480bc7b2ecebcb0 /common/main.c | |
parent | 249467b9f291e2b10a7aafdbb584c68c8b0a4e88 (diff) | |
download | chrome-ec-000a6d57423e96ffaa2061bd764b8141ea46bb8e.tar.gz |
Refactor temperature sensor code and add support of Link I2C temp sensor.
Refactor board/chip-specific code into corresponding directories.
Add support of the four I2C temp sensor in Link.
Use table lookup to handle different types of temperature sensors.
BUG=chrome-os-partner:7527
TEST=Correctly read EC internal temperature on bds.
Compile for link succeeded.
Change-Id: I694cfa54e1545798d877fafdf18c5585ab5f03e2
Diffstat (limited to 'common/main.c')
-rw-r--r-- | common/main.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/common/main.c b/common/main.c index d9d1f5375c..bf27cae30f 100644 --- a/common/main.c +++ b/common/main.c @@ -31,7 +31,8 @@ #include "vboot.h" #include "watchdog.h" #include "usb_charge.h" - +#include "chip_temp_sensor.h" +#include "charger.h" int main(void) { @@ -75,10 +76,12 @@ int main(void) i2c_init(); #ifdef CONFIG_TEMP_SENSOR temp_sensor_init(); + chip_temp_sensor_init(); #endif power_button_init(); adc_init(); usb_charge_init(); + charger_init(); /* Print the reset cause */ uart_printf("\n\n--- Chrome EC initialized! ---\n"); |