From 641094fcadd97f81f4124cfcbb447b93bb40188b Mon Sep 17 00:00:00 2001 From: Yohei Ueda Date: Mon, 1 Jul 2024 23:47:17 +0900 Subject: [PATCH 1/2] install: Add support for s390x architecture This patch enables support for s390x arch. Signed-off-by: Yohei Ueda --- lib/src/install/baseline.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/src/install/baseline.rs b/lib/src/install/baseline.rs index e8d4c0237..b9575c0a4 100644 --- a/lib/src/install/baseline.rs +++ b/lib/src/install/baseline.rs @@ -254,8 +254,6 @@ pub(crate) fn install_create_rootfs( "BIOS-BOOT", Some("21686148-6449-6E6F-744E-656564454649"), ); - } else if cfg!(target_arch = "aarch64") { - // Only UEFI here for now } else if cfg!(target_arch = "powerpc64") { // PowerPC-PReP-boot partno += 1; @@ -266,6 +264,8 @@ pub(crate) fn install_create_rootfs( crate::bootloader::PREPBOOT_LABEL, Some(crate::bootloader::PREPBOOT_GUID), ); + } else if cfg!(any(target_arch = "aarch64", target_arch = "s390x")) { + // No bootloader partition is necessary } else { anyhow::bail!("Unsupported architecture: {}", std::env::consts::ARCH); } From 9cf239b48faead8e643e3582434f90adce0ed43c Mon Sep 17 00:00:00 2001 From: Yohei Ueda Date: Thu, 6 Jun 2024 17:03:15 +0900 Subject: [PATCH 2/2] Remove s390s check Signed-off-by: Yohei Ueda --- lib/src/install.rs | 4 ---- 1 file changed, 4 deletions(-) diff --git a/lib/src/install.rs b/lib/src/install.rs index ac4e56e11..d23f8198d 100644 --- a/lib/src/install.rs +++ b/lib/src/install.rs @@ -1101,10 +1101,6 @@ async fn prepare_install( crate::cli::require_root()?; require_host_pidns()?; - if cfg!(target_arch = "s390x") { - anyhow::bail!("Installation is not supported on this architecture yet"); - } - let rootfs = cap_std::fs::Dir::open_ambient_dir("/", cap_std::ambient_authority()) .context("Opening /")?;