-
Notifications
You must be signed in to change notification settings - Fork 201
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
[LibOS] Handle IP_RECVERR
socket option as a no-op
#678
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 1 of 1 files at r1, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion, not enough approvals from maintainers (1 more required) (waiting on @boryspoplawski)
libos/src/net/ip.c
line 285 at r1 (raw file):
/* See the comment in `set_ipv4_option` for why we handle it this way. */ return 0; }
Actually, you could just move this under the switch (optname)
-- this will basically be just 2 lines of code.
I guess you don't want to call DkStreamAttributesQueryByHandle()
unnecessarily, but on the other hand -- this setsockopt()
is a rare operation, so we don't lose any performance on this. Not blocking though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 1 of 1 files at r1, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @boryspoplawski)
This socket option allows for later retrieval of detailed error descriptions that happened on the socket. We do not support such retrieval, so allowing to set this option basically defers the moment the app notices that it's not supported from the call to `setsockopt`, to the moment the error condition actually happens (which might be never). Signed-off-by: Borys Popławski <[email protected]>
2542b4a
to
8b112b4
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 0 of 1 files reviewed, all discussions resolved, not enough approvals from maintainers (2 more required), not enough approvals from different teams (1 more required, approved so far: ITL) (waiting on @dimakuv and @mkow)
libos/src/net/ip.c
line 285 at r1 (raw file):
Previously, dimakuv (Dmitrii Kuvaiskii) wrote…
Actually, you could just move this under the
switch (optname)
-- this will basically be just 2 lines of code.I guess you don't want to call
DkStreamAttributesQueryByHandle()
unnecessarily, but on the other hand -- thissetsockopt()
is a rare operation, so we don't lose any performance on this. Not blocking though.
Done.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 1 of 1 files at r2, all commit messages.
Reviewable status: all files reviewed, all discussions resolved, not enough approvals from maintainers (1 more required)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 1 of 1 files at r2, all commit messages.
Reviewable status: complete! all files reviewed, all discussions resolved
Description of the changes
This socket option allows for later retrieval of detailed error descriptions that happened on the socket. We do not support such retrieval, so allowing to set this option basically defers the moment the app notices that it's not supported from the call to
setsockopt
, to the moment the error condition actually happens (which might be never).Fixes #673
How to test this PR?
Try running repro code from #673
This change is