diff options
author | Jeremy Bettis <jbettis@google.com> | 2022-08-16 11:13:21 -0600 |
---|---|---|
committer | Chromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com> | 2022-08-17 22:35:12 +0000 |
commit | 96af58d5d8e438628342bca6458d8cd2987df7b6 (patch) | |
tree | d13fb3d854f33baf1d0c6e8e8c9e8e17926b6f24 /zephyr/test/kingler/src/fakes.c | |
parent | b37f579fdaa277bc0b89fd255fa2a7535f06e24d (diff) | |
download | chrome-ec-96af58d5d8e438628342bca6458d8cd2987df7b6.tar.gz |
zephyr: Added test for steelix board specific coderelease-R106-15054.B-main
Add a dts file for native_posix tests that want to use npcx gpios and
interrupts. There is more work to be done to make it full featured.
Specifically the npcx pinctrl driver really needs an emulator.
Add test for the board specific code in steelix. This is mostly a sample
on how to do this, more than being that useful of a test on it's own.
BRANCH=None
BUG=b:242032118
TEST=./twister --coverage -T zephyr/test/kingler
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Change-Id: I9436a447e7cd4f3baa743c77d4b2d89bafeb0c9c
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3833914
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Yuval Peress <peress@google.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
Code-Coverage: Zoss <zoss-cl-coverage@prod.google.com>
Diffstat (limited to 'zephyr/test/kingler/src/fakes.c')
-rw-r--r-- | zephyr/test/kingler/src/fakes.c | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/zephyr/test/kingler/src/fakes.c b/zephyr/test/kingler/src/fakes.c new file mode 100644 index 0000000000..5de43475ae --- /dev/null +++ b/zephyr/test/kingler/src/fakes.c @@ -0,0 +1,22 @@ +/* Copyright 2022 The ChromiumOS Authors. + * Use of this source code is governed by a BSD-style license that can be + * found in the LICENSE file. + */ + +#include <zephyr/fff.h> +#include "gpio_signal.h" + +DEFINE_FFF_GLOBALS; +FAKE_VOID_FUNC(power_button_interrupt, enum gpio_signal); +FAKE_VOID_FUNC(button_interrupt, enum gpio_signal); +FAKE_VOID_FUNC(lid_interrupt, enum gpio_signal); +FAKE_VOID_FUNC(chipset_reset_request_interrupt, enum gpio_signal); +FAKE_VOID_FUNC(power_signal_interrupt, enum gpio_signal); +FAKE_VOID_FUNC(chipset_watchdog_interrupt, enum gpio_signal); +FAKE_VOID_FUNC(extpower_interrupt, enum gpio_signal); +FAKE_VOID_FUNC(usb_a0_interrupt, enum gpio_signal); +FAKE_VOID_FUNC(switch_interrupt, enum gpio_signal); +FAKE_VOID_FUNC(tcpc_alert_event, enum gpio_signal); +FAKE_VOID_FUNC(ppc_interrupt, enum gpio_signal); +FAKE_VOID_FUNC(bc12_interrupt, enum gpio_signal); +FAKE_VOID_FUNC(x_ec_interrupt, enum gpio_signal); |