summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2020-12-17 13:46:54 -0700
committerCommit Bot <commit-bot@chromium.org>2021-01-15 03:56:03 +0000
commit207dd397bf09afe2b188ca771024b6a0dc93849c (patch)
tree26d653cdc08e6c8f12a1ffb43a85a5a820b3ccd3
parent51aaf7dadf38aa04fe5472030bcd078108aeba50 (diff)
downloadchrome-ec-207dd397bf09afe2b188ca771024b6a0dc93849c.tar.gz
cros_kb: Add the missing enable_interrupt method
This method is defined in the file but not included in the API struct for the driver. Add it to avoid a warning. BUG=b:174871569 TEST=build for zephyr, see the warning gone Change-Id: I4fa8330b351582eeb796c8f8b4226e0542d1a45a Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/zephyr-chrome/+/2597661 Reviewed-by: Jack Rosenthal <jrosenth@chromium.org> Commit-Queue: Simon Glass <sjg@chromium.org> Tested-by: Simon Glass <sjg@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2630162 Tested-by: Jack Rosenthal <jrosenth@chromium.org> Reviewed-by: Simon Glass <sjg@chromium.org> Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
-rw-r--r--zephyr/drivers/cros_kb_raw/cros_kb_raw_npcx.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/zephyr/drivers/cros_kb_raw/cros_kb_raw_npcx.c b/zephyr/drivers/cros_kb_raw/cros_kb_raw_npcx.c
index 4858d5d251..2512a5a1bf 100644
--- a/zephyr/drivers/cros_kb_raw/cros_kb_raw_npcx.c
+++ b/zephyr/drivers/cros_kb_raw/cros_kb_raw_npcx.c
@@ -88,8 +88,8 @@ static int kb_raw_npcx_init(const struct device *dev)
}
/* Cros ec keyboard raw api functions */
-static void cros_kb_raw_npcx_enable_interrupt(const struct device *dev,
- int enable)
+static int cros_kb_raw_npcx_enable_interrupt(const struct device *dev,
+ int enable)
{
const struct cros_kb_raw_npcx_config *const config = DRV_CONFIG(dev);
@@ -97,6 +97,8 @@ static void cros_kb_raw_npcx_enable_interrupt(const struct device *dev,
irq_enable(config->irq);
else
irq_disable(config->irq);
+
+ return 0;
}
static int cros_kb_raw_npcx_read_row(const struct device *dev)
@@ -213,6 +215,7 @@ static const struct cros_kb_raw_driver_api cros_kb_raw_npcx_driver_api = {
.init = cros_kb_raw_npcx_init,
.drive_colum = cros_kb_raw_npcx_drive_column,
.read_rows = cros_kb_raw_npcx_read_row,
+ .enable_interrupt = cros_kb_raw_npcx_enable_interrupt,
};
static const struct npcx_alt cros_kb_raw_alts[] = DT_NPCX_ALT_ITEMS_LIST(0);