can: mcp251xfd: ring: change order of TX and RX FIFOs
authorMarc Kleine-Budde <mkl@pengutronix.de>
Tue, 3 Aug 2021 14:33:48 +0000 (16:33 +0200)
committerMarc Kleine-Budde <mkl@pengutronix.de>
Thu, 24 Feb 2022 07:46:59 +0000 (08:46 +0100)
commit62713f0d9a38f2e0b772e6448adfa9c405316237
treed88171c9327640c80610ce76c012cdb4207e5e9a
parent617283b9c4dbc1384b063f59c840e1d1ab612108
can: mcp251xfd: ring: change order of TX and RX FIFOs

This patch actually changes the order of the TX and RX FIFOs.

This gives the opportunity to minimize the number of SPI transfers in
the IRQ handler. The read of the IRQ status register and RX FIFO
status registers can be combined into single SPI transfer. If the RX
ring uses FIFO 1, the overall length of the transfer is smaller than
in the original layout, where the RX FIFO comes after the TX FIFO.

Link: https://lore.kernel.org/all/20220217103826.2299157-5-mkl@pengutronix.de
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
drivers/net/can/spi/mcp251xfd/mcp251xfd-ring.c
drivers/net/can/spi/mcp251xfd/mcp251xfd.h