misc: vmm: drop extern crate, use modern rust

This commit is part of a series of similar commits.

Signed-off-by: Philipp Schuster <philipp.schuster@cyberus-technology.de>
On-behalf-of: SAP philipp.schuster@sap.com
This commit is contained in:
Philipp Schuster
2025-09-05 09:21:43 +02:00
committed by Rob Bradford
parent 2157f1a1f2
commit 67fc9d990e
17 changed files with 35 additions and 12 deletions

View File

@@ -8,6 +8,7 @@ use std::path::{Path, PathBuf};
use std::str::FromStr;
use std::{fs, result};
use log::{debug, warn};
use net_util::MacAddr;
use serde::{Deserialize, Serialize};
use thiserror::Error;
@@ -807,13 +808,11 @@ impl PayloadConfig {
(Some(_firmware), Some(_kernel)) => Err(PayloadConfigError::FirmwarePlusOtherPayloads),
(Some(_firmware), None) => {
if self.cmdline.is_some() {
log::warn!("Ignoring cmdline parameter as firmware is provided as the payload");
warn!("Ignoring cmdline parameter as firmware is provided as the payload");
self.cmdline = None;
}
if self.initramfs.is_some() {
log::warn!(
"Ignoring initramfs parameter as firmware is provided as the payload"
);
warn!("Ignoring initramfs parameter as firmware is provided as the payload");
self.initramfs = None;
}
Ok(())