can: peak_usb: PCAN-USB: add support of loopback and one-shot mode
authorStephane Grosjean <s.grosjean@peak-system.com>
Fri, 25 Jun 2021 13:09:28 +0000 (15:09 +0200)
committerMarc Kleine-Budde <mkl@pengutronix.de>
Sun, 25 Jul 2021 09:36:28 +0000 (11:36 +0200)
commit3a7939495ce8213656419ed7dbbc7f32e9645bdf
treea7f52b43cfe14c00e33810f05768a963a4782292
parent1d0214a0f5db10d5dc37f4da980786cd094ae3e4
can: peak_usb: PCAN-USB: add support of loopback and one-shot mode

The CAN - USB PCAN-USB interface is able to generate one-shot frames
as well as loopback frames that it transmits starting from version 4.1
of its firmware.

This patch adds support for the one-shot and loopback functionality to
the driver, that can be activated if the embedded firmware allows it.
If the driver detects that the PCAN-USB device runs an old firmware
(< 4.1) it prints a message suggesting to contact
<support@peak-system.com> for a possible firmware update.

Link: https://lore.kernel.org/r/20210625130931.27438-3-s.grosjean@peak-system.com
Signed-off-by: Stephane Grosjean <s.grosjean@peak-system.com>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
drivers/net/can/usb/peak_usb/pcan_usb.c