Commit Graph

711 Commits

Author SHA1 Message Date
dependabot[bot]
1ff8de46bf build(deps): bump rust-vmm-ci from 9dfe5b2 to 7c1057e
Bumps [rust-vmm-ci](https://github.com/rust-vmm/rust-vmm-ci) from `9dfe5b2` to `7c1057e`.
- [Commits](9dfe5b267c...7c1057e9bc)

---
updated-dependencies:
- dependency-name: rust-vmm-ci
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-19 15:31:05 +02:00
dependabot[bot]
1b9dca824a build(deps): bump ryu from 1.0.14 to 1.0.15
Bumps [ryu](https://github.com/dtolnay/ryu) from 1.0.14 to 1.0.15.
- [Release notes](https://github.com/dtolnay/ryu/releases)
- [Commits](https://github.com/dtolnay/ryu/compare/1.0.14...1.0.15)

---
updated-dependencies:
- dependency-name: ryu
  dependency-type: indirect
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-18 08:37:10 -06:00
Erik Schilling
3cab62ea02 rng: also pretty print configuration errors
If the parsed commandline options cannot be converted into a
`VuRngConfig` we would only get a .unwrap() error message.

Chain this before the check of the daemon launch.

Suggested-by: Manos Pitsidianakis <manos.pitsidianakis@linaro.org>
Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
2023-07-11 13:30:01 +05:30
Erik Schilling
a9de87a1ce tree-wide: bubble up errors from daemon threads
There was a mix of just unwrapping (panicking) and catching and logging
errors. The unwrapping is not allowing for particulary pretty error
handling, so let's bubble the errors up by not crashing the thread,
but by just returning a Result<()> than is received when joining the
threads.

Not all .unwrap() uses were translated since a followup PR (#389) will
rework that code anyway (and get rid of the .unwrap() in the process).

Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
2023-07-11 13:30:01 +05:30
Erik Schilling
2b1b3644da tree-wide: drop the Eq trait from Error
I plan to add some wrapper errors around vhost errors. These end up
nesting other errors all the way to std::error::Error, which has no
Eq trait.

The implementations were only used for comparisions in tests. While
there is a assert_matches!() in nightly [1] it seems unlikely that
further testing lib additions are getting standarized soon (or ever).

One could use assert!(matches!()), but that would worsen the error
messages for test failures. Hence, during review [2] we agreed on
introducing the assert_matches crate. It got no dependencies and
allows us to keep the good error messages while not needing to depend
on nightly.

Signed-off-by: Erik Schilling <erik.schilling@linaro.org>

[1] https://doc.rust-lang.org/std/assert_matches/macro.assert_matches.html
[2] https://github.com/rust-vmm/vhost-device/pull/388#discussion_r1257831748
2023-07-11 13:30:01 +05:30
Erik Schilling
9332a933f8 tree-wide: actually pretty-print error messages
We setup pretty-printing with all the thiserror-based Error structs, but
then only bubble the error up to the main, where it just gets printed
with the `Debug` trait.

This "catches" the error in the main and performs pretty printing using
the `Display` trait.

Before:

    Error: FailedCreatingListener(SocketError(Os { code: 98, kind:
        AddrInUse, message: "Address already in use" }))

After:

    [2023-07-06T17:20:47Z ERROR vhost_device_scsi] Failed creating
        listener: socket error: Address already in use (os error 98)

vhost-device-vsock is a bit special since it does not let error messages
bubble up to the main. It also does .unwrap() in most places, but it
_does_  pretty print errors during the main request handling part.

Had to slightly adjust the coverage since we have no tests for the main
functions.

Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
2023-07-11 13:30:01 +05:30
Manos Pitsidianakis
8a1deef49a vsock: use tempfile in tests
Tests were run in a series before the previous commit because of a
testing failure (#232), and masked a bug. This is not necessary anymore
since the bug was fixed in the previous commit.

Instead of reverting to running the tests without the #[serial]
attribute, make every test self-contained by using unique temp
directories in each test run.

Test files that refer to sockets need to be unique because they risk
sharing filenames with other tests after refactoring. Since these tests
create/use/free resources, they should take care not to litter /tmp/ and
not share any file with other tests.

This commit uses a unique temp dir as location of test run files instead
of `/tmp/`. It adds a new dev-dependency, `tempfile`.

Signed-off-by: Manos Pitsidianakis <manos.pitsidianakis@linaro.org>
2023-07-11 13:01:41 +05:30
Manos Pitsidianakis
7f809eeab8 vsock: fix use-after-close RawFd unsafe {} use
Using a raw file descriptor in `stream_map` caused two `UnixStream`
instances have a shared single reference to the underlying stream
socket. Use UnixStream::try_clone instead which duplicates the file
descriptor while still referring to the same stream.

Fixes #232

Signed-off-by: Manos Pitsidianakis <manos.pitsidianakis@linaro.org>
2023-07-11 13:01:41 +05:30
Ramyak Mehra
e24d3e52fc vsock: reduce credit update messages sent to guest
Earlier we were sending credit update messages to guest
everytime data was read, now we send it only if the available
space is less than 1/4th of the tx buffer size.

benchmarks:

host->guest[Gbps]

before   1.45
after    1.51

guest->host[Gbps]

before   5.68
after    6.07

Note: I did 3 runs of 10 secs and took average of all,
they are relative results.

Fixes #317

Signed-off-by: Ramyak Mehra <rmehra_be19@thapar.edu>

[SG: fixed S-o-b and small things in the commit description]

Signed-off-by: Stefano Garzarella <sgarzare@redhat.com>
2023-07-11 12:29:18 +05:30
dependabot[bot]
0b7f536998 build(deps): bump regex from 1.9.0 to 1.9.1
Bumps [regex](https://github.com/rust-lang/regex) from 1.9.0 to 1.9.1.
- [Release notes](https://github.com/rust-lang/regex/releases)
- [Changelog](https://github.com/rust-lang/regex/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/regex/compare/1.9.0...1.9.1)

---
updated-dependencies:
- dependency-name: regex
  dependency-type: indirect
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-10 11:16:18 +05:30
dependabot[bot]
0d08c5a334 build(deps): bump serde from 1.0.166 to 1.0.168
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.166 to 1.0.168.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.166...v1.0.168)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-10 11:16:08 +05:30
dependabot[bot]
83f9e61c09 build(deps): bump ucd-trie from 0.1.5 to 0.1.6
Bumps [ucd-trie](https://github.com/BurntSushi/ucd-generate) from 0.1.5 to 0.1.6.
- [Commits](https://github.com/BurntSushi/ucd-generate/compare/ucd-util-0.1.5...ucd-trie-0.1.6)

---
updated-dependencies:
- dependency-name: ucd-trie
  dependency-type: indirect
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-10 11:15:56 +05:30
Erik Schilling
7a371edc3e Add CHANGELOG.md to all crates
In order to prepare for an initial release of the crates, this adds a
CHANGELOG.md for tracking changes in the future releases.

The template was copied from the vhost crate [1].

Signed-off-by: Erik Schilling <erik.schilling@linaro.org>

[1] 900b9a5c41/crates/vhost/CHANGELOG.md
2023-07-07 22:06:45 +05:30
Viresh Kumar
055f27f4ab Run Cargo update
Cargo audit gives an error currently:

Crate:         hermit-abi
Version:       0.3.1
Warning:       yanked

Fix it by updating the dependencies forcefully.

Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
2023-07-06 16:37:36 +05:30
Viresh Kumar
462a621485 Add support for Xen builds
Various rust-vmm dependencies now support Xen platforms under a new
feature `xen`. Add the same here for all the crates.

Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
2023-07-06 16:37:36 +05:30
Erik Schilling
0bb783601e Symlink license files into crate folders
Once we publish crates to crates.io, only the crate subfolder is
uploaded. Symlink the license files in in order to include them during
packaging.

`cargo package` will replace the symlinks with the actual files during
packaging, so crates.io will include the license file.

Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
2023-07-04 14:56:52 +05:30
Erik Schilling
827921a07f build(deps): updated epoll to 4.3.3
4.3.2 got yanked [1]. No reason was given, but it looks like a build fix
for a bitflags updated [2].

Signed-off-by: Erik Schilling <erik.schilling@linaro.org>

[1] https://crates.io/crates/epoll/4.3.2
[2] d3a2304d38
2023-07-04 13:24:16 +05:30
Erik Schilling
2ebba0910c build(deps): switch to released virtio-bindings
This version brings the SCSI bindings and allows us to drop the git
dependency (which was complicating the packaging situation).

Thanks-to: Jiang Liu <gerry@linux.alibaba.com>
Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
2023-07-04 13:24:16 +05:30
Erik Schilling
147c566ec0 build(deps): bump rustix to prevent build error
Before bumping, the error was:

    error[E0554]: `#![feature]` may not be used on the stable release
                  channel
       --> [...]/rustix-0.37.20/src/lib.rs:101:26
        |
    101 | #![cfg_attr(rustc_attrs, feature(rustc_attrs))]
        |                          ^^^^^^^^^^^^^^^^^^^^

    error[E0554]: `#![feature]` may not be used on the stable release
                  channel
       --> [...]/rustix-0.37.20/src/lib.rs:117:5
        |
    117 |     feature(core_intrinsics)
        |     ^^^^^^^^^^^^^^^^^^^^^^^^

    error[E0554]: `#![feature]` may not be used on the stable release
                  channel
       --> [...]/rustix-0.37.20/src/lib.rs:117:13
        |
    117 |     feature(core_intrinsics)
        |             ^^^^^^^^^^^^^^^

    For more information about this error, try `rustc --explain E0554`.
    error: could not compile `rustix` (lib) due to 3 previous errors

Bumped using: cargo update -p rustix --aggressive

Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
2023-07-04 13:24:16 +05:30
Viresh Kumar
ad40227827 vsock: Fix build error with epoll-4.3.2
With epoll-4.3.2, bitflags moves to 2.3.3 from 1.3.2 and breaks the
build with following error:

error[E0369]: binary operation `!=` cannot be applied to type `Events`

Fix those by using the .bits() functions.

Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
2023-07-03 13:37:19 +05:30
dependabot[bot]
41f4cb1ab2 build(deps): bump epoll from 4.3.1 to 4.3.2
Bumps [epoll](https://github.com/nathansizemore/epoll) from 4.3.1 to 4.3.2.
- [Release notes](https://github.com/nathansizemore/epoll/releases)
- [Commits](https://github.com/nathansizemore/epoll/commits)

---
updated-dependencies:
- dependency-name: epoll
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-03 13:37:19 +05:30
Priyansh Rathi
4346438bff vsock: Compare packet src_cid with the configured guest CID
Cross-check the packet `src_cid` with the CID configured for the guest.
This will forbid a VM from impersonating another.

Signed-off-by: Priyansh Rathi <techiepriyansh@gmail.com>
2023-07-03 11:33:13 +05:30
Priyansh Rathi
d6b953e958 vsock: Implement sibling VM communication
Adds support for communication between sibling VMs that use the
vhost-user-vsock devices from the same vhost-user-vsock application.

Tested with nc-vsock patched to set `.svm_flags = VMADDR_FLAG_TO_HOST`:

host$ vhost-user-vsock \
      --vm guest-cid=3,uds-path=/tmp/vm3.vsock,socket=/tmp/vhost3.socket \
      --vm guest-cid=4,uds-path=/tmp/vm4.vsock,socket=/tmp/vhost4.socket

vm_cid3$ nc-vsock -l 1234
vm_cid4$ nc-vsock 3 1234

Signed-off-by: Priyansh Rathi <techiepriyansh@gmail.com>
2023-07-03 11:33:13 +05:30
Priyansh Rathi
015ccff9fc vsock: Handle the single VM case same as multiple VMs
In future, we could add the ability to change the configuration at runtime
and allow new guests to be added even without having to restart the
daemon. So it is reasonable to not differentiate between the single and
multiple VM cases, even with only one guest.

Signed-off-by: Priyansh Rathi <techiepriyansh@gmail.com>
2023-07-03 11:33:13 +05:30
Erik Schilling
f0b0eee465 gpio: update instructions for setting up libgpiod
Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
2023-07-03 11:26:22 +05:30
dependabot[bot]
6d548cd7c8 build(deps): bump itoa from 1.0.6 to 1.0.7
Bumps [itoa](https://github.com/dtolnay/itoa) from 1.0.6 to 1.0.7.
- [Release notes](https://github.com/dtolnay/itoa/releases)
- [Commits](https://github.com/dtolnay/itoa/compare/1.0.6...1.0.7)

---
updated-dependencies:
- dependency-name: itoa
  dependency-type: indirect
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-03 10:29:39 +05:30
dependabot[bot]
8ed0c0e58a build(deps): bump num_cpus from 1.15.0 to 1.16.0
Bumps [num_cpus](https://github.com/seanmonstar/num_cpus) from 1.15.0 to 1.16.0.
- [Release notes](https://github.com/seanmonstar/num_cpus/releases)
- [Changelog](https://github.com/seanmonstar/num_cpus/blob/master/CHANGELOG.md)
- [Commits](https://github.com/seanmonstar/num_cpus/compare/v1.15.0...v1.16.0)

---
updated-dependencies:
- dependency-name: num_cpus
  dependency-type: indirect
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-03 10:29:30 +05:30
dependabot[bot]
1e97f7c0dd build(deps): bump rust-vmm-ci from 7e9af57 to 9dfe5b2
Bumps [rust-vmm-ci](https://github.com/rust-vmm/rust-vmm-ci) from `7e9af57` to `9dfe5b2`.
- [Commits](7e9af57588...9dfe5b267c)

---
updated-dependencies:
- dependency-name: rust-vmm-ci
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-03 10:20:59 +05:30
dependabot[bot]
45e6c6d5aa build(deps): bump serde_yaml from 0.9.21 to 0.9.22
Bumps [serde_yaml](https://github.com/dtolnay/serde-yaml) from 0.9.21 to 0.9.22.
- [Release notes](https://github.com/dtolnay/serde-yaml/releases)
- [Commits](https://github.com/dtolnay/serde-yaml/compare/0.9.21...0.9.22)

---
updated-dependencies:
- dependency-name: serde_yaml
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-26 11:23:36 +05:30
dependabot[bot]
a893caa0d6 build(deps): bump clap from 4.3.5 to 4.3.8
Bumps [clap](https://github.com/clap-rs/clap) from 4.3.5 to 4.3.8.
- [Release notes](https://github.com/clap-rs/clap/releases)
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md)
- [Commits](https://github.com/clap-rs/clap/compare/v4.3.5...v4.3.8)

---
updated-dependencies:
- dependency-name: clap
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-26 11:22:46 +05:30
dependabot[bot]
f0be54bcfe build(deps): bump toml_edit from 0.19.10 to 0.19.11
Bumps [toml_edit](https://github.com/toml-rs/toml) from 0.19.10 to 0.19.11.
- [Commits](https://github.com/toml-rs/toml/compare/v0.19.10...v0.19.11)

---
updated-dependencies:
- dependency-name: toml_edit
  dependency-type: indirect
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-26 11:22:28 +05:30
Priyansh Rathi
83bc481e76 Run cargo update
Manually update all cargo dependencies.

Signed-off-by: Priyansh Rathi <techiepriyansh@gmail.com>
2023-06-23 19:49:35 +05:30
dependabot[bot]
f260959cdf build(deps): bump getrandom from 0.2.9 to 0.2.10
Bumps [getrandom](https://github.com/rust-random/getrandom) from 0.2.9 to 0.2.10.
- [Changelog](https://github.com/rust-random/getrandom/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-random/getrandom/compare/v0.2.9...v0.2.10)

---
updated-dependencies:
- dependency-name: getrandom
  dependency-type: indirect
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-19 10:46:42 +05:30
dependabot[bot]
fa4fbc4d1e build(deps): bump sha2 from 0.10.6 to 0.10.7
Bumps [sha2](https://github.com/RustCrypto/hashes) from 0.10.6 to 0.10.7.
- [Commits](https://github.com/RustCrypto/hashes/compare/sha2-v0.10.6...sha2-v0.10.7)

---
updated-dependencies:
- dependency-name: sha2
  dependency-type: indirect
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-19 10:46:35 +05:30
dependabot[bot]
13b9e2ceaa build(deps): bump winnow from 0.4.6 to 0.4.7
Bumps [winnow](https://github.com/winnow-rs/winnow) from 0.4.6 to 0.4.7.
- [Changelog](https://github.com/winnow-rs/winnow/blob/main/CHANGELOG.md)
- [Commits](https://github.com/winnow-rs/winnow/compare/v0.4.6...v0.4.7)

---
updated-dependencies:
- dependency-name: winnow
  dependency-type: indirect
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-19 10:46:26 +05:30
dependabot[bot]
1ca98aadea build(deps): bump rust-vmm-ci from 285971e to 7e9af57
Bumps [rust-vmm-ci](https://github.com/rust-vmm/rust-vmm-ci) from `285971e` to `7e9af57`.
- [Commits](285971e8c7...7e9af57588)

---
updated-dependencies:
- dependency-name: rust-vmm-ci
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-19 10:46:10 +05:30
Erik Schilling
8ac1ce45c1 gpio: use libgpiod from crates.io
This simplifies the packaging and allows using existing tooling to
manage further updates.

The lock file was updated with:

    cargo update -p libgpiod --aggressive

Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
2023-06-14 20:07:27 +05:30
dependabot[bot]
93bdb73af2 build(deps): bump serial_test from 1.0.0 to 2.0.0
Bumps [serial_test](https://github.com/palfrey/serial_test) from 1.0.0 to 2.0.0.
- [Release notes](https://github.com/palfrey/serial_test/releases)
- [Commits](https://github.com/palfrey/serial_test/compare/v1.0.0...v2.0.0)

---
updated-dependencies:
- dependency-name: serial_test
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-14 12:55:57 +05:30
dependabot[bot]
393b268921 build(deps): bump rust-vmm-ci from 8627b37 to 285971e
Bumps [rust-vmm-ci](https://github.com/rust-vmm/rust-vmm-ci) from `8627b37` to `285971e`.
- [Commits](8627b3766b...285971e8c7)

---
updated-dependencies:
- dependency-name: rust-vmm-ci
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-14 12:55:47 +05:30
dependabot[bot]
7ad018653c build(deps): bump lock_api from 0.4.9 to 0.4.10
Bumps [lock_api](https://github.com/Amanieu/parking_lot) from 0.4.9 to 0.4.10.
- [Changelog](https://github.com/Amanieu/parking_lot/blob/master/CHANGELOG.md)
- [Commits](https://github.com/Amanieu/parking_lot/compare/lock_api-0.4.9...lock_api-0.4.10)

---
updated-dependencies:
- dependency-name: lock_api
  dependency-type: indirect
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-14 12:55:32 +05:30
dependabot[bot]
10133d65a2 build(deps): bump parking_lot_core from 0.9.7 to 0.9.8
Bumps [parking_lot_core](https://github.com/Amanieu/parking_lot) from 0.9.7 to 0.9.8.
- [Changelog](https://github.com/Amanieu/parking_lot/blob/master/CHANGELOG.md)
- [Commits](https://github.com/Amanieu/parking_lot/compare/core-0.9.7...core-0.9.8)

---
updated-dependencies:
- dependency-name: parking_lot_core
  dependency-type: indirect
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-14 12:55:20 +05:30
Priyansh Rathi
a4aabb15e1 vsock: Add support for multiple guests
Adds support for instantiating multiple `VhostUserVsockBackend`s parallely
to handle multiple guests. Extends the CLI interface to accept the config
for multiple VMs in addition to the yaml config file with the `--vm`
argument as follows:

vhost-user-vsock \
--vm guest_cid=3,socket=/tmp/vhost3.socket,uds_path=/tmp/vm3.vsock \
--vm guest_cid=4,socket=/tmp/vhost4.socket,uds_path=/tmp/vm4.vsock

Signed-off-by: Priyansh Rathi <techiepriyansh@gmail.com>
2023-06-08 13:09:16 +05:30
Erik Schilling
f50e7147df scsi: mention out-of-tree fuzzing infrastructure
Polishing this up for inclusion is currently not high on the priority
list, but we can at least link it.

Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
2023-06-05 14:55:32 +05:30
Erik Schilling
8bb862d415 scsi: add some helper scripts for testing
This provides some tooling for running blktests. The README.md contains
documentation about the architecture.

I am seeing some race-conditions that sometimes lead to boot
freezes [1], so this is not really ready for automatic evaluation during
a CI pipeline.

[1] https://linaro.atlassian.net/browse/ORKO-37

Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
Link: https://linaro.atlassian.net/browse/ORKO-17
2023-06-05 14:55:32 +05:30
Erik Schilling
a6382dd937 scsi: add support for SYNCHRONIZE CACHE(10)
While the command also allows syncing individual regions of a LUN, we
do not support that here and simply sync the entire file.

Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
2023-06-05 14:55:32 +05:30
Erik Schilling
07b103b4d6 scsi: add support for WRITE SAME(16)
WRITE SAME allows writing a block for a repeated number of times.

Mostly, it can also be used to deallocate parts of the block device
(the fstrim functionality uses this). We do not support that aspect
yet. Instead, we will just stupidly repeat the pattern as many times
as we are told.

A future, smarter implementation could just punch a hole into the
backend instead of filling it with zeros.

Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
2023-06-05 14:55:32 +05:30
Erik Schilling
3adff11c94 scsi: add support for WRITE(10)
This adds write support. Being very similar to READ(10) in structure,
much of the code is very similar.

Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
2023-06-05 14:55:32 +05:30
Erik Schilling
4c8a2bc3ac scsi: Advertise support for CONFIG
The config that we send is based on the current QEMU defaults
(as of 60ca584b8af0de525656f959991a440f8c191f12).

This allows testing using Alex Bennee's vhost-user-generic series and
will be required for hypervisors that do not come with the stubs that
QEMU has (eg: Xen).

Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
Link: https://lore.kernel.org/all/20230414160433.2096866-1-alex.bennee@linaro.org/
2023-06-05 14:55:32 +05:30
Gaelan Steele
ad82d45928 scsi: Add documentation
Co-developed-by: Erik Schilling <erik.schilling@linaro.org>
Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
Signed-off-by: Gaelan Steele <gbs@canishe.com>
2023-06-05 14:55:32 +05:30
Erik Schilling
c07b42b662 scsi: Add tests for daemon and virtio code
Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
2023-06-05 14:55:32 +05:30