diff options
author | Bill Richardson <wfrichar@chromium.org> | 2013-10-02 16:36:10 -0700 |
---|---|---|
committer | chrome-internal-fetch <chrome-internal-fetch@google.com> | 2013-10-04 01:54:46 +0000 |
commit | 9ef58858c40e93c611c1260bea39d004c1687a18 (patch) | |
tree | d42e21cc1c08366e2217225f5069e2f59346cb8c | |
parent | 3990a8e32370d9ec05263b35a765b650bfd40acd (diff) | |
download | chrome-ec-9ef58858c40e93c611c1260bea39d004c1687a18.tar.gz |
Cleanup use of config.h macros
include/config.h should have the canonical list of all CONFIG_* macros used
everywhere else. This fixes some that weren't included, and some that had
been changed in one place but not in others.
BUG=chrome-os-partner:18343
BRANCH=none
TEST=manual
Build everything. It should still work.
cd src/plaform/ec
make runtests
for i in bds bolt daisy discovery falco kirby link mccroskey peppy pit puppy rambi samus slippy snow spring; do make BOARD=$i || touch died.$i; done
There shouldn't be any died.* files.
Change-Id: I0a1ec2d57668509c514dc5a521e547836a3e9894
Signed-off-by: Bill Richardson <wfrichar@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/171690
Reviewed-by: Randall Spangler <rspangler@chromium.org>
-rw-r--r-- | board/bolt/board.h | 3 | ||||
-rw-r--r-- | board/falco/board.c | 4 | ||||
-rw-r--r-- | board/rambi/board.h | 1 | ||||
-rw-r--r-- | board/samus/board.h | 4 | ||||
-rw-r--r-- | board/slippy/board.h | 1 | ||||
-rw-r--r-- | chip/lm4/fan.c | 14 | ||||
-rw-r--r-- | chip/lm4/uart.c | 2 | ||||
-rw-r--r-- | common/pwm_fan.c | 2 | ||||
-rw-r--r-- | include/config.h | 3 |
9 files changed, 13 insertions, 21 deletions
diff --git a/board/bolt/board.h b/board/bolt/board.h index eaa935ba8d..f89a24ab3d 100644 --- a/board/bolt/board.h +++ b/board/bolt/board.h @@ -9,15 +9,12 @@ #define __BOARD_H /* Debug features */ -#define CONFIG_ASSERT_HELP #define CONFIG_CONSOLE_CMDHELP -#define CONFIG_PANIC_HELP #define CONFIG_TASK_PROFILING /* Optional features */ #define CONFIG_CHIPSET_X86 #define CONFIG_CHIPSET_CAN_THROTTLE -#define CONFIG_CUSTOM_KEYSCAN #define CONFIG_EXTPOWER_GPIO #define CONFIG_KEYBOARD_BOARD_CONFIG #define CONFIG_KEYBOARD_PROTOCOL_8042 diff --git a/board/falco/board.c b/board/falco/board.c index e60acb71d2..71fd2acfa7 100644 --- a/board/falco/board.c +++ b/board/falco/board.c @@ -248,7 +248,7 @@ int board_discharge_on_ac(int enable) * Take a nice smooth ramp and make it all chunky. * And never turn it off. Bah. That'll do wonders for battery life. */ -#ifdef CONFIG_PWM_FAN_RPM_CUSTOM +#ifdef CONFIG_FAN_RPM_CUSTOM int pwm_fan_percent_to_rpm(int pct) { const int FAN_MAX = 5050; @@ -260,4 +260,4 @@ int pwm_fan_percent_to_rpm(int pct) int chunky = 100 * (pct + m0) / m; return FAN_MIN + (FAN_MAX - FAN_MIN) * m * chunky / 10000; } -#endif /* CONFIG_PWM_FAN_RPM_CUSTOM */ +#endif /* CONFIG_FAN_RPM_CUSTOM */ diff --git a/board/rambi/board.h b/board/rambi/board.h index bb48e48307..c062368684 100644 --- a/board/rambi/board.h +++ b/board/rambi/board.h @@ -36,7 +36,6 @@ #define CONFIG_CHIPSET_CAN_THROTTLE #define CONFIG_CHIPSET_HASWELL #define CONFIG_CHIPSET_X86 -#define CONFIG_LED_SLIPPY #define CONFIG_USB_PORT_POWER_DUMB #endif diff --git a/board/samus/board.h b/board/samus/board.h index 05c53e973d..936aecd363 100644 --- a/board/samus/board.h +++ b/board/samus/board.h @@ -9,16 +9,13 @@ #define __BOARD_H /* Debug features */ -#define CONFIG_ASSERT_HELP #define CONFIG_CONSOLE_CMDHELP -#define CONFIG_PANIC_HELP #define CONFIG_TASK_PROFILING /* Optional features */ #define CONFIG_BOARD_VERSION #define CONFIG_CHIPSET_X86 #define CONFIG_CHIPSET_CAN_THROTTLE -#define CONFIG_CUSTOM_KEYSCAN #define CONFIG_EXTPOWER_GPIO #define CONFIG_KEYBOARD_BOARD_CONFIG #define CONFIG_KEYBOARD_PROTOCOL_8042 @@ -41,7 +38,6 @@ #define CONFIG_FAN_CH_CPU 2 #define CONFIG_FAN_RPM_MIN 1000 #define CONFIG_FAN_RPM_MAX 5050 -#define CONFIG_FAN_POWER_GOOD GPIO_PP5000_PGOOD #define CONFIG_PWM #define CONFIG_PWM_KBLIGHT #define CONFIG_SWITCH_DEDICATED_RECOVERY diff --git a/board/slippy/board.h b/board/slippy/board.h index 75dde8aa76..9fcd0318f8 100644 --- a/board/slippy/board.h +++ b/board/slippy/board.h @@ -29,7 +29,6 @@ #define CONFIG_FAN_POWER_GOOD GPIO_PP5000_PGOOD #define CONFIG_KEYBOARD_BOARD_CONFIG #define CONFIG_KEYBOARD_PROTOCOL_8042 -#define CONFIG_LED_SLIPPY #define CONFIG_POWER_BUTTON #define CONFIG_POWER_BUTTON_X86 #define CONFIG_PWM diff --git a/chip/lm4/fan.c b/chip/lm4/fan.c index 98e19e767e..d6f8b9915f 100644 --- a/chip/lm4/fan.c +++ b/chip/lm4/fan.c @@ -45,9 +45,9 @@ static void fan_set_enabled(int enable) { pwm_enable(PWM_CH_FAN, enable); -#ifdef CONFIG_PWM_FAN_EN_GPIO - gpio_set_level(CONFIG_PWM_FAN_EN_GPIO, enable); -#endif /* CONFIG_PWM_FAN_EN_GPIO */ +#ifdef CONFIG_FAN_EN_GPIO + gpio_set_level(CONFIG_FAN_EN_GPIO, enable); +#endif /* CONFIG_FAN_EN_GPIO */ } static int fan_get_rpm_mode(void) @@ -192,12 +192,12 @@ static int cc_faninfo(int argc, char **argv) ccprintf("Mode: %s\n", fan_get_rpm_mode() ? "rpm" : "duty"); ccprintf("Auto: %s\n", thermal_control_enabled ? "yes" : "no"); ccprintf("Enable: %s\n", fan_get_enabled() ? "yes" : "no"); -#ifdef CONFIG_PWM_FAN_POWER_GOOD +#ifdef CONFIG_FAN_POWER_GOOD ccprintf("Power: %s\n", -#ifdef CONFIG_PWM_FAN_EN_GPIO - gpio_get_level(CONFIG_PWM_FAN_EN_GPIO) && +#ifdef CONFIG_FAN_EN_GPIO + gpio_get_level(CONFIG_FAN_EN_GPIO) && #endif - gpio_get_level(CONFIG_PWM_FAN_POWER_GOOD) ? "yes" : "no"); + gpio_get_level(CONFIG_FAN_POWER_GOOD) ? "yes" : "no"); #endif diff --git a/chip/lm4/uart.c b/chip/lm4/uart.c index 73570e1746..75f6fa0724 100644 --- a/chip/lm4/uart.c +++ b/chip/lm4/uart.c @@ -276,4 +276,4 @@ DECLARE_CONSOLE_COMMAND(comxtest, command_comxtest, "Write test data to COMx uart", NULL); -#endif /* CONFIG_CMD_COMX_TEST */ +#endif /* CONFIG_CMD_COMXTEST */ diff --git a/common/pwm_fan.c b/common/pwm_fan.c index f9198b1274..f84159a7ad 100644 --- a/common/pwm_fan.c +++ b/common/pwm_fan.c @@ -24,4 +24,4 @@ int pwm_fan_percent_to_rpm(int pct) return rpm; } -#endif /* CONFIG_PWM_FAN_RPM_CUSTOM */ +#endif /* CONFIG_FAN_RPM_CUSTOM */ diff --git a/include/config.h b/include/config.h index 978b512d38..4c69dd9577 100644 --- a/include/config.h +++ b/include/config.h @@ -324,7 +324,7 @@ #undef CONFIG_FAN /* Fan channel (not PWM channel) for the CPU fan */ -#undef CONFIG_FAN_CPU_CH +#undef CONFIG_FAN_CH_CPU /* Name of active high GPIO to control power to the cooling fan */ #undef CONFIG_FAN_EN_GPIO @@ -733,6 +733,7 @@ #ifndef HAS_TASK_CHARGER #undef CONFIG_CHARGER +#undef CONFIG_CHARGER_BQ24192 #undef CONFIG_CHARGER_BQ24707A #undef CONFIG_CHARGER_BQ24715 #undef CONFIG_CHARGER_BQ24725 |