Searched refs:zfilter (Results 1 – 4 of 4) sorted by relevance
/Zephyr-latest/include/zephyr/net/ |
D | socketcan_utils.h | 90 struct can_filter *zfilter) in socketcan_to_can_filter() argument 92 memset(zfilter, 0, sizeof(*zfilter)); in socketcan_to_can_filter() 94 zfilter->flags |= (sfilter->can_id & BIT(31)) != 0 ? CAN_FILTER_IDE : 0; in socketcan_to_can_filter() 95 zfilter->id = sfilter->can_id & BIT_MASK(29); in socketcan_to_can_filter() 96 zfilter->mask = sfilter->can_mask & BIT_MASK(29); in socketcan_to_can_filter() 105 static inline void socketcan_from_can_filter(const struct can_filter *zfilter, in socketcan_from_can_filter() argument 110 sfilter->can_id = zfilter->id; in socketcan_from_can_filter() 111 sfilter->can_id |= (zfilter->flags & CAN_FILTER_IDE) != 0 ? BIT(31) : 0; in socketcan_from_can_filter() 113 sfilter->can_mask = zfilter->mask; in socketcan_from_can_filter() 114 sfilter->can_mask |= (zfilter->flags & CAN_FILTER_IDE) != 0 ? BIT(31) : 0; in socketcan_from_can_filter()
|
/Zephyr-latest/tests/net/socket/can/src/ |
D | main.c | 102 struct can_filter zfilter = { 0 }; in ZTEST() local 111 socketcan_to_can_filter(&sfilter, &zfilter); in ZTEST() 113 LOG_HEXDUMP_DBG((const uint8_t *)&zfilter, sizeof(zfilter), "zfilter"); in ZTEST() 117 zassert_equal(zfilter.flags, expected.flags, "Flags not equal"); in ZTEST() 118 zassert_equal(zfilter.id, expected.id, "CAN id invalid"); in ZTEST() 119 zassert_equal(zfilter.mask, expected.mask, "id mask not set"); in ZTEST() 129 struct can_filter zfilter = { 0 }; in ZTEST() local 137 zfilter.flags = CAN_FILTER_IDE; in ZTEST() 138 zfilter.id = 1234U; in ZTEST() 139 zfilter.mask = 1234U; in ZTEST() [all …]
|
/Zephyr-latest/samples/net/sockets/can/src/ |
D | main.c | 34 static const struct can_filter zfilter = { variable 178 socketcan_from_can_filter(&zfilter, &sock_filter); in setup_socket()
|
/Zephyr-latest/subsys/net/lib/sockets/ |
D | sockets_can.c | 676 struct can_filter zfilter; in can_sock_setsockopt_vmeth() local 689 socketcan_to_can_filter(sfilter, &zfilter); in can_sock_setsockopt_vmeth() 692 &zfilter, sizeof(zfilter)); in can_sock_setsockopt_vmeth()
|