zephyr/drivers/usb/udc
Tomasz Moń 962a53ef8e drivers: udc_dwc2: Avoid unnecessary context switches
DWC2 thread must acquire UDC mutex before accessing shared resources
(peripheral registers and software data structures). Whenever software
enqueues a buffer, the caller first obtains mutex, adds the buffer to
the list, posts event to wake up DWC2 thread and releases mutex. If DWC2
thread has higher priority than the task currently holding a mutex,
there will be two completely unnecessary task switches: DWC2 will switch
in, try to obtain mutex, and then the control will be returned to the
mutex holder.

Avoid the unnecessary task switches by locking scheduler prior to
obtaining the mutex and unlocking scheduler after releasing the mutex.

Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
2025-03-07 21:29:09 +01:00
..
CMakeLists.txt drivers: udc: add support for Renesas RA USB device 2024-12-12 16:23:48 +01:00
Kconfig drivers: udc: add support for Renesas RA USB device 2024-12-12 16:23:48 +01:00
Kconfig.ambiq
Kconfig.dwc2
Kconfig.it82xx2
Kconfig.kinetis
Kconfig.mcux
Kconfig.nrf
Kconfig.numaker
Kconfig.renesas_ra drivers: udc: add support for Renesas RA USB device 2024-12-12 16:23:48 +01:00
Kconfig.rpi_pico
Kconfig.skeleton
Kconfig.smartbond
Kconfig.stm32 drivers: udc: stm32: update STM32_CLOCK_CHECK definition 2025-01-31 11:50:01 +01:00
Kconfig.virtual
udc_ambiq.c drivers: udc: Do not allow lock/unlock to fail 2025-02-11 10:13:03 +01:00
udc_common.c usb: device_next: remove redundant memset() after net_buf_alloc.*() 2024-12-17 11:38:22 +00:00
udc_common.h
udc_dwc2_vendor_quirks.h
udc_dwc2.c drivers: udc_dwc2: Avoid unnecessary context switches 2025-03-07 21:29:09 +01:00
udc_dwc2.h
udc_it82xx2.c drivers: udc: Do not allow lock/unlock to fail 2025-02-11 10:13:03 +01:00
udc_kinetis.c drivers: udc: Do not allow lock/unlock to fail 2025-02-11 10:13:03 +01:00
udc_mcux_ehci.c drivers: udc: Do not allow lock/unlock to fail 2025-02-11 10:13:03 +01:00
udc_mcux_ip3511.c drivers: udc_mcux_ip3511: fix typo in transfer handler 2025-02-25 07:55:42 +01:00
udc_nrf.c drivers: usb: do not enabled nRF USBREG interrupt 2025-02-27 23:18:39 +00:00
udc_numaker.c drivers: udc: Fix log in "disable" function 2025-02-21 15:14:17 +00:00
udc_renesas_ra.c drivers: Correct value of event macro for all Renesas SoC 2025-02-28 18:29:17 +01:00
udc_rpi_pico.c drivers: udc: Fix log in "disable" function 2025-02-21 15:14:17 +00:00
udc_skeleton.c drivers: udc: Fix log in "disable" function 2025-02-21 15:14:17 +00:00
udc_smartbond.c drivers: udc: Do not allow lock/unlock to fail 2025-02-11 10:13:03 +01:00
udc_stm32.c drivers: udc_stm32: handle ZLP flag for control transfers as well 2025-02-25 20:41:03 +01:00
udc_virtual.c drivers: udc: Do not allow lock/unlock to fail 2025-02-11 10:13:03 +01:00