History

can: virtio: Fix comment in UAPI header

When compile testing the UAPI headers with clang, there is an warning turned error for using a C++ style ('//') comment, which is explicitly forbidden for UAPI headers. In file included from <built-in>:1: ./usr/include/linux/virtio_can.h:29:35: error: // comments are not allowed in this language [-Werror,-Wcomment] 29 | #define VIRTIO_CAN_MAX_DLEN 64 // this is like CANFD_MAX_DLEN | ^ 1 error generated. Switch to a standard C style comment.

Nathan Chancellor committed 5 months ago

Commit 8cb2c921 parent 083082a1 file · +1 −1Browse files

Showing the changes to include/uapi (1 of 1 file). Show all

Unified · Split

include/uapi/linux/virtio_can.h+1−1
@@ -26,7 +26,7 @@ · 25 unmodified lines
26#define VIRTIO_CAN_FLAGS_FD 0x400026#define VIRTIO_CAN_FLAGS_FD 0x4000
27#define VIRTIO_CAN_FLAGS_RTR 0x200027#define VIRTIO_CAN_FLAGS_RTR 0x2000
28 28
29#define VIRTIO_CAN_MAX_DLEN 64 // this is like CANFD_MAX_DLEN29#define VIRTIO_CAN_MAX_DLEN 64 /* this is like CANFD_MAX_DLEN */
30 30
31struct virtio_can_config {31struct virtio_can_config {
32#define VIRTIO_CAN_S_CTRL_BUSOFF (1u << 0) /* Controller BusOff */32#define VIRTIO_CAN_S_CTRL_BUSOFF (1u << 0) /* Controller BusOff */