crosvm/devices
Alexandre Courbot 2c171901ee virtio: vhost: user: remove use of serde's flatten in VhostUserParams
The use of flatten is problematic as it introduces type ambiguity if we
need to parse a string from either the embedding or the embedded
structure. For this reason we are now discouraging its use.

Replace the only place where it was used (the VhostUserParams struct)
with a manual parser that requires the 'vhost' parameter to come first.
This is a bit more constraining but at the same time is probably clearer
than having it in the middle of device-parameters anyway.

BUG=b:217480043
BUG=b:241300017
TEST=cargo test -p devices vhost_user_params

Change-Id: I35847196fa6dc4858112ffe1e2883d64c2fae514
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/3889329
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Commit-Queue: Alexandre Courbot <acourbot@chromium.org>
2022-09-15 02:07:56 +00:00
..
src virtio: vhost: user: remove use of serde's flatten in VhostUserParams 2022-09-15 02:07:56 +00:00
Cargo.toml devices: cmos: use chrono crate to get time 2022-08-03 18:19:31 +00:00