incubator-nuttx/net/can
chao an 2eb9abc3d8 net/can: fix can mssage corruption if enable NET_TIMESTAMP
Timestamp location in can message has changed,
In the original logic timestamp is saved at the end of the data segment:

io_data
   -------------------------------------------------
   |         CAN message            |  Time Stamp  |
   -------------------------------------------------
   |<---------------     io_len   ---------------->|

In the new structure timestamps will reuse NET_LL_GUARDSIZE to isolate CAN messages:
io_data       io_offset
   -------------------------------------------------
   |  Time Stamp  |         CAN message            |
   -------------------------------------------------
                  |<--------    io_len   --------->|

This PR will:
1. Increase NET_LL_GUARDSIZE to 16 (sizeof(struct timeval)) if NET_CAN && NET_TIMESTAMP are enabled
2. Apply timestamp to adapt to the new structure

Signed-off-by: chao an <anchao@xiaomi.com>
2023-04-27 00:30:58 +08:00
..
Kconfig Remove the tail spaces from all files except Documentation 2023-02-26 13:24:24 -08:00
Make.defs
can.h net: Remove protocol argument from si_setup callback 2023-02-13 22:41:19 +08:00
can_callback.c net/can: fix can mssage corruption if enable NET_TIMESTAMP 2023-04-27 00:30:58 +08:00
can_conn.c Performance optimizations in connection allocations. 2023-02-28 14:23:16 +01:00
can_getsockopt.c net/get/setsockopt: add si_get/setsockopt interface to simply get/setsockopt 2022-11-23 15:01:54 +08:00
can_input.c net/netdev: Avoid hardcoded guardsize when using d_iob 2023-01-18 14:41:07 +08:00
can_notifier.c
can_poll.c net/devif_poll: optimize device buffer alloc in txpoll 2023-01-13 16:41:10 +08:00
can_recvmsg.c net/can: fix can mssage corruption if enable NET_TIMESTAMP 2023-04-27 00:30:58 +08:00
can_sendmsg.c Bugfixed the SocketCAN send via setting the dev->d_len to dev->d_sndlen. The dev->d_len wouldn't be assigned otherwise. 2023-01-27 23:08:05 +08:00
can_setsockopt.c net/get/setsockopt: add si_get/setsockopt interface to simply get/setsockopt 2022-11-23 15:01:54 +08:00
can_sockif.c net: Make si_accept callback optional 2023-03-06 20:58:27 +02:00