File tree Expand file tree Collapse file tree 7 files changed +10
-50
lines changed
samples/net/sockets/echo_server Expand file tree Collapse file tree 7 files changed +10
-50
lines changed Original file line number Diff line number Diff line change @@ -24,10 +24,6 @@ target_sources_ifdef(CONFIG_NET_TCP app PRIVATE src/tcp.c)
2424target_sources_ifdef(CONFIG_NET_VLAN app PRIVATE src/vlan.c)
2525target_sources_ifdef(CONFIG_NET_L2_IPIP app PRIVATE src/tunnel.c)
2626
27- if (CONFIG_USB_DEVICE_STACK)
28- target_sources (app PRIVATE src/usb.c)
29- endif ()
30-
3127if (CONFIG_USB_DEVICE_STACK_NEXT)
3228 target_sources (app PRIVATE src/usb.c)
3329 include (${ZEPHYR_BASE} /samples/subsys/usb/common/common.cmake)
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -4,4 +4,6 @@ CONFIG_LOG=y
44CONFIG_USBD_LOG_LEVEL_WRN=y
55CONFIG_UDC_DRIVER_LOG_LEVEL_WRN=y
66
7+ CONFIG_NET_L2_ETHERNET=y
8+
79CONFIG_SYSTEM_WORKQUEUE_STACK_SIZE=2048
Original file line number Diff line number Diff line change @@ -75,18 +75,15 @@ tests:
7575 sample.net.sockets.echo_server.b91_802154 :
7676 extra_args : EXTRA_CONF_FILE="overlay-802154.conf"
7777 platform_allow : tlsr9518adk80d
78- sample.net.sockets.echo_server.usbnet :
79- depends_on : usb_device
78+ sample.net.sockets.echo_server.usbd_cdc_ncm :
79+ depends_on : usbd
8080 harness : net
81- extra_args : EXTRA_CONF_FILE="overlay-netusb.conf"
81+ extra_args : EXTRA_CONF_FILE="overlay-usbd.conf"
82+ EXTRA_DTC_OVERLAY_FILE="usbd_cdc_ncm.overlay"
8283 tags :
8384 - net
8485 - usb
85- # native_sim usb driver does not work with CONFIG_POSIX_API
86- platform_exclude :
87- - native_sim
88- - native_sim/native/64
89- sample.net.sockets.echo_server.openthread :
86+ sample.net.sockets.echo_server.nrf_openthread :
9087 extra_args : EXTRA_CONF_FILE="overlay-ot.conf"
9188 slow : true
9289 tags :
Original file line number Diff line number Diff line change @@ -107,7 +107,7 @@ static inline bool is_tunnel(struct net_if *iface)
107107}
108108#endif /* CONFIG_NET_L2_IPIP */
109109
110- #if defined(CONFIG_USB_DEVICE_STACK ) || defined( CONFIG_USB_DEVICE_STACK_NEXT )
110+ #if defined(CONFIG_USB_DEVICE_STACK_NEXT )
111111int init_usb (void );
112112#else
113113static inline int init_usb (void )
Original file line number Diff line number Diff line change 77#include <zephyr/logging/log.h>
88LOG_MODULE_DECLARE (net_echo_server_sample , LOG_LEVEL_DBG );
99
10- #include <zephyr/usb/usb_device.h>
11- #include <zephyr/net/net_config.h>
12-
13- #if defined(CONFIG_USB_DEVICE_STACK_NEXT )
1410#include <sample_usbd.h>
11+ #include <zephyr/net/net_config.h>
1512
1613static struct usbd_context * sample_usbd ;
1714
18- static int enable_usb_device_next (void )
15+ int init_usb (void )
1916{
2017 int err ;
2118
@@ -29,28 +26,6 @@ static int enable_usb_device_next(void)
2926 return err ;
3027 }
3128
32- return 0 ;
33- }
34- #endif /* CONFIG_USB_DEVICE_STACK_NEXT */
35-
36- int init_usb (void )
37- {
38- #if defined(CONFIG_USB_DEVICE_STACK )
39- int ret ;
40-
41- ret = usb_enable (NULL );
42- if (ret != 0 ) {
43- LOG_ERR ("Cannot enable USB (%d)" , ret );
44- return ret ;
45- }
46- #endif /* CONFIG_USB_DEVICE_STACK */
47-
48- #if defined(CONFIG_USB_DEVICE_STACK_NEXT )
49- if (enable_usb_device_next ()) {
50- return 0 ;
51- }
52- #endif /* CONFIG_USB_DEVICE_STACK_NEXT */
53-
5429 (void )net_config_init_app (NULL , "Initializing network" );
5530
5631 return 0 ;
File renamed without changes.
You can’t perform that action at this time.
0 commit comments