can: gs_usb: add CAN-FD support
authorPeter Fink <pfink@christ-es.de>
Tue, 7 Dec 2021 18:35:31 +0000 (19:35 +0100)
committerMarc Kleine-Budde <mkl@pengutronix.de>
Thu, 10 Mar 2022 08:49:15 +0000 (09:49 +0100)
commit26949ac935e37ad47fbe35cf0ff6e51aeeb15c6f
tree7bf66e538e3c3cdb87b7f461446d076196e0ac43
parentc359931d2545173c4328d828643035259a0ba936
can: gs_usb: add CAN-FD support

CANtact Pro from Linklayer is the first gs_usb compatible device
supporting CAN-FD with a different HW and re-written candlelight FW.

Support for CAN-FD is indicated by the device setting the
GS_CAN_FEATURE_FD flag. CAN-FD support is requested by the driver with
the GS_CAN_MODE_FD flag. The CAN-FD specific data bit timing
parameters are set with the GS_USB_BREQ_DATA_BITTIMING control
message.

This patch is based on the Eric Evenchick's gs_usb_fd driver (which
itself is a fork of gs_usb). The gs_usb_fd code base was reintegrated
into the gs_usb driver, and reworked to not break the existing
classical-CAN only hardware.

Link: https://lore.kernel.org/all/20220309124132.291861-16-mkl@pengutronix.de
Link: https://github.com/linklayer/gs_usb_fd/issues/2
Co-developed-by: Eric Evenchick <eric@evenchick.com>
Signed-off-by: Eric Evenchick <eric@evenchick.com>
Signed-off-by: Peter Fink <pfink@christ-es.de>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
drivers/net/can/usb/gs_usb.c