]> git.itanic.dy.fi Git - linux-stable/commit
can: at91_can: at91_alloc_can_err_skb() introduce new function
authorMarc Kleine-Budde <mkl@pengutronix.de>
Thu, 28 Sep 2023 09:15:15 +0000 (11:15 +0200)
committerMarc Kleine-Budde <mkl@pengutronix.de>
Thu, 5 Oct 2023 19:47:39 +0000 (21:47 +0200)
commitdd94a2f1f2f848a2534c4b0115db752a55b7eb03
tree9dc0f5be26358c8520380e70e5413eaad50222b9
parent3db6154e44dba8626cd6e31e15bd29d1c3861ca8
can: at91_can: at91_alloc_can_err_skb() introduce new function

This is a preparation patch to convert the driver to make use of the
rx-offload helper. With rx-offload the received CAN frames are sorted
by their timestamp. Regular CAN RX'ed and TX'ed CAN frames are
timestamped by the hardware. Error events are not.

Introduce a new function at91_alloc_can_err_skb() the allocates an
error SKB and reads the current timestamp from the controller.

Link: https://lore.kernel.org/all/20231005-at91_can-rx_offload-v2-26-9987d53600e0@pengutronix.de
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
drivers/net/can/at91_can.c