diff options
author | Vijay Hiremath <vijay.p.hiremath@intel.com> | 2015-07-27 12:39:35 -0700 |
---|---|---|
committer | ChromeOS Commit Bot <chromeos-commit-bot@chromium.org> | 2015-07-29 21:18:25 +0000 |
commit | 1b45f6ed717c8c1a62cbe0698bc2217b69ce1483 (patch) | |
tree | d986841aada034e9514c53a4bf849e135e4e652a /driver/battery | |
parent | 511766b6388099ed6894f7209430de145397afc4 (diff) | |
download | chrome-ec-1b45f6ed717c8c1a62cbe0698bc2217b69ce1483.tar.gz |
Driver: Add macros to conditionally compile the console commands
Added macros to conditionally compile the console commands to save the
memory. These macros can be enabled/disabled in the board specific files.
BUG=none
TEST=make buildall -j
BRANCH=none
Change-Id: I108a072c333762cd24ea973612202c9cc4d40914
Signed-off-by: Vijay Hiremath <vijay.p.hiremath@intel.com>
Reviewed-on: https://chromium-review.googlesource.com/288950
Reviewed-by: Shawn N <shawnn@chromium.org>
Diffstat (limited to 'driver/battery')
-rw-r--r-- | driver/battery/ryu.c | 2 | ||||
-rw-r--r-- | driver/battery/samus.c | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/driver/battery/ryu.c b/driver/battery/ryu.c index 7bfcc949b8..867d4e34d2 100644 --- a/driver/battery/ryu.c +++ b/driver/battery/ryu.c @@ -198,6 +198,7 @@ enum ec_status charger_profile_override_set_param(uint32_t param, return EC_RES_INVALID_PARAM; } +#ifdef CONFIG_CMD_FASTCHARGE static int command_fastcharge(int argc, char **argv) { if (argc > 1 && !parse_bool(argv[1], &fast_charging_allowed)) @@ -211,5 +212,6 @@ DECLARE_CONSOLE_COMMAND(fastcharge, command_fastcharge, "[on|off]", "Get or set fast charging profile", NULL); +#endif /* CONFIG_CMD_FASTCHARGE */ #endif /* CONFIG_CHARGER_PROFILE_OVERRIDE */ diff --git a/driver/battery/samus.c b/driver/battery/samus.c index ff57369d07..bd334d08c8 100644 --- a/driver/battery/samus.c +++ b/driver/battery/samus.c @@ -208,6 +208,7 @@ enum ec_status charger_profile_override_set_param(uint32_t param, return EC_RES_INVALID_PARAM; } +#ifdef CONFIG_CMD_FASTCHARGE static int command_fastcharge(int argc, char **argv) { if (argc > 1 && !parse_bool(argv[1], &fast_charging_allowed)) @@ -221,6 +222,7 @@ DECLARE_CONSOLE_COMMAND(fastcharge, command_fastcharge, "[on|off]", "Get or set fast charging profile", NULL); +#endif /* CONFIG_CMD_FASTCHARGE */ #endif /* CONFIG_CHARGER_PROFILE_OVERRIDE */ |