summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2021-05-12Add metadata files am: fa467c1dd1 am: e2740908c1 am: b0ee5c13c5android-12.0.0_r32android-12.0.0_r29android-12.0.0_r28android-12.0.0_r27android-12.0.0_r26android-12.0.0_r21android-12.0.0_r20android-12.0.0_r19android-12.0.0_r18android-12.0.0_r16android12-qpr1-releaseandroid12-qpr1-d-s3-releaseandroid12-qpr1-d-s2-releaseandroid12-qpr1-d-s1-releaseandroid12-qpr1-d-releaseandroid12-devJorge E. Moreira
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1704407 Change-Id: Ic3eab2a44418506c474b744fdcf93a992eef7922
2021-05-12Add metadata files am: fa467c1dd1 am: e2740908c1Jorge E. Moreira
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1704407 Change-Id: I35cf2fe00bbbbc619310f10332caff1ddd54a798
2021-05-12Add metadata files am: fa467c1dd1Jorge E. Moreira
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1704407 Change-Id: Ieaf0ef115a7cfaf225f0b5a82afd62b706e1f1d3
2021-05-11Add metadata filesandroid-s-beta-2android-s-beta-1Jorge E. Moreira
Bug: 187839847 Change-Id: I0d6278674b0bdfb5ac59c9878b769b6c3461fb1a
2021-04-30[LSC] Add LOCAL_LICENSE_KINDS to external/rust/crates/vmm_vhost am: ↵Bob Badour
17c6610442 am: bf7284f199 am: 373ba53438 Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1690702 Change-Id: I7e45fefd4c170778e31f03b38777656f61b6c72f
2021-04-30[LSC] Add LOCAL_LICENSE_KINDS to external/rust/crates/vmm_vhost am: ↵Bob Badour
17c6610442 am: bf7284f199 Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1690702 Change-Id: I8ef0762cccfd8750882901a3635ba83c4170c37a
2021-04-30[LSC] Add LOCAL_LICENSE_KINDS to external/rust/crates/vmm_vhost am: 17c6610442Bob Badour
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1690702 Change-Id: I6fd5c6485de0c4e0ad3ca0d3ca87c436945182a2
2021-04-29[LSC] Add LOCAL_LICENSE_KINDS to external/rust/crates/vmm_vhostBob Badour
Added SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-BSD to: Android.bp Bug: 68860345 Bug: 151177513 Bug: 151953481 Test: m all Exempt-From-Owner-Approval: janitorial work Change-Id: I91d89b2ea6990a4665e1af35adee017233affdc8
2021-04-27[LSC] Add LOCAL_LICENSE_KINDS to external/rust/crates/vmm_vhostBob Badour
Added SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-BSD to: Android.bp Bug: 68860345 Bug: 151177513 Bug: 151953481 Test: m all Exempt-From-Owner-Approval: janitorial work Change-Id: I937deeaab48cf7bccbceb29f077190e31ccc4a87
2021-04-26Re-Add Android.bp file am: 200df3137a am: 8848ccf625 am: 7c1970469fJorge Moreira Broche
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1676155 Change-Id: I11f386841be7d6ea1c10069c3dfad0745d35183d
2021-04-26Re-Add Android.bp file am: 200df3137a am: 8848ccf625Jorge Moreira Broche
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1676155 Change-Id: Ie3f1dd12394d9dc4d1fa0afeab9637eb02cf4138
2021-04-26Re-Add Android.bp file am: 200df3137aJorge Moreira Broche
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1676155 Change-Id: Ie7820d86a7eda741b18c707629fd01035159a79a
2021-04-15Revert "Add Android.bp file" am: 66cbf7119a am: 46026d41e7 am: 3b0a6022a2Matthew Maurer
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1676804 Change-Id: Iec1bfd48fbc06a3549d071b814e29c9a1e694cdb
2021-04-15Add Android.bp file am: cb90b5b4d9 am: 7b3216110e am: b76846b988Jorge E. Moreira
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1676995 Change-Id: I1b21682d591a2744c5d762f087369bc7621a03ad
2021-04-15Merge remote-tracking branch 'aosp/upstream-main' am: 86868ea15c am: ↵Jorge E. Moreira
63e5d17388 am: 9f5725d400 Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1676994 Change-Id: I3e36e53abc7fb1903e6dc6c8fec0fdcb8ee7fcc3
2021-04-15Revert "Add Android.bp file" am: 66cbf7119a am: 46026d41e7Matthew Maurer
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1676804 Change-Id: Ifd626dc523ba3976080d0988d176be193fe7892d
2021-04-15Add Android.bp file am: cb90b5b4d9 am: 7b3216110eJorge E. Moreira
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1676995 Change-Id: I054c85d380709adaf113e9f6960dcc78d39961a8
2021-04-15Merge remote-tracking branch 'aosp/upstream-main' am: 86868ea15c am: 63e5d17388Jorge E. Moreira
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1676994 Change-Id: I5fc2a9bbabf59270f4303a81fa70194ee00e4c84
2021-04-15Revert "Add Android.bp file" am: 66cbf7119aMatthew Maurer
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1676804 Change-Id: Ia5df8fd7c6a3963d0d17923fcaf3627cc3207ce2
2021-04-15Add Android.bp file am: cb90b5b4d9Jorge E. Moreira
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1676995 Change-Id: I0a48925dca82642305f67fc02ed6869cca75d96c
2021-04-15Merge remote-tracking branch 'aosp/upstream-main' am: 86868ea15cJorge E. Moreira
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/vmm_vhost/+/1676994 Change-Id: I1896033874d9f7edc287a4dbf3d3294251eed104
2021-04-15Re-Add Android.bp fileJorge Moreira Broche
This time in a topic with the crosvm changes it depends on This reverts commit 66cbf7119a2e3023664171adbd528ac94243e2c5. Reason for revert: Merging along the changes it depends on Change-Id: Idafa87fcc683efece89fdd807117b12e111bb1ef
2021-04-15Revert "Add Android.bp file"Matthew Maurer
This reverts commit cb90b5b4d9a76b03c9774df919f0dc74c331dc51. Reason for revert: Breaking Build Change-Id: I24874cb134d4b2f46a0499f71674b324ab24649f
2021-04-15Add Android.bp fileJorge E. Moreira
Bug: 185157703 Test: build updated crosvm locally Change-Id: I34fbdc6b798ae4e1d56f6cd20f94b6c3634987e3
2021-04-15Merge remote-tracking branch 'aosp/upstream-main'Jorge E. Moreira
Bug: 185157703 Test: locally with following change Change-Id: Id39b5523128be41f44b551722ffcf325b58dbb58
2021-04-14Initial empty repositoryInna Palant
2021-03-16CHROMIUM: Ignore vsock test casesKeiichi Watanabe
Disable vsock test cases accessing /dev/vhost-vsock, which is unavailable in chroot. BUG=b:181227406 TEST=cargo test --all-features in chroot Change-Id: I99a80330597c7e281f73ed60aa798ec99f307e3a Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/rust-vmm/vhost/+/2759311 Tested-by: Keiichi Watanabe <keiichiw@chromium.org> Reviewed-by: Chirantan Ekbote <chirantan@chromium.org> Commit-Queue: Keiichi Watanabe <keiichiw@chromium.org>
2021-03-16CHROMIUM: Remove unused importKeiichi Watanabe
The unused import was introduced by the merge commit CL:2755328. While it's used in the upstream, it's not in Chrome OS. BUG=none TEST=build Change-Id: I2324162cbdf8a1ee0050a8a9e8a5fea16f10b5f2 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/rust-vmm/vhost/+/2759310 Tested-by: Keiichi Watanabe <keiichiw@chromium.org> Reviewed-by: Chirantan Ekbote <chirantan@chromium.org> Commit-Queue: Keiichi Watanabe <keiichiw@chromium.org>
2021-03-11Merge remote-tracking branch 'cros/upstream/master' into HEADDylan Reid
Change-Id: I81dfdf258d902b434e8a1b8339eb367cb7211153
2021-03-12Add PRESUBMIT.cfg for clippyKeiichi Watanabe
BUG=b:181227406 TEST=run `repo upload` Change-Id: I8f599f979758f2d0fb99fdc2e1c47c84bb49d48e Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/rust-vmm/vhost/+/2717907 Tested-by: Keiichi Watanabe <keiichiw@chromium.org> Auto-Submit: Keiichi Watanabe <keiichiw@chromium.org> Reviewed-by: Dylan Reid <dgreid@chromium.org> Reviewed-by: Chirantan Ekbote <chirantan@chromium.org> Commit-Queue: Chirantan Ekbote <chirantan@chromium.org>
2021-03-12Fix tempfile usage in vhost_user testsKeiichi Watanabe
Fix tests we forgot at crrev.com/c/2717529. BUG=b:181227406 TEST=cargo test --all-features Change-Id: I58ffcd8505e7f39891034c9b018fdf04acdde3ac Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/rust-vmm/vhost/+/2754348 Tested-by: Keiichi Watanabe <keiichiw@chromium.org> Auto-Submit: Keiichi Watanabe <keiichiw@chromium.org> Commit-Queue: Dylan Reid <dgreid@chromium.org> Reviewed-by: Dylan Reid <dgreid@chromium.org>
2021-03-11use sys_util and tempfile from crosvmDylan Reid
Adjust dependencies to use the crosvm-local crates. The tempfile interface is subtly different use the crosvm implementation to avoid a dependency on `rand`. Using a temporary directory avoids any chance of name collision with using rand to generate a string for a socket name. Some of the ScmSocket interfaces have changed and needed updating on both ends. BUG=b:181227406 TEST=cargo test Change-Id: Idee69f0c561642954ac1fa05c2951949e3b74fb5 Cq-Depend: chromium:2740533 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/rust-vmm/vhost/+/2717529 Tested-by: Dylan Reid <dgreid@chromium.org> Commit-Queue: Keiichi Watanabe <keiichiw@chromium.org> Reviewed-by: Keiichi Watanabe <keiichiw@chromium.org> Reviewed-by: Chirantan Ekbote <chirantan@chromium.org>
2021-03-10vhost_user: Add support for REM_MEM_REGSebastien Boeuf
Adding support for a new message REM_MEM_REG. This command request an existing memory region to be removed and unmapped from the vhost-user backend. It is designed for supporting memory hot-unplug, rather than using SET_MEM_TABLE, which is less efficient as it would remap all remaining regions. It is only available if the protocol feature VHOST_USER_PROTOCOL_F_CONFIGURE_MEM_SLOTS has been negotiated. Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2021-03-10vhost_user: Add support for ADD_MEM_REGSebastien Boeuf
Adding support for a new message ADD_MEM_REG. This command request a new region to be added and mapped by the vhost-user backend. It is designed for supporting memory hotplug, avoiding the limitation from SET_MEM_TABLE (supports only 8 regions). It is only available if the protocol feature VHOST_USER_PROTOCOL_F_CONFIGURE_MEM_SLOTS has been negotiated. Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2021-03-10vhost_user: Add support for GET_MAX_MEM_SLOTSSebastien Boeuf
Add the support for GET_MAX_MEM_SLOTS command. This requests the vhost-user backend to provide the maximum amount of memory slots that can be supported. It is only available if the protocol feature VHOST_USER_PROTOCOL_F_CONFIGURE_MEM_SLOTS has been negotiated. Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2021-03-10vhost_user: Update list of message typesSebastien Boeuf
The vhost-user specification moved forward by adding more message types. This commit extends the list according to the latest specification. Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2021-03-08Merge remote-tracking branch 'cros/upstream/master' into HEADDylan Reid
Change-Id: Ia2c11ff4e1f09d8dd74d1e0f19dbcefbb0c588fc
2021-03-07Allow using Path/PathBuf for initializationDylan Reid
Instead of taking a `&str` for the path of the sockets, take `AsRef<Path>`. This way users can pass `PathBuf`, `Path`, `String`, or `&str`. Signed-off-by: Dylan Reid <dgreid@chromium.org>
2021-03-05Merge "Merge remote-tracking branch 'cros/upstream/master' into HEAD" into mainCommit Bot
2021-03-04Add OWNERS fileKeiichi Watanabe
BUG=b:181227406 TEST=none Cq-Depend: chrome-internal:3639368, chrome-internal:3639230 Change-Id: I81a0bd403e16f941a9021a9402dfce80c0b3a817 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/rust-vmm/vhost/+/2719843 Reviewed-by: Chirantan Ekbote <chirantan@chromium.org> Tested-by: Woody Chow <woodychow@google.com> Commit-Queue: Keiichi Watanabe <keiichiw@chromium.org>
2021-03-04Merge remote-tracking branch 'cros/upstream/master' into HEADKeiichi Watanabe
BUG=none TEST=none Cq-Depend: chrome-internal:3639368, chrome-internal:3639230 Change-Id: Iaa169363f8e4ef933b4775009ad000fdc0ce0da5
2021-03-03Fix clippy erros and warningsKeiichi Watanabe
Make `cargo clippy --all-features --all-targets` pass. Signed-off-by: Keiichi Watanabe <keiichiw@chromium.org>
2021-03-01Prepare for publishing to crates.ioLiu Jiang
Prepare for publishing to crates.io, 1) update README.md 2) update Cargo.toml 3) set code owners It should be ready for publishing now. Signed-off-by: Liu Jiang <gerry@linux.alibaba.com>
2021-03-01vhost_user: add more negative unit test casesLiu Jiang
Add more negative unit test cases to improve code coverage. Also add two helper functions to simplify code. Signed-off-by: Liu Jiang <gerry@linux.alibaba.com>
2021-03-01vhost_user: add more unit test casesLiu Jiang
Add more unit test cases for vhost-user protocol. Signed-off-by: Liu Jiang <gerry@linux.alibaba.com>
2021-03-01vhost_user: use read_aligned() to access dataLiu Jiang
Use std::ptr::read_aligned() to safely access data buffer instead of directly accessing data struct in data buffer. Also enforce stricter message size validation. Signed-off-by: Liu Jiang <gerry@linux.alibaba.com>
2021-03-01vhost_user: add VhostUserSlaveReqHandlerMut traitLiu Jiang
Rename the original VhostUserSlaveReqHandler trait as VhostUserSlaveReqHandlerMut, and add another VhostUserSlaveReqHandler trait with interior mutability. This also help to simplify caller implementations. Signed-off-by: Liu Jiang <gerry@linux.alibaba.com>
2021-03-01vhost_user: fix a bug in SlaveReqHandlerLiu Jiang
An acknowlege reply message should be sent iif: 1) the VHOST_USER_PROTOCOL_F_REPLY_ACK feature is nogotiated, 2) the NEED_REPLY in header.flags is set. Also enforce stricter validation for message size. Signed-off-by: Liu Jiang <gerry@linux.alibaba.com>
2021-03-01vhost_user: refine connection implementationLiu Jiang
Refine connection implementation by: 1) using "payload: &[u8]" for send_message_with_payload() 2) enabling all unit test cases Signed-off-by: Liu Jiang <gerry@linux.alibaba.com>
2021-03-01vhost_user: fix bugs and refine message defintionLiu Jiang
Fix two bugs: 1) in VhostUserConfigFlags definition 2) in validating VhostUserConfig Refine vhost-user message definition by: 1) validate offset of VhostUserConfig 2) better documentation 3) more unit tests Signed-off-by: Liu Jiang <gerry@linux.alibaba.com>