summaryrefslogtreecommitdiffstats
path: root/recipes-extended/images/xen-image-minimal.bb
Commit message (Collapse)AuthorAgeFilesLines
* xen-image-minimal: allow non-zero return codesBruce Ashfield2024-11-151-1/+1
| | | | Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xen: enable networking and guest image bundlingBruce Ashfield2024-11-151-8/+173
| | | | | | | | | | | | | | | | | | The xen host image reference needed signifant work to be functional for launching and testing Xen domu guests. Here we add additional tools to the host image, and allow it to automatically bundle guests if the configuration is enabled. We also add systemd networking configuration to create a xenbr0 which offeres connectivity to the entire reference system. See the recipes and the README for details on testing and bundling. Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xen-image-minimal: Add missing dependency causing intermittent failuresRichard Purdie2024-08-011-0/+1
| | | | | | | | | | | | | | | "bitbake xen-image-minimal -c do_image_wic" fails with: | ERROR: _exec_cmd: install -m 0644 tmp/deploy/images/qemux86-64/xen-qemux86-64.gz tmp/work/qemux86_64-poky-linux/xen-image-minimal/1.0/tmp-wic/hdd/boot/xen.gz returned '1' instead of 0 | output: install: cannot stat 'tmp/deploy/images/qemux86-64/xen-qemux86-64.gz': No such file or directory | | WARNING: exit code 1 from a shell command. ERROR: Task (/media/build/poky/meta-virtualization/recipes-extended/images/xen-image-minimal.bb:do_image_wic) failed with exit code '1' Add the missing dependency to avoid this. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xen: use bzImage for boot (instead of vmlinux)Bruce Ashfield2024-03-211-0/+7
| | | | | | | | | | | | | | | | Testing with the latest oe-core was unable to boot and only syslinux was running. It appears that the desired kernel is not on the /boot partition, and hence the system can't continue. bzImage is installed and available, so we switch to that. We also ensure that both kernel-vmlinux and kernel-image are installed to the rootfs so we can have choices in the future. Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xen-image-minimal: reduce the x86 wic build dependenciesChristopher Clark2022-07-201-0/+2
| | | | | | | | | | | | | | | | | The Xen image recipe provides a default WKS_FILE for x86 builds to enable booting the image either in qemu or directly on hardware. Add settings for WKS_FILE_DEFAULT_DEPENDS that specify the wic image build dependencies, which are lower than the defaults used without it. This change reduces the amount of build resources required for CI of this image and images that are derived from it. Since WKS_FILE is specified separately for x86-64 and qemux86-64 overrides, do the same for WKS_FILE_DEFAULT_DEPENDS, even though the dependencies for the two separate WKS_FILEs are currently the same. Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xen: Fix class inherit in xen-imageBertrand Marquis2022-05-181-1/+1
| | | | | | | | | | | | | | Remove inherit of qemuboot classes when not build for qemu in xen-image-minimal. When reverted the handling for only adding inherited classes for qemu was kept but the line always inheriting them was kept to. This patch is fixing that so that qemuboot classes are now only added when the image is built for qemu. This fixes commit 27e5ade0abc2660226389b8b62ef07d85f4b8758 Signed-off-by: Bertrand Marquis <bertrand.marquis@arm.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* Revert "qemuboot, xen-image-minimal: enable runqemu for qemuarm Xen images"Bruce Ashfield2022-05-091-2/+2
| | | | | | This reverts commit 1c746a976830ebaf85c7c8c25612bea349b0a7c5. Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xen images, qemuboot: configure xenbr0 bridge for runqemu, testimageChristopher Clark2022-05-091-0/+2
| | | | | | | | | | | | | | Networking for Xen guest virtual machines is commonly configured via bridging in the host system between a physical interface and the guest virtual interfaces. To make it easier to test networking and use testimage with Xen guest virtual machines, extend the bbclass that provides network configuration for qemu machines for the Xen images to configure a Xen bridge and put eth0 onto it when QB_XEN_HOST_BRIDGE is set. Signed-off-by: Christopher Clark <christopher.clark@starlab.io> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* qemuboot, xen-image-minimal: enable runqemu for qemuarm Xen imagesChristopher Clark2022-05-091-1/+5
| | | | | | | | | | | | | | | | | | | | | The Xen hypervisor built for Arm 32-bit targets can be launched with runqemu by providing a u-boot script and configuration for Qemu, which enables interactive testing of Xen images. Add qemuboot-xen-u-boot.bbclass to add a new bitbake task for generating the u-boot script. Since this increases the number of qemuboot-specific classes that are inherited by the xen-image-minimal recipe, change the inherit of all of these to only apply to qemu machines with the qemuall override. Update qemuboot-xen-defaults.bbclass to supply working default parameters for the qemuarm machine needed to boot successfully in testing. Also change all the arch-specific variable overrides into narrower qemu platform overrides instead to avoid unnecessary interactions with other Arm platform machines. Signed-off-by: Christopher Clark <christopher.clark@starlab.io> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xen: Add missing space in append to IMAGE_INSTALLBertrand Marquis2022-04-261-2/+2
| | | | | | | | | Add a space before doing an append in IMAGE_INSTALL on x86. This is solving issues happening if someone is using IMAGE_INSTALL in local.conf to add things to the generated image. Signed-off-by: Bertrand Marquis <bertrand.marquis@arm.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xen-*image-minimal: Install *xen-acpi-processor package only for x86* machinesKamil Dziezyk2022-03-021-1/+4
| | | | | | | | | | | Kernel module xen_acpi_processor is built only for x86* architectures, therefore 'kernel-module-xen-acpi-processor' package is compatible only with x86* machines. Issue-Id: SCM-3892 Signed-off-by: Kamil Dziezyk <kamil.dziezyk@arm.com> Change-Id: I8dde00e3c78a1f9eea50b19fbc1981f5e26df133 Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xtf: add testimage integration to run XTF test cases in OEQAChristopher Clark2021-09-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a new minimal OEQA test case to run the Xen Test Framework test runner in the standard testimage step. Tested with qemux86-64 and designed for compatibility with Arm when XTF supports it. To enable, append to local.conf: INHERIT += "testimage" QEMU_USE_SLIRP = "1" TEST_SERVER_IP = "127.0.0.1" To run: bitbake -c testimage xtf-image For inspection while it runs, at another shell prompt: * Observe the image booting: tail -f ${TMPDIR}/work/qemux86_64-*/xtf-image/*/testimage/qemu_boot_log.* * Observe the tests running once boot has completed: tail -f ${TMPDIR}/work/qemux86_64-*/xtf-image/*/temp/log.do_testimage The XTF test sequence by default is a single XTF test case with minimal hardware dependency to ensure that Xen is running, the Xen toolstack is functional and XTF works. Additional XTF test cases for an image can be configured via variables that are documented in the OEQA test case: * XTF_TEST_CASES_POPULATE * XTF_TEST_CASES_SKIP * XTF_TEST_CASES_REQUIRE Since testimage requires a functioning network to perform the tests on the image and the qemu MACHINES do not have networking enabled this commit provides a new qemuboot-testimage-network bbclass to add an image postprocess command to enable a functional eth0 for qemu MACHINES. Signed-off-by: Christopher Clark <christopher.clark@starlab.io> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xen-image-minimal: supply bootloader config for qemux86-64 machineChristopher Clark2021-09-021-0/+1
| | | | | | | | | | | | | | | | Add a dedicated bootloader config for the qemux86-64 machine so that the 'pmtmr=0' kernel command line argument can be provided, which removes an error message that otherwise occurs in syslog during boot which is detected by an OEQA test case causing it to fail. A new kickstart file is provided that applies the new bootloader config and it is supplied as an override to WKS_FILE for this image. This is work towards enabling the Xen Test Framework (XTF) in the OEQA testimage framework. Signed-off-by: Christopher Clark <christopher.clark@starlab.io> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* global: overrides conversion pass 2Bruce Ashfield2021-08-021-2/+2
| | | | Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* global: overrides syntax conversionBruce Ashfield2021-08-021-9/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | OEcore/bitbake are moving to use the clearer ":" as an overrides separator. This is pass one of updating the meta-virt recipes to use that syntax. This has only been minimally build/runtime tested, more changes will be required for missed overrides, or incorrect conversions Note: A recent bitbake is required: commit 75fad23fc06c008a03414a1fc288a8614c6af9ca Author: Richard Purdie <richard.purdie@linuxfoundation.org> Date: Sun Jul 18 12:59:15 2021 +0100 bitbake: data_smart/parse: Allow ':' characters in variable/function names It is becomming increasingly clear we need to find a way to show what is/is not an override in our syntax. We need to do this in a way which is clear to users, readable and in a way we can transition to. The most effective way I've found to this is to use the ":" charater to directly replace "_" where an override is being specified. This includes "append", "prepend" and "remove" which are effectively special override directives. This patch simply adds the character to the parser so bitbake accepts the value but maps it back to "_" internally so there is no behaviour change. This change is simple enough it could potentially be backported to older version of bitbake meaning layers using the new syntax/markup could work with older releases. Even if other no other changes are accepted at this time and we don't backport, it does set us on a path where at some point in future we could require a more explict syntax. I've tested this patch by converting oe-core/meta-yocto to the new syntax for overrides (9000+ changes) and then seeing that builds continue to work with this patch. (Bitbake rev: 0dbbb4547cb2570d2ce607e9a53459df3c0ac284) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* qemuboot, xen-image-minimal: enable runqemu for qemuarm64 Xen imagesChristopher Clark2021-07-291-2/+3
| | | | | | | | | | | | | | | | | | | The Xen hypervisor built for Arm 64-bit targets can be launched with runqemu by providing a Device Tree binary and configuration for Qemu, which enables interactive testing of Xen images. Add qemuboot-xen-dtb.bbclass to add a new bitbake task for generating the dtb file by using lopper on a device tree produced by Qemu. Add qemuboot-xen-defaults.bbclass to supply working default parameters for the qemuarm64 machine and general support for qemuboot for Xen, and adjust the defaults as needed to boot successfully in testing. Development aided by this script by Stewart Hildebrand of DornerWorks: https://gist.github.com/stewdk/110f43e0cc1d905fc6ed4c7e10d8d35e Signed-off-by: Christopher Clark <christopher.clark@starlab.io> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xen: make kernel modules an override possible variableBruce Ashfield2020-09-221-7/+7
| | | | | | | | | | Sometimes Xen is built with different mixes of kernel modules and built-in values. If we put our expected/default modules in a variable, they can be overriden by a different kernel provider as required Signed-off-by: Bruce Ashfield <bruce.ashfield@xilinx.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xen: make QB_ assignments weakBruce Ashfield2020-09-161-4/+4
| | | | | | | | | | | | | | runqemu is looking for the QB_DEFAULT_KERNEL to be set to "none" to trigger special processing. The current set of QB_DEFAULT_KERNEL="" won't trigger that behaviour .. so we change the default. We also make the assignments weak, to allow easier overrides in specific implementations. We also need a patch to qemuboot.bbclass to make the defaults ??=, and when that is done, our ?= here will work properly. Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xen-image-minimal: enable runqemu for x86-64Christopher Clark2020-03-021-0/+13
| | | | | | | | | | | | | | | | Booting this Xen image with QEMU works when launching from the wic-generated pcbios disk image with the directdisk-xen.wks kickstart file, so add the variable settings to make doing it simple -- eg: runqemu xen-image-minimal nographic slirp Tested with MACHINEs: qemux86-64 and genericx86-64 Memory allocated to qemu is increased slightly over the default to allow for running Xen and the Linux dom0 and guest VMs. Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xen-image-minimal: add a build dependency on the xen hypervisorChristopher Clark2020-02-271-0/+4
| | | | | | | | | The hypervisor may not be within the dom0 filesystem image itself, so add a task dependency to ensure that it is deployable: do_build[depends] += "xen:do_deploy" Signed-off-by: Christopher Clark <christopher.clark6@baesystems.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xen-image-minimal: add kernel-module-tun for HVM guest networkingChristopher Clark2020-02-271-0/+4
| | | | | | | Xen HVM guests are only on x86 platforms so add the module via overrides. Signed-off-by: Christopher Clark <christopher.clark6@baesystems.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xen: separate recipes for hypervisor and tools; switch to git as sourceChristopher Clark2020-02-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change changes the names of many packages produced: the xen-tools recipe now builds packages previous built by the xen recipe, so the package prefix changes from "xen-" to "xen-tools-". A temporary bbappend is provided for qemu to ease the transition. Multiple motivations for recipe separation: - improves efficiency of incremental build and development - supports building the hypervisor and tools with different toolchains and for different architectures Switch to using a git recipe on the Xen stable branch: - enables easier tracking of critical XSA security updates applied upstream by just advancing SRCREV along the branch Revision has been set to the tip of the stable-4.12 branch, which has the one XSA-312 patch applied on top of RELEASE-4.12.2. The recipe refactor externalizes the block tap components, to enable optional building of blktap in a separate recipe outside xen-tools, needed by OpenXT. xenstored is made a virtual package to support switching between alternative implementations (several exist). Update xen-image-minimal to install the xen-tools package, which replaces what was previously xen-base. Determine the flask policy filename, which is Xen-version specific, using the same method as the Xen build system. qemu: update PACKAGECONFIG[xen] for xen package renaming: allows builds to continue correctly in the meantime while openembedded core and poky are updated. OpenXT ticket reference: OXT-1694 Signed-off-by: Christopher Clark <christopher.clark6@baesystems.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
* xen-image-minimal: corrected popoulation xen.gz for syslinuxDariusz Pelowski2017-10-091-1/+1
| | | | | | | | | syslinux images cannot boot because they're missing of xen.gz file. Current poky doesn't use populate() function, instead syslinux_populate() can be used. Signed-off-by: Dariusz Pelowski <dariusz.pelowski@gmail.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
* xen-guest-image-minimal: fix making PCI a x86-only dependencyChristopher Clark2017-10-041-4/+4
| | | | | | | | | | | | | | | The logic for restricting the xen-pciback kernel module to x86-only images was incorrect, resulting in the IMAGE_INSTALL_x86 and _x86-64 variables causing the IMAGE_INSTALL variable contents to be overridden and incomplete. This correction removes the specialized IMAGE_INSTALL_x86 and _x84-64 variables. The replacement logic causes a value with conditionally-populated contents to be added to the IMAGE_INSTALL variable. Signed-off-by: Christopher Clark <christopher.clark6@baesystems.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
* xen-image-minimal: Make kernel-module-xen-pciback a x86-only dependencyChristopher Clark2017-09-191-1/+6
| | | | | | | | | | | This commit fixes the xen-image-minimal build for non-x86 arch with PCI enabled. The Linux kernel option CONFIG_XEN_PCIDEV_BACKEND currently depends on X86. This means that the xen-pciback kernel module cannot be included in this image for non-x86 architecture builds, so don't attempt to install it in that case. Signed-off-by: Christopher Clark <christopher.clark6@baesystems.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
* xen-image-minimal : change SYSLINUXCFG to SYSLINUX_CFGChristopher Clark2017-08-241-7/+7
| | | | | | | | | | | | | | | | | | | | The SYSLINUXCFG variable was renamed to SYSLINUX_CFG in poky and openembedded-core with the commits referenced below. This commit makes a corresponding change to fix the build for xen-image-minimal. Signed-off-by: Christopher Clark <christopher.clark6@baesystems.com> git://git.openembedded.org/openembedded-core commit e38c94d6bf83ed3ca7f046d9503e81b927487bf2 git://git.yoctoproject.org/poky.git commit bb1c719250cecc8725147cbdd999a9a44a11b549 Author: Robert Yang <liezhi.yang@windriver.com> Date: Wed Feb 24 01:23:58 2016 -0800 syslinux.bbclass: make vm and live can be built together Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
* xen-image-minimal: if DISTRO_FEATURES is missing xen errorDoug Goldstein2016-12-181-0/+8
| | | | | | | | | It can be confusing to users why things are failing with missing kernel dependencies when you don't have 'xen' in your DISTRO_FEATURES. This should provide them with some better info. Signed-off-by: Doug Goldstein <cardoe@cardoe.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
* xen-image-minimal: Install qemu instead of xen-qemuNathan Rossi2015-02-201-1/+1
| | | | | | * Install QEMU from the distro as opposed to a specific xen-qemu setup Signed-off-by: Nathan Rossi <nathan.rossi@xilinx.com>
* xen-*image-minimal: Setup conditional based on MACHINE_FEATURESNathan Rossi2015-02-201-2/+2
| | | | | | | * Conditionally add packages to the image depending on whether the machine supports the respective feature Signed-off-by: Nathan Rossi <nathan.rossi@xilinx.com>
* xen-image-minimal: fix syslinux dependencyChris Patterson2013-11-241-0/+2
| | | | | | | | | | Install libcom32.c32 when populating syslinux-based images. When syslinux upgraded to v6, libcom32.c32 became a dependency for mboot.c32. Signed-off-by: Chris Patterson <cjp256@gmail.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
* xen-image-minimal: update image installed modules to reflect xen fragment ↵Chris Patterson2013-10-101-6/+0
| | | | | | | changes. Signed-off-by: Chris Patterson <cjp256@gmail.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
* xen-image-minimal: break out arguments for xen and linux kernel as variables ↵Chris Patterson2013-10-101-1/+4
| | | | | | | SYSLINUX_XEN_ARGS and SYSLINUX_KERNEL_ARGS to allow modification/overwriting. Signed-off-by: Chris Patterson <cjp256@gmail.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
* xen-image-minimal: update image to support xen 4.3.0 base with xl toolstack.Chris Patterson2013-09-241-6/+46
| | | | Signed-off-by: Chris Patterson <cjp256@gmail.com>
* xen-image-minimal: Changed from task-core-boot to package-core-bootMihai Prica2012-11-261-1/+1
| | | | | Signed-off-by: Mihai Prica <mihai.prica@intel.com> Signed-off-by: Raymond Danks <ray.danks@se-eng.com>
* images/xen-image-minimal: Initial meta file for a minimal xen image.Raymond Danks2012-06-211-0/+14
Signed-off-by: Raymond Danks <ray.danks@se-eng.com>