linux-stable/include/uapi/linux/can
Oliver Hartkopp 626332696d can: raw: add CAN XL support
Enable CAN_RAW sockets to read and write CAN XL frames analogue to the
CAN FD extension (new CAN_RAW_XL_FRAMES sockopt).

A CAN XL network interface is capable to handle Classical CAN, CAN FD and
CAN XL frames. When CAN_RAW_XL_FRAMES is enabled, the CAN_RAW socket checks
whether the addressed CAN network interface is capable to handle the
provided CAN frame.

In opposite to the fixed number of bytes for
- CAN frames (CAN_MTU = sizeof(struct can_frame))
- CAN FD frames (CANFD_MTU = sizeof(struct can_frame))
the number of bytes when reading/writing CAN XL frames depends on the
number of data bytes. For efficiency reasons the length of the struct
canxl_frame is truncated to the needed size for read/write operations.
This leads to a calculated size of CANXL_HDR_SIZE + canxl_frame::len which
is enforced on write() operations and guaranteed on read() operations.

NB: Valid length values are 1 .. 2048 (CANXL_MIN_DLEN .. CANXL_MAX_DLEN).

Acked-by: Vincent Mailhol <mailhol.vincent@wanadoo.fr>
Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net>
Link: https://lore.kernel.org/all/20220912170725.120748-8-socketcan@hartkopp.net
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2022-09-15 09:08:09 +02:00
..
bcm.h treewide: uapi: Replace zero-length arrays with flexible-array members 2022-06-28 21:26:05 +02:00
error.h can: error: add definitions for the different CAN error thresholds 2022-07-20 09:27:51 +02:00
gw.h can: gw: support modification of Classical CAN DLCs 2020-11-20 12:05:14 +01:00
isotp.h can: isotp: add support for transmission without flow control 2022-05-16 22:03:45 +02:00
j1939.h can: j1939: extend UAPI to notify about RX status 2021-08-04 12:11:52 +02:00
netlink.h can: netlink: report the CAN controller mode supported flags 2022-01-05 12:09:06 +01:00
raw.h can: raw: add CAN XL support 2022-09-15 09:08:09 +02:00
vxcan.h can: don't use deprecated license identifiers 2019-11-05 12:44:34 +01:00