This commit is contained in:
Alex Zenla
2024-05-13 01:23:14 -07:00
parent 7fb2732f4b
commit 444fb4e4b3
3 changed files with 14 additions and 9 deletions

View File

@ -139,7 +139,9 @@ impl GuestLauncher {
None
};
let cmdline_options = [
if request.debug { "debug" } else { "quiet" },
"earlycon=xen,keep",
"earlyprintk=xen,keep",
"debug",
"elevator=noop",
];
let cmdline = cmdline_options.join(" ");

View File

@ -7,7 +7,7 @@ use log::error;
use loopdev::LoopControl;
use tokio::sync::Semaphore;
use uuid::Uuid;
use xenclient::{x86pv::X86PvPlatform, XenClient};
use xenclient::{x86pvh::X86PvhPlatform, XenClient};
use xenstore::{XsdClient, XsdInterface};
use self::{
@ -21,6 +21,8 @@ pub mod channel;
pub mod ip;
pub mod launch;
type RuntimePlatform = X86PvhPlatform;
pub struct GuestLoopInfo {
pub device: String,
pub file: String,
@ -49,13 +51,13 @@ pub struct GuestInfo {
#[derive(Clone)]
pub struct RuntimeContext {
pub autoloop: AutoLoop,
pub xen: XenClient<X86PvPlatform>,
pub xen: XenClient<RuntimePlatform>,
pub ipvendor: IpVendor,
}
impl RuntimeContext {
pub async fn new(host_uuid: Uuid) -> Result<Self> {
let xen = XenClient::open(0, X86PvPlatform::new()).await?;
let xen = XenClient::open(0, RuntimePlatform::new()).await?;
let ipv4_network = Ipv4Network::new(Ipv4Addr::new(10, 75, 80, 0), 24)?;
let ipv6_network = Ipv6Network::from_str("fdd4:1476:6c7e::/48")?;
let ipvend =