From 0cf03bd3b1fbaa3c025b50b1329286af448a41a6 Mon Sep 17 00:00:00 2001 From: Maureen Helm Date: Tue, 4 Jan 2022 16:58:42 -0600 Subject: [PATCH] zephyr: Use CONFIG_USB_DEVICE_STACK for conditional USB device support. CONFIG_USB was removed in Zephyr v2.7.0 after some Kconfig rework that made it sufficient to use CONFIG_USB_DEVICE_STACK only. Signed-off-by: Maureen Helm --- ports/zephyr/boards/mimxrt1050_evk.conf | 1 - ports/zephyr/main.c | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/ports/zephyr/boards/mimxrt1050_evk.conf b/ports/zephyr/boards/mimxrt1050_evk.conf index c4abf726a4..98981df75a 100644 --- a/ports/zephyr/boards/mimxrt1050_evk.conf +++ b/ports/zephyr/boards/mimxrt1050_evk.conf @@ -1,7 +1,6 @@ # Required for zephyr.DiskAccess block devices CONFIG_DISK_ACCESS=y -CONFIG_USB=y CONFIG_USB_DEVICE_STACK=y CONFIG_USB_DEVICE_PRODUCT="Zephyr MicroPython" CONFIG_USB_MASS_STORAGE=y diff --git a/ports/zephyr/main.c b/ports/zephyr/main.c index f972768340..1275a49739 100644 --- a/ports/zephyr/main.c +++ b/ports/zephyr/main.c @@ -34,7 +34,7 @@ #include #endif -#ifdef CONFIG_USB +#ifdef CONFIG_USB_DEVICE_STACK #include #endif @@ -140,7 +140,7 @@ soft_reset: #endif mp_init(); - #ifdef CONFIG_USB + #ifdef CONFIG_USB_DEVICE_STACK usb_enable(NULL); #endif