Commit Graph

31 Commits

Author SHA1 Message Date
Sandeep Gundlupet Raju
e7f9c2dd2f xen-boot-cmd.inc: Fix initrd boot issue with 6.6 kernel
Due to increase in 6.6 kernel image size xen ramdisk offset was
overlapping with kernel image. This causes xen randisk image boot
failures. Hence increase the ramdisk offset to fix initrd boot
issue.

Signed-off-by: Sandeep Gundlupet Raju <sandeep.gundlupet-raju@amd.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2024-02-22 17:15:22 +00:00
Bruce Ashfield
c39840a3bd rpi: linux-yocto: move bbappend to 6.1
Moving the rpi to 6.6 to enable extended testing.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2024-01-24 02:17:12 +00:00
Sandeep Gundlupet Raju
caa14c63f1 zynqmp-xen-qemu.dtsi: Remove device_type dt nodes
Remove device_type device tree nodes as these nodes are no longer
required for Xen qemu boot.

Signed-off-by: Sandeep Gundlupet Raju <sandeep.gundlupet-raju@amd.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2023-12-14 20:00:06 +00:00
Sandeep Gundlupet Raju
7fee614060 xen-boot-cmd: Remove hard assigment for ramdisk image
Setting hard assignment for RAMDISK_IMAGE will take precedence during
variable pre-expansion. Hence set RAMDISK_IMAGE variable with soft
assignment.

Signed-off-by: Sandeep Gundlupet Raju <sandeep.gundlupet-raju@amd.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2023-08-17 20:01:19 +00:00
Sandeep Gundlupet Raju
7332b59472 recipes-bsp: Add u-boot-xlnx scripts for Xen support
Add new boot.cmd.xen to u-boot-xlnx-scr bbappend to enable
Xen support for ZynqMP and Versal devices.

User can enable xen u-boot script by adding below variable from
configuration file.

BOOTMODE = "xen"

This u-boot script also supports to configure below Xen params from
configuration file

params          variable assignment
------          -------------------
duart           XEN_SERIAL_CONSOLES = "serial0"
dom0_mem        DOM0_MEM = "1500M"
dom0_max_vcpus  DOM0_MAX_VCPUS = "1"
extra params    XEN_CMDLINE_APPEND = "loglvl=all"

Signed-off-by: Sandeep Gundlupet Raju <sandeep.gundlupet-raju@amd.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2023-08-01 14:41:45 -04:00
Sandeep Gundlupet Raju
c9b65ee0e5 recipes-bsp: Add device-tree files for Xen support
Add device-tree files for Xen support, Earlier all these files
were in meta-petalinux layer, Hence move these files to this layer
so that users can build Xen without including meta-petalinux.

Signed-off-by: Sandeep Gundlupet Raju <sandeep.gundlupet-raju@amd.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2023-08-01 14:41:45 -04:00
Christopher Clark
0ca7ee0286 rpi, xen, linux-yocto: enable linux-yocto 6.1 for RPi4
Added to the raspberrypi dynamic layer for use with Xen as
the default preference for Linux kernel.

Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2023-05-29 09:45:22 -04:00
Martin Jansa
5a20d44dae rpi: linux-yocto: drop 5.15 bbappend
* 5.15 recipe was dropped from oe-core in:
  https://git.openembedded.org/openembedded-core/commit/?h=master-next&id=e30b37776d16cfd4ce7f79746427ccd95b306059

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2023-05-29 09:45:22 -04:00
Mark Hatle
3b63ed0e4f xen: Make xilinx extension generic
Move the xilinx specific bbappend to a wildcard append.

Signed-off-by: Mark Hatle <mark.hatle@kernel.crashing.org>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2022-10-26 10:09:57 -04:00
Martin Jansa
884355eeed dynamic-layers/raspberrypi: drop linux-yocto 5.10 bbappend
* the inc file was dropped in:
  58f5ac6 kernel: drop 5.10 .inc
  but this .bbappend still causes parsing error, because 5.10 recipes
  were removed from oe-core

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2022-08-12 09:32:31 -04:00
Christopher Clark
8e8f59d007 xen, raspberry pi: replace linux-yocto-dev with linux-yocto 5.15
The default preferred Linux kernel for Xen on the Raspberry Pi 4 is
linux-yocto. The alternative provided option is linux-yocto-dev, but
this is unintentionally a branch tracking configuration rather than a
fixed revision.

Remove the linux-yocto-dev in favour of the linux-yocto kernel version
5.15 which has been tested and verified working on the board.

Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2022-05-25 12:19:57 -04:00
luca fancellu
f939b5bdbd xen, rpi4: Use PARTUUID for rootfs discovery
The mmc probing order has become unpredictable
due to recent linux kernel changes, therefore devices
like the raspberry pi that have two mmc interface most
of the time can't boot from the hard-coded root path.

Modify the u-boot script to fetch the PARTUUID of the
second partition of the sd card and use it to put
root=PARTUUID=<xxx> in the command line passed to
the dom0 kernel.

Reviewed-by: Diego Sueiro <diego.sueiro@arm.com>
Reviewed-by: Bertrand Marquis <bertrand.marquis@arm.com>
Reviewed-by: Christopher Clark <christopher.w.clark@gmail.com>
Tested-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Luca Fancellu <luca.fancellu@arm.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-10-08 07:30:44 -04:00
luca fancellu
cc33e3a253 xen, rpi4: Fix syntax in linux-yocto bbappend
Syntax conversion for bbappend linux-yocto_5.10
and linux-yocto-dev inside the raspberrypi
dynamic layer.

Reviewed-by: Diego Sueiro <diego.sueiro@arm.com>
Reviewed-by: Bertrand Marquis <bertrand.marquis@arm.com>
Reviewed-by: Christopher Clark <christopher.w.clark@gmail.com>
Tested-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Luca Fancellu <luca.fancellu@arm.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-10-08 07:29:28 -04:00
Bruce Ashfield
d876cfc5bf global: overrides syntax conversion
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>
2021-08-02 17:17:53 -04:00
Mark Hatle
ba24aaeea8 xen: Remove deltask for setscene
As of the gatesgarth you are no longer allowed to remove setscene tasks
as the eSDK generation expects for tasks to actually be executed.

Signed-off-by: Mark Hatle <mark.hatle@xilinx.com>
Signed-off-by: Mark Hatle <mark.hatle@kernel.crashing.org>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-04-29 23:12:46 -04:00
Christopher Clark
550a408083 xen, rpi4: add xen-rpi-u-boot-scr recipe for default u-boot script
Add a new xen-rpi-u-boot-scr recipe to PROVIDE u-boot-default-script
instead of using a bbappend to rpi-u-boot-scr.

This allows the new recipe to be selected by indicating it as
PREFERRED_PROVIDER of u-boot-default-script, and then do that in the
Xen on Raspberry Pi 4 config file, xen-raspberrypi4-64.inc.

Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-04-29 23:05:11 -04:00
Christopher Clark
686adaf68e xen, rpi4: move rpi4-machine+xen-distro cfg into dynamic layer
Improve meta-virt-xen.inc by moving all the Raspberry Pi 4 config
settings to a new xen-raspberrypi4-64.inc file in the raspberrypi
dynamic layer.

The new .inc file is included only for the raspberrypi4-64 MACHINE,
so the config settings no longer need to be applied using overrides.

Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-04-29 23:05:11 -04:00
Christopher Clark
b882ebab22 xen, rpi4: apply workaround to fix crash on boot with Xen 4.14
Apply update to the device tree to allow Xen 4.14 to boot.

Suggested-by: Bertrand Marquis <bertrand.marquis@arm.com>
Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-04-29 23:05:11 -04:00
Christopher Clark
a2664f884c xen, rpi4: fix u-boot script to load binaries from boot partition
fatload needs to read from mmc 1:1 to find the Xen hypervisor and Linux
kernel binaries with the current Yocto Linux 5.10 kernel.

Add boot messages to to the u-boot script to indicate the size of files
loaded for easier confirmation of load success.

Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-04-29 23:05:11 -04:00
Christopher Clark
d82cc67a23 xen, rpi4, linux-yocto: enable linux-yocto 5.10 for RPi4
Added to the raspberrypi dynamic layer for use with Xen as
preparation for switching to it as the default preference.

Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-04-29 23:05:11 -04:00
Christopher Clark
c3f729252f xen, rpi4: drop the raspberrypi4-64 defconfig, xen_git.bbappend
Since upstream Xen 4.14 and 4.15 have working default configs for Xen on
the Raspberry Pi 4, the defconfig and bbappend in the raspberrypi
dynamic layer can now be removed.

Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-04-29 23:05:11 -04:00
Christopher Clark
c66fca46e4 xen, rpi4: use the preferred generic multiboot,module compatible string
This string has been preferred since 2014 -- ref: Xen commit a860dfeec
and also current documentation: docs/misc/arm/device-tree/booting.txt

Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2021-04-29 23:05:11 -04:00
Christopher Clark
1ebde9be9a xen, linux-yocto-dev, RPi4: weaker assign for KBRANCH and KMACHINE
Switch to use ?= to set KBRANCH_raspberrypi4-64 to make it easier to
override elsewhere when needed for switching to a different kernel branch.
Also make the same change for KMACHINE_raspberrypi4-64 to match how it is
assigned in the meta-yocto-bsp layer.

Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2020-12-28 22:54:16 -05:00
Bruce Ashfield
2ee6fcd29b dynamic-layers: add xilinx dynamic layer for Xen support
Although this dynamic layer currently only adds Xen support, it will
eventually hold other board and platform specific tweaks to core
meta-virt recipes.

Signed-off-by: Bruce Ashfield <bruce.ashfield@xilinx.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2020-09-22 15:51:20 -04:00
Christopher Clark
dc08df210c xen, raspi4, linux-yocto-dev: Enable Xen on Raspberry Pi 4
Enable linux-yocto-dev as the Linux kernel for Xen on the
Raspberry Pi 4, with the bcm-2xxx-rpi4 KMACHINE and KBRANCH.

Set a Raspberry Pi SD card variable to increase the size of the boot
partition to accommodate both the kernel and the Xen hypervisor.

Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2020-08-11 15:58:37 -04:00
Christopher Clark
066225be3a xen, linux-raspberrypi4: remove linux-raspberrypi bbappends and patches
Retiring use of the downstream vendor kernel for use with Xen.

Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2020-08-11 15:58:37 -04:00
Christopher Clark
738bd333a9 xen, rpi4: use RPI_EXTRA_CONFIG and drop the rpi-config_git.bbappend
The GIC that is needed by Xen can be enabled via the rpi-config recipe
variable. Fixes the build after the upstream recipe changed recently.

Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2020-08-11 15:58:37 -04:00
Christopher Clark
681591b5b8 xen, raspberrypi: bugfix early boot messages: use earlycon=xenboot
Replaces the prior use of earlyprintk which is an x86-specific option.

Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2020-08-11 15:58:37 -04:00
Christopher Clark
abed1be72d xen, linux-raspberrypi: add Linux kernel 5.4 patches for Xen support
Kernel patches are in process of Linux review and submission, and are
backported from the Linux Foundation's Eve Project kernel from 5.6 to 5.4
(some patches not needed for 5.4, hence gaps in the patch sequence number)
https://github.com/lf-edge/eve/tree/master/pkg/new-kernel/patches-5.6.x

A bbappend applies Xen overrides to the boot command line.

Since linux-raspberrypi depends on linux-yocto, and
linux-yocto_virtualization introduces a requirement for cfg/virtio.scc
obtain it from the yocto kernel cache.

Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2020-07-06 16:25:56 -04:00
Christopher Clark
da1743e4b4 xen, raspberry pi 4: provide a default defconfig for raspberrypi4
Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2020-07-06 16:25:56 -04:00
Christopher Clark
90a01fcbd9 xen, raspberry pi: add dynamic-layer for Xen configuration for Rpi4
A Xen-specific u-boot script is needed for launching Xen, and the GIC
(interrupt controller) needs to be enabled.

Since this is both Xen-specific and Raspberry Pi-specific, use a
dynamic layer to conditionally enable the recipes when both
meta-virtualization and meta-raspberrypi are in use together.

Signed-off-by: Christopher Clark <christopher.w.clark@gmail.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2020-07-06 16:25:56 -04:00