-
Notifications
You must be signed in to change notification settings - Fork 677
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for SO_TS_CLOCK sockopt for packet timestamping on FreeBSD. #2058
Comments
Yeah, that sounds reasonable. It's pretty easy to add a new sockopt to Nix. |
devnexen
added a commit
to devnexen/nix
that referenced
this issue
Aug 11, 2023
devnexen
added a commit
to devnexen/nix
that referenced
this issue
Aug 26, 2023
devnexen
added a commit
to devnexen/nix
that referenced
this issue
Aug 26, 2023
github-merge-queue bot
pushed a commit
that referenced
this issue
Aug 27, 2023
* introduces FreeBSD's SO_TS_CLOCK into net::sys::socket::sockopt. close GH-2058. * CHANGELOG entry * changes from feedback
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
As of FreeBSD 11.3, callers can control which clock is used for reporting packet receipt timestamps (in part for choosing between CLOCK_MONOTONIC and CLOCK_REALTIME). See the SO_TS_CLOCK section in man getsockopt(2). As of 0.2.146 Rust's libc added the relevant optvals for doing this (see rust-lang/libc@694e371).
I've been working on a handwritten proof of concept implementation in Rust for CLOCK_MONOTONIC here, and would be up for trying to add it back into nix if there's interest. Note that this is exclusive to FreeBSD as far as I know, no other bsd-likes support this to my knowledge.
The text was updated successfully, but these errors were encountered: