zephyr/dts
Aurelien Jarno 7688f49065 drivers: usb_dc_stm32: change all endpoints to bidirectional
The various STM32 reference manuals sometimes define the USB endpoints
as IN or OUT only and sometimes as bidirectional, even in the same
manual. This is likely because the OTG implementation has one set of
registers for the IN endpoints and one other set for OUT endpoints.
However at the end a given endpoint address can both transmit and
receive data.

This causes some confusion how to declare the endpoints in the device
tree, and depending on the SoC, they are either the same number of IN
and OUT endpoints declared, or they are declared as bidirectional. At
the end it doesn't really matter given how the driver uses those values:

    #define NUM_IN_EP (CONFIG_USB_NUM_BIDIR_ENDPOINTS + \
                       CONFIG_USB_NUM_IN_ENDPOINTS)

    #define NUM_OUT_EP (CONFIG_USB_NUM_BIDIR_ENDPOINTS + \
                        CONFIG_USB_NUM_OUT_ENDPOINTS)

    #define NUM_BIDIR_EP NUM_OUT_EP

This patch therefore cleanup the driver, the DTS, and the DTS fixups to
only define the number of bidirectional endpoints.

In addition to the cleanup, that fixes a regression introduced by commit
52eacf16a2 ("driver: usb: add check for endpoint capabilities"), which
introduced a wrong check for SoC only defining the number of
bidirectional endpoints.

Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2018-06-18 15:24:15 -04:00
..
arc dts: arc: Fix IRQ priorities for quark_se_c1000_ss 2018-06-01 07:40:30 -04:00
arm drivers: usb_dc_stm32: change all endpoints to bidirectional 2018-06-18 15:24:15 -04:00
bindings can: Add can support for STM32L432 2018-06-18 15:23:29 -04:00
common dts: common.dts: trivial whitespace cleanup 2018-02-22 18:52:42 +01:00
nios2 dts: nios2-qemu: add device tree support 2018-05-17 14:09:15 -07:00
riscv32 dts: riscv32: riscv32-qemu: Add device tree support 2018-06-13 08:47:52 -04:00
x86 dts: x86: Fix wrong interrupt number for I2C 2018-05-28 08:45:58 -04:00
xtensa DTS: interrupt controller: Define IRQ priorities for CAVS & DW ICTL 2018-06-11 17:27:58 -04:00
Kconfig dts: nrf: Expand nRF DTS to support watchdog 2018-05-14 10:28:23 -05:00