diff options
author | Tristan Honscheid <honscheid@google.com> | 2023-04-12 16:57:15 -0600 |
---|---|---|
committer | Chromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com> | 2023-04-13 17:14:31 +0000 |
commit | f4023abb261000c1df6946f026f8df5dfccd64c4 (patch) | |
tree | 46af1ac812fb00c91e2cb18a11a9786fe50b14a4 | |
parent | 59de61f2dbbfcea4534a48eec30b96001105920c (diff) | |
download | chrome-ec-f4023abb261000c1df6946f026f8df5dfccd64c4.tar.gz |
emul: isl923x: Syntax bug in ZTEST_RULE for multiple instances
The semicolon in the ztest rule for the ISL923X emulator was in the
wrong spot and caused a syntax error when instantiating multiple chips.
It should be in the macro so it gets repeated for each child.
BUG=b:276805061
BRANCH=None
TEST=./twister
Change-Id: I4fc8f7e3c4360948648c377f99e84525bb0e61dd
Signed-off-by: Tristan Honscheid <honscheid@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/4421008
Reviewed-by: Simon Glass <sjg@chromium.org>
Commit-Queue: Simon Glass <sjg@chromium.org>
-rw-r--r-- | zephyr/emul/emul_isl923x.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/zephyr/emul/emul_isl923x.c b/zephyr/emul/emul_isl923x.c index 92bff73656..bd7b8b54f5 100644 --- a/zephyr/emul/emul_isl923x.c +++ b/zephyr/emul/emul_isl923x.c @@ -453,7 +453,7 @@ DT_INST_FOREACH_STATUS_OKAY(INIT_ISL923X) #ifdef CONFIG_ZTEST_NEW_API #define ISL923X_EMUL_RESET_RULE_AFTER(n) \ - isl923x_emul_reset(&isl923x_emul_data_##n) + isl923x_emul_reset(&isl923x_emul_data_##n); static void emul_isl923x_reset_before(const struct ztest_unit_test *test, void *data) @@ -461,7 +461,7 @@ static void emul_isl923x_reset_before(const struct ztest_unit_test *test, ARG_UNUSED(test); ARG_UNUSED(data); - DT_INST_FOREACH_STATUS_OKAY(ISL923X_EMUL_RESET_RULE_AFTER); + DT_INST_FOREACH_STATUS_OKAY(ISL923X_EMUL_RESET_RULE_AFTER) } ZTEST_RULE(emul_isl923x_reset, emul_isl923x_reset_before, NULL); #endif /* CONFIG_ZTEST_NEW_API */ |