From 4b0f3782bd3832bf4141624a33a625b35ea109ae Mon Sep 17 00:00:00 2001 From: Alex Zenla Date: Sat, 14 Dec 2024 18:22:37 -0500 Subject: [PATCH] fix(xenclient): boot example should use unsupported platform on aarch64 --- crates/xen/xenclient/examples/boot.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/crates/xen/xenclient/examples/boot.rs b/crates/xen/xenclient/examples/boot.rs index 7a1e72a..b007bcb 100644 --- a/crates/xen/xenclient/examples/boot.rs +++ b/crates/xen/xenclient/examples/boot.rs @@ -24,10 +24,15 @@ async fn main() -> Result<()> { let initrd_path = args.get(2).expect("argument not specified"); let client = XenClient::new().await?; + #[cfg(target_arch = "x86_64")] + let runtime_platform = RuntimePlatformType::Pv; + #[cfg(not(target_arch = "x86_64"))] + let runtime_platform = RuntimePlatformType::Unsupported; + let mut config = DomainConfig::new(); config.platform(PlatformDomainConfig { uuid: Uuid::new_v4(), - platform: RuntimePlatformType::Pv, + platform: runtime_platform, kernel: PlatformKernelConfig { data: Arc::new(fs::read(&kernel_image_path).await?), format: KernelFormat::ElfCompressed,