]> git.dujemihanovic.xyz Git - u-boot.git/commit
usb: dwc3: allocate setup_buf with dma_alloc_coherent()
authorNeil Armstrong <neil.armstrong@linaro.org>
Fri, 11 Oct 2024 14:38:24 +0000 (16:38 +0200)
committerMattijs Korpershoek <mkorpershoek@baylibre.com>
Tue, 15 Oct 2024 09:03:56 +0000 (11:03 +0200)
commit1f12fc7e3350b179d17efaf5ba00fc3683cf33ec
treee28098ab347fb2380efd61dea147db732e3449f8
parentc54c72dec7948093b200ae1290575a1e9abbbb40
usb: dwc3: allocate setup_buf with dma_alloc_coherent()

Since setup_buf is also consumed by hardware DMA, aligns it's
allocation like other hardware buffers by introduce setup_buf_addr
populated by dma_alloc_coherent(), and use it to pass the physical
address of the buffer to the hardware.

Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
Reviewed-by: Marek Vasut <marex@denx.de>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20241011-u-boot-dwc3-gadget-dcache-fixup-v4-1-5f3498d8035b@linaro.org
Signed-off-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
drivers/usb/dwc3/core.h
drivers/usb/dwc3/ep0.c
drivers/usb/dwc3/gadget.c