From 3a0dbcd37fbfc74b528ab47c78d50080f301f61d Mon Sep 17 00:00:00 2001 From: Ross Burton Date: Thu, 31 Mar 2022 19:31:13 +0100 Subject: [PATCH] runfvp: strip all suffixes from the image when calculating .fvpconf name Until testimage tells the controller the basename of the image, make sure to strip all suffixes from the image name to get the base name, not just one. Machines such as corstone500 have images called .wic.nopt, so just stripping one isn't sufficient. Signed-off-by: Ross Burton Signed-off-by: Jon Mason --- meta-arm/lib/oeqa/controllers/fvp.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/meta-arm/lib/oeqa/controllers/fvp.py b/meta-arm/lib/oeqa/controllers/fvp.py index 7136a003..2913f782 100644 --- a/meta-arm/lib/oeqa/controllers/fvp.py +++ b/meta-arm/lib/oeqa/controllers/fvp.py @@ -16,7 +16,9 @@ class OEFVPTarget(oeqa.core.target.ssh.OESSHTarget): **kwargs): super().__init__(logger, target_ip, server_ip, timeout, user, port) image_dir = pathlib.Path(dir_image) - basename = pathlib.Path(rootfs).stem + # rootfs may have multiple extensions so we need to strip *all* suffixes + basename = pathlib.Path(rootfs) + basename = basename.name.replace("".join(basename.suffixes), "") self.fvpconf = image_dir / (basename + ".fvpconf") if not self.fvpconf.exists():