forked from zephyrproject-rtos/zephyr
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
net: socket: Add SO_TIMESTAMPING data to messages received via socket
Add returning timestamp of received packet in ancillary data buffer in `msghdr` structure. This commit enables getting timestamp of the received packet by calling `recvmsg()` function. The function returns in the `msg_control` field timestamp if following criteria are met: - `CONFIG_NET_CONTEXT_TIMESTAMPING` is set - `SO_TIMESTAMPING` socket option has `SOF_TIMESTAMPING_RX_HARDWARE` option enabled for that socket - driver used by sockets supports packet timestamping Signed-off-by: Adam Wojasinski <[email protected]>
- Loading branch information
1 parent
50cfe12
commit ee06da5
Showing
1 changed file
with
36 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters