vm-virtio, virtio-devices: Address Rust 1.51.0 clippy issue (upper_case_acronyms)

error: name `TYPE_UNKNOWN` contains a capitalized acronym
  --> vm-virtio/src/lib.rs:48:5
   |
48 |     TYPE_UNKNOWN = 0xFF,
   |     ^^^^^^^^^^^^ help: consider making the acronym lowercase, except the initial letter: `Type_Unknown`
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#upper_case_acronyms

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
This commit is contained in:
Rob Bradford
2021-03-25 16:54:09 +00:00
parent 261c039831
commit aa34d545f6
16 changed files with 66 additions and 69 deletions
+2 -2
View File
@@ -384,11 +384,11 @@ impl VirtioPciDevice {
// to firmware without requiring excessive identity mapping.
let mut use_64bit_bar = true;
let (class, subclass) = match VirtioDeviceType::from(locked_device.device_type()) {
VirtioDeviceType::TYPE_NET => (
VirtioDeviceType::Net => (
PciClassCode::NetworkController,
&PciNetworkControllerSubclass::EthernetController as &dyn PciSubclass,
),
VirtioDeviceType::TYPE_BLOCK => {
VirtioDeviceType::Block => {
use_64bit_bar = false;
(
PciClassCode::MassStorage,