On 2022-12-16 12:52:43 [+0100], Marek Vasut wrote: > > Also it might be worth checking if the DMA mode makes any sense if the > > FIFO is so small. > > If you want to push a lot of data through the UART without refilling the > small FIFO all the time and getting a lot of IRQs, that's where the DMA > comes in. Maybe I misunderstood this comment ? I have no idea how this works in detail. However: if you FIFO which is 16 bytes deep then filling it means 16 writes and so one interrupt every 16 bytes. If the DMA engine is the "average slave dma support" then it gets programmed to fill 16 bytes and then issues an interrupt again. The "lucky" case if you can program say 512 bytes (or so) and the DMA engines itself is able to fill the FIFO 32 times without involving the CPU. The last case is clear win. If you have the 16 bytes-DMA case then you would have to check what is cheaper: programming the DMA engine for 16 bytes or stuffing it directly into the FIFO. If the DMA engine supports the larger case say 512 and refills the FIFO on its own, then using it makes sense. However this makes usually sense for larger transfers. Having a console on it usually leads to more overhead because you receive usually say two bytes a second (unless you are a fast typer). Sending depends on the usecase and the peak is usually during boot. People doing BT via UART usually want to use DMA because of the insane amount of data, that is pumped. Sebastian