summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorOliver Hartkopp <socketcan@hartkopp.net>2016-06-17 16:35:27 +0300
committerMarc Kleine-Budde <mkl@pengutronix.de>2016-06-17 16:39:46 +0300
commit6f3b911d5f29b98752e5da86a295210c0c4f4e14 (patch)
tree385a3c2b38bbee79bbec91ed6d5969eb49021820 /include
parent2b5f5f5dc114219dcd848fb0ff344acb413c11ef (diff)
downloadlinux-6f3b911d5f29b98752e5da86a295210c0c4f4e14.tar.xz
can: bcm: add support for CAN FD frames
The programming API of the CAN_BCM depends on struct can_frame which is given as array directly behind the bcm_msg_head structure. To follow this schema for the CAN FD frames a new flag 'CAN_FD_FRAME' in the bcm_msg_head flags indicates that the concatenated CAN frame structures behind the bcm_msg_head are defined as struct canfd_frame. This patch adds the support to handle CAN and CAN FD frames on a per BCM-op base. Main changes: - generally use struct canfd_frames instead if struct can_frames - use canfd_frame.flags instead of can_frame.can_dlc for private BCM flags - make all CAN frame sizes depending on the new CAN_FD_FRAME flags - separate between CAN and CAN FD when sending/receiving frames Due to the dependence of the CAN_FD_FRAME flag the former binary interface for classic CAN frames remains stable. Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Diffstat (limited to 'include')
-rw-r--r--include/uapi/linux/can/bcm.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/uapi/linux/can/bcm.h b/include/uapi/linux/can/bcm.h
index 7a291dc1ff15..cefb304414ba 100644
--- a/include/uapi/linux/can/bcm.h
+++ b/include/uapi/linux/can/bcm.h
@@ -99,5 +99,6 @@ enum {
#define RX_ANNOUNCE_RESUME 0x0100
#define TX_RESET_MULTI_IDX 0x0200
#define RX_RTR_FRAME 0x0400
+#define CAN_FD_FRAME 0x0800
#endif /* !_UAPI_CAN_BCM_H */