]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
can: peak_usb: fix USB FD devices potential malfunction
authorStephane Grosjean <stephane.grosjean@hms-networks.com>
Thu, 24 Jul 2025 08:13:19 +0000 (10:13 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 15 Aug 2025 10:04:59 +0000 (12:04 +0200)
commit1abd9dc18008962732e2e58ddc6236e4c7a3d2bc
tree6de3250dfff5f0283e02868f32ee144c2d391470
parent1c38196defef951a129c081360d02e459623ac8d
can: peak_usb: fix USB FD devices potential malfunction

[ Upstream commit 788199b73b6efe4ee2ade4d7457b50bb45493488 ]

The latest firmware versions of USB CAN FD interfaces export the EP numbers
to be used to dialog with the device via the "type" field of a response to
a vendor request structure, particularly when its value is greater than or
equal to 2.

Correct the driver's test of this field.

Fixes: 4f232482467a ("can: peak_usb: include support for a new MCU")
Signed-off-by: Stephane Grosjean <stephane.grosjean@hms-networks.com>
Link: https://patch.msgid.link/20250724081550.11694-1-stephane.grosjean@free.fr
Reviewed-by: Vincent Mailhol <mailhol.vincent@wanadoo.fr>
[mkl: rephrase commit message]
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/can/usb/peak_usb/pcan_usb_fd.c