mirror of
https://chromium.googlesource.com/crosvm/crosvm
synced 2025-02-05 10:10:41 +00:00
update Cargo.lock and conditional compile certain modules
This change is to cleanup some dead_code warnings that appear if certain features aren't enabled. This also updates the Cargo.lock when changed due to zeroize being added to libchromeos-rs. TEST=cargo check --all-features BUG=None Change-Id: I5347b584a7426dc37f3933b1e907b23a71145749 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/2753128 Reviewed-by: Allen Webb <allenwebb@google.com> Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org> Reviewed-by: Daniel Verkamp <dverkamp@chromium.org> Tested-by: kokoro <noreply+kokoro@google.com> Tested-by: Zach Reizner <zachr@chromium.org> Commit-Queue: Zach Reizner <zachr@chromium.org>
This commit is contained in:
parent
2f5d4b64a3
commit
fdf87d8827
5 changed files with 40 additions and 2 deletions
34
Cargo.lock
generated
34
Cargo.lock
generated
|
@ -564,6 +564,7 @@ dependencies = [
|
|||
"log",
|
||||
"protobuf",
|
||||
"thiserror",
|
||||
"zeroize",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
|
@ -919,6 +920,18 @@ dependencies = [
|
|||
name = "sync"
|
||||
version = "0.1.0"
|
||||
|
||||
[[package]]
|
||||
name = "synstructure"
|
||||
version = "0.12.4"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "b834f2d66f734cb897113e34aaff2f1ab4719ca946f9a7358dba8f8064148701"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
"syn",
|
||||
"unicode-xid",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "sys_util"
|
||||
version = "0.1.0"
|
||||
|
@ -1094,3 +1107,24 @@ dependencies = [
|
|||
"vm_control",
|
||||
"vm_memory",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "zeroize"
|
||||
version = "1.2.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "81a974bcdd357f0dca4d41677db03436324d45a4c9ed2d0b873a5a360ce41c36"
|
||||
dependencies = [
|
||||
"zeroize_derive",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "zeroize_derive"
|
||||
version = "1.0.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "c3f369ddb18862aba61aa49bf31e74d29f0f162dec753063200e1dc084345d16"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
"syn",
|
||||
"synstructure",
|
||||
]
|
||||
|
|
|
@ -970,8 +970,10 @@ impl Gpu {
|
|||
let num_capsets = match self.rutabaga_component {
|
||||
RutabagaComponentType::Rutabaga2D => 0,
|
||||
_ => {
|
||||
let mut num_capsets = 0;
|
||||
|
||||
// Cross-domain (like virtio_wl with llvmpipe) is always available.
|
||||
let mut num_capsets = 1;
|
||||
num_capsets += 1;
|
||||
|
||||
// Three capsets for virgl_renderer
|
||||
#[cfg(feature = "virgl_renderer")]
|
||||
|
|
|
@ -15,6 +15,7 @@ mod gpu_display_stub;
|
|||
mod gpu_display_wl;
|
||||
#[cfg(feature = "x")]
|
||||
mod gpu_display_x;
|
||||
#[cfg(feature = "x")]
|
||||
mod keycode_converter;
|
||||
|
||||
pub use event_device::{EventDevice, EventDeviceKind};
|
||||
|
|
|
@ -10,6 +10,7 @@ mod generated;
|
|||
mod gfxstream;
|
||||
#[macro_use]
|
||||
mod macros;
|
||||
#[cfg(any(feature = "gfxstream", feature = "virgl_renderer"))]
|
||||
mod renderer_utils;
|
||||
mod rutabaga_2d;
|
||||
mod rutabaga_core;
|
||||
|
|
|
@ -30,7 +30,7 @@ pub struct VirglBox {
|
|||
* -o vsnprintf.rs
|
||||
*/
|
||||
|
||||
#[allow(dead_code, non_snake_case, non_camel_case_types)]
|
||||
#[allow(non_snake_case, non_camel_case_types)]
|
||||
#[cfg(any(target_arch = "x86", target_arch = "x86_64"))]
|
||||
extern "C" {
|
||||
pub fn vsnprintf(
|
||||
|
|
Loading…
Reference in a new issue