From: Jimmy Assarsson <extja@xxxxxxxxxx> This patch series will add support for the Kvaser USB hydra family. Patches 01-04 and 09-10 contains minor fixes/improvements for the current driver. Patch "can: kvaser_usb: Add driver name to printouts" from the first version of this patch series is replaced by patches 05-08. See discussion with Marc here https://marc.info/?t=152472147500003&r=1&w=2 Patch 11 (Split driver into...) will split the current driver into kvaser_usb.h kvaser_usb_core.c kvaser_usb_leaf.c. Where family common functionality is kept in kvaser_usb_core.c and leaf specific functionality is moved to kvaser_usb_leaf.c. Patch 12 adds support for the hydra family. The USB communication concept is similar to the leaf and USBcanII driver. The driver will send and receive hydra commands, where a command number is used to identify the command. However, for hydra devices it is possible to address to which thread in firmware a certain command shall be sent to. And vice versa it is possible to determine which firmware thread sent the command. The firmware threads are denoted hydra entity (HE). Firmware will allocate HE addresses for each HE dynamically at boot. Hence, the driver need to enumerate the HE addresses. Jimmy Assarsson (12): can: kvaser_usb: Remove unnecessary return can: kvaser_usb: Remove unused commands and defines can: kvaser_usb: Rename message/msg to command/cmd can: kvaser_usb: Replace USB timeout constants with one define can: kvaser_usb: Add pointer to struct usb_interface into struct kvaser_usb can: kvaser_usb: Refactor kvaser_usb_get_endpoints() can: kvaser_usb: Refactor kvaser_usb_init_one() can: kvaser_usb: Improve logging messages can: kvaser_usb: Fix typos can: kvaser_usb: Add SPDX GPL-2.0 license identifier can: kvaser_usb: Split driver into kvaser_usb_core.c and kvaser_usb_leaf.c can: kvaser_usb: Add support for Kvaser USB hydra family drivers/net/can/usb/Kconfig | 14 +- drivers/net/can/usb/Makefile | 2 +- drivers/net/can/usb/kvaser_usb.c | 2085 ----------------- drivers/net/can/usb/kvaser_usb/Makefile | 2 + drivers/net/can/usb/kvaser_usb/kvaser_usb.h | 188 ++ .../net/can/usb/kvaser_usb/kvaser_usb_core.c | 835 +++++++ .../net/can/usb/kvaser_usb/kvaser_usb_hydra.c | 2028 ++++++++++++++++ .../net/can/usb/kvaser_usb/kvaser_usb_leaf.c | 1366 +++++++++++ 8 files changed, 4433 insertions(+), 2087 deletions(-) delete mode 100644 drivers/net/can/usb/kvaser_usb.c create mode 100644 drivers/net/can/usb/kvaser_usb/Makefile create mode 100644 drivers/net/can/usb/kvaser_usb/kvaser_usb.h create mode 100644 drivers/net/can/usb/kvaser_usb/kvaser_usb_core.c create mode 100644 drivers/net/can/usb/kvaser_usb/kvaser_usb_hydra.c create mode 100644 drivers/net/can/usb/kvaser_usb/kvaser_usb_leaf.c -- Changes in v2: - Removed patch "can: kvaser_usb: Increase correct stats counter in kvaser_usb_rx_can_msg()", since it's already applied. - Replace patch "can: kvaser_usb: Add driver name to printouts" with "can: kvaser_usb: Add pointer to struct usb_interface into struct kvaser_usb", "can: kvaser_usb: Refactor kvaser_usb_get_endpoints()", "can: kvaser_usb: Refactor kvaser_usb_init_one()" and "can: kvaser_usb: Improve logging messages". 2.17.0 -- To unsubscribe from this list: send the line "unsubscribe linux-can" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html