refactor(kscan): Auto enable kscan drivers

The key scanning drivers are now automatically enabled when a DT node
with the matching "compatible" property is present and enabled, so they
no longer need to be manually set for each board.
This commit is contained in:
Joel Spadin
2022-04-25 16:48:33 -05:00
committed by Pete Johanson
parent a3a9510e47
commit 6d6efa32f5
18 changed files with 33 additions and 58 deletions

View File

@@ -13,8 +13,6 @@
LOG_MODULE_DECLARE(zmk, CONFIG_ZMK_LOG_LEVEL);
#if DT_HAS_COMPAT_STATUS_OKAY(DT_DRV_COMPAT)
struct kscan_gpio_item_config {
char *label;
gpio_pin_t pin;
@@ -242,5 +240,3 @@ static const struct kscan_driver_api gpio_driver_api = {
&gpio_driver_api);
DT_INST_FOREACH_STATUS_OKAY(GPIO_INST_INIT)
#endif /* DT_HAS_COMPAT_STATUS_OKAY(DT_DRV_COMPAT) */