-
Notifications
You must be signed in to change notification settings - Fork 1k
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 sockaddr_vm definition for Fuchsia #4194
Conversation
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @tgross35 (or someone else) some time within the next two weeks. Please see the contribution instructions for more information. Namely, in order to ensure the minimum review times lag, PR authors and assigned reviewers should ensure that the review label (
|
src/fuchsia/mod.rs
Outdated
pub svm_reserved: u16, | ||
pub svm_port: crate::in_port_t, | ||
pub svm_cid: u32, |
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.
Usually we use the c_*
types if that is how they are defined in the source.
pub svm_reserved: u16, | |
pub svm_port: crate::in_port_t, | |
pub svm_cid: u32, | |
pub svm_reserved: c_short, | |
pub svm_port: crate::in_port_t, | |
pub svm_cid: c_int, |
Do you have a link to relevant header for fuchsia?
This should also get added to |
This lgtm but I'm not sure what to compare it against. Is the relevant fuchsia header public? |
https://cs.opensource.google/fuchsia/fuchsia/+/main:src/paravirtualization/lib/vsock/vm_sockets.h;drc=4050ee185f9701a852d764e120bc0886917e3c1a is the most relevant header today. It's public but it is not in the best location - we are still debating exactly where to put it. Regardless of where it is, I don't expect the definition to change (and if it does, I'll update the bindings here to match). (I tried to reply inline but may have failed - I'm not very practiced with GitHub-ing) |
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.
https://cs.opensource.google/fuchsia/fuchsia/+/main:src/paravirtualization/lib/vsock/vm_sockets.h;drc=4050ee185f9701a852d764e120bc0886917e3c1a is the most relevant header today. It's public but it is not in the best location - we are still debating exactly where to put it. Regardless of where it is, I don't expect the definition to change (and if it does, I'll update the bindings here to match).
Thanks, that works for me :) Just trying to keep everything crosslinked since it can can be difficult to find sources for everything down.
(I tried to reply inline but may have failed - I'm not very practiced with GitHub-ing)
I assume it put your comments in a review and wants you to submit them in a batch - It seems to do this sometimes but I have no clue what decides that should happen...
@rustbot label +stable-nominated |
Oh wait, one more thing - it looks like the field is called |
That seems like a good idea - done. In practice it's rare to ever type this field but consistent is better than inconsistency. |
Description
This adds a definition of
struct sockaddr_vm
for FuchsiaSources
man vsock
documents this type on most platforms. The Fuchsia definition matchesLinux except that we do not (currently) have support for flags.
Checklist
libc-test does not have support for Fuchsia currently.