[automerger skipped] Merge sc-qpr1-dev-plus-aosp-without-vendor@7810918 am: 79fd00fce0 -s ours am: 9b67d0dafd -s ours

am skip reason: Merged-In I3c2e54dbcdbe3a99017ad31bfc4e76984335b330 with SHA-1 e49a692386 is already in history

Original change: https://googleplex-android-review.googlesource.com/c/platform/external/rust/crates/vsock/+/16279007

Change-Id: I78012352d30cffaf20581f91ea4bf5fd7be9684b
tree: 5ee1a8fe64339ca9dc9be1b169491460b23237fb
  1. .cargo/
  2. .github/
  3. src/
  4. tests/
  5. .cargo_vcs_info.json
  6. .gitignore
  7. Android.bp
  8. Cargo.toml
  9. Cargo.toml.orig
  10. cargo2android.json
  11. LICENSE
  12. Makefile
  13. METADATA
  14. MODULE_LICENSE_APACHE2
  15. OWNERS
  16. README.md
  17. TEST_MAPPING
README.md

vsock-rs

Virtio socket support for Rust. Implements VsockListener and VsockStream which are analogous to the std::net::TcpListener and std::net::TcpStream types.

Usage

Refer to the crate documentation.

Testing

Prerequisites

You will need a recent qemu-system-x86_64 build in your path.

Host

Setup the required virtio kernel modules:

make kmod

Start the test vm, you can shutdown the vm with the keyboard shortcut Ctrl+A and then x:

make vm

Tests

Run the test suite with:

make check