summaryrefslogtreecommitdiff
path: root/src/ec/quanta
diff options
context:
space:
mode:
authorKyösti Mälkki <kyosti.malkki@gmail.com>2019-11-06 12:07:21 +0200
committerKyösti Mälkki <kyosti.malkki@gmail.com>2019-11-09 10:50:12 +0000
commitbe5317f6d0084b1997ff7342fbf5a5af3eecd950 (patch)
treed5efa36c5a5ba1a0141663c6a4b0737fe8879eec /src/ec/quanta
parent9dd1a12f9c3199fe9f678a4997bb163a1eb1bb96 (diff)
downloadcoreboot-be5317f6d0084b1997ff7342fbf5a5af3eecd950.tar.xz
ELOG: Avoid some preprocessor use
Change-Id: I8daf8868af2e8c2b07b0dda0eeaf863f2f550c59 Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/36648 Reviewed-by: Aaron Durbin <adurbin@chromium.org> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/ec/quanta')
-rw-r--r--src/ec/quanta/ene_kb3940q/ec.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/ec/quanta/ene_kb3940q/ec.c b/src/ec/quanta/ene_kb3940q/ec.c
index 4fc38da99d..5de6336040 100644
--- a/src/ec/quanta/ene_kb3940q/ec.c
+++ b/src/ec/quanta/ene_kb3940q/ec.c
@@ -125,11 +125,11 @@ void ec_mem_write(u8 addr, u8 data)
static void ene_kb3940q_log_events(void)
{
-#if CONFIG(ELOG)
- u8 reason = ec_mem_read(EC_SHUTDOWN_REASON);
- if (reason)
- elog_add_event_byte(ELOG_TYPE_EC_SHUTDOWN, reason);
-#endif
+ if (CONFIG(ELOG)) {
+ u8 reason = ec_mem_read(EC_SHUTDOWN_REASON);
+ if (reason)
+ elog_add_event_byte(ELOG_TYPE_EC_SHUTDOWN, reason);
+ }
}
static void ene_kb3940q_init(struct device *dev)