summaryrefslogtreecommitdiffstats
path: root/drivers/ssb
diff options
context:
space:
mode:
authorMarc Kleine-Budde <mkl@pengutronix.de>2020-11-19 14:03:17 +0100
committerMarc Kleine-Budde <mkl@pengutronix.de>2020-11-26 11:50:32 +0100
commit4ba1cb39fce4464151517a37ce0ac0a1a3f580d6 (patch)
tree60ff929eb6808ebaf7b739c685f9c87c1c58c11a /drivers/ssb
parentcbf3d60329c4e11edcecac0c8fc6767b0f05e3a7 (diff)
downloadlinux-4ba1cb39fce4464151517a37ce0ac0a1a3f580d6.tar.bz2
can: gs_usb: fix endianess problem with candleLight firmware
The firmware on the original USB2CAN by Geschwister Schneider Technologie Entwicklungs- und Vertriebs UG exchanges all data between the host and the device in host byte order. This is done with the struct gs_host_config::byte_order member, which is sent first to indicate the desired byte order. The widely used open source firmware candleLight doesn't support this feature and exchanges the data in little endian byte order. This breaks if a device with candleLight firmware is used on big endianess systems. To fix this problem, all u32 (but not the struct gs_host_frame::echo_id, which is a transparent cookie) are converted to __le32. Cc: Maximilian Schneider <max@schneidersoft.net> Cc: Hubert Denkmair <hubert@denkmair.de> Reported-by: Michael Rausch <mr@netadair.de> Link: https://lore.kernel.org/r/b58aace7-61f3-6df7-c6df-69fee2c66906@netadair.de Tested-by: Oleksij Rempel <o.rempel@pengutronix.de> Fixes: d08e973a77d1 ("can: gs_usb: Added support for the GS_USB CAN devices") Link: https://lore.kernel.org/r/20201120103818.3386964-1-mkl@pengutronix.de Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Diffstat (limited to 'drivers/ssb')
0 files changed, 0 insertions, 0 deletions