Commit Graph

12 Commits

Author SHA1 Message Date
Xiang Xiao fcb3e84c24 can: Merge netpacket/can.h into nuttx/can.h
To align with the layout of Linux can header file.

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2024-08-26 05:05:31 -04:00
gaohedong dc651e090e net/can: Add SO_RCVBUF option for can socket
If the CAN stack receiving packets fast, but the application layer reading packets slow. Then `conn->readahead` will continue to grow, leading to memory leaks. Finally CAN stack potentially starve out all IOB buffers. To prevent memory leaks, users can restrict can socket buffer length.

Signed-off-by: gaohedong <gaohedong@xiaomi.com>
2024-06-14 19:54:07 +08:00
xucheng5 b756a7c3a9 socketcan : support error frame filter
add error mask for CAN_RAW_ERR_FILTER

Signed-off-by: xucheng5 <xucheng5@xiaomi.com>
2023-09-08 21:14:09 +03:00
chao an 7d1763a57c net/assert: remove all unnecessary check for psock/conn
Since inet/socket layer already contains sanity checks, so remove unnecessary lower half checks

Signed-off-by: chao an <anchao@xiaomi.com>
2023-08-30 20:36:49 +08:00
Petro Karashchenko c70b7f6b3d nuttx: improve C89 compatibility in common code
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-05-19 02:40:38 +08:00
zhanghongyu 91e13c47ae net: remove conn-related casts
remove redundant casts associated with psock

Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-05-10 19:32:09 -03:00
dongjiuzhu1 e6f8ccda4a net/get/setsockopt: add si_get/setsockopt interface to simply get/setsockopt
move private option to protocol sockif

Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2022-11-23 15:01:54 +08:00
raiden00pl 2b0ce033d7 net/can/can_xxxsockopt.c: correct the code alignment 2022-10-21 16:24:13 -03:00
raiden00pl 5b678ab12e net/can/can_setsockopt.c: fix assertion, value can be NULL 2022-02-13 23:16:00 +08:00
Peter van der Perk ba5fe5cee3 SocketCAN: Fixed dropping timestamped frames when running in CAN2.0B 2020-06-17 15:17:38 -07:00
Ouss4 c8d83e0a88 net/can/can_setsockopt&can_getsockopt.c: Initialiaze ret variable to
eliminate any warning.
2020-06-15 12:20:32 -06:00
Peter van der Perk 55d9e5f7af net: Add SocketCAN support 2020-06-15 08:07:19 -06:00