Skip to content
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

vsock: Don't allow duplicate CIDs #434

Merged
merged 2 commits into from
Sep 19, 2023

Conversation

techiepriyansh
Copy link
Contributor

@techiepriyansh techiepriyansh commented Aug 30, 2023

Currently, while updating the cid_map, it is not checked if the map already contained a key with the same CID before. So, fail to create the vsock thread if the CID is already in use.

Fixes #432.

@techiepriyansh techiepriyansh changed the title vsock: Fail to parse VsockArgs if duplicate CIDs specified vsock: Don't allow duplicate CIDs Sep 12, 2023
Copy link
Member

@stefano-garzarella stefano-garzarella left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@techiepriyansh thanks for the fix!

Currently, while updating the `cid_map`, it is not checked if the map
already contained a key with the same CID before. So, fail to create the
vsock thread if the CID is already in use.

Signed-off-by: Priyansh Rathi <techiepriyansh@gmail.com>
@stefano-garzarella
Copy link
Member

@stsquad @mathieupoirier can you take a look?

It's a simple bug fix we introduce when starting to support sibling VMs.

@vireshk vireshk merged commit 38caab2 into rust-vmm:main Sep 19, 2023
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Potential Bug: The update of cid_map doesn't check confict cid.
3 participants