Skip to content

RPI 5 Zephyr Dom0 exercise

GrygiriiS edited this page May 8, 2024 · 14 revisions

RPI 5 Zephyr Dom0 exercise is intended to demonstrate of basic functionality of Zephyr running as thin Xen Dom0 on Raspberry Pi 5 platform.

The thin Zephyr Xen Dom0 allows to start at boot two Xen domains and, if enabled, manage them through shell commands. The Zephyr Xen Dom0 is implemented by zephyr-dom0-xt application developed by Xen Troops tem.

Note

The work is in active development.

              Start                                              
            ┌────────────────────────┬───────────────────┐       
            │                        │                   │       
            │                        │                   │       
            │                        │                   │       
┌───────────┴─────────────┐   ┌──────▼─────┐   ┌─────────▼──────┐
│                         │   │ Dom1       │   │ Dom2           │
│   zephyr-dom0-xt        │   │ (GPIO)     │   │ (xenvm)        │
│                         │   │            │   │                │
│                         │   │ samples/   │   │     samples/   │
│                         │   │            │   │                │
└─────────────────────────┘   │ Blinky     │   │ synchronization│
                              │            │   │                │
┌──┬────────────────┬─────┐   │            │   │                │
│  │                │     │   │            │   │                │
│  │ zephyr-xenlib  │     │   │            │   │                │
│  └────────────────┘     │   │            │   │                │
│                         │   │            │   │                │
│                         │   │            │   │                │
│ Zephyr OS               │   │Zephyr OS   │   │    Zephyr OS   │
└─────────────────────────┘   └────────────┘   └────────────────┘
                                                                 
┌───────────────────────────────────────────────────────────────┐
│                  XEN                                          │
└───────────────────────────────────────────────────────────────┘
                                                                 
┌───────────────────────────────────────────────────────────────┐
│                   Raspberry Pi 5                              │
└───────────────────────────────────────────────────────────────┘

The zephyr-dom0-xt application contains binary images of Dom1 and Dom2 and domains configuration. It may contain DTBs for domains also, but it is not actual for this exercise as both domains are Zephyr.

Boot process:

  • RPI5 bootloder started u-boot
  • u-boot executes boot script:
    • loads Zephyr Dom0 binary
    • adds Xen data to the System device tree
    • loads Xen binary and starts Xen
  • Xen is booted and starts Zephyr Dom0
  • Zephyr Dom0 processing domains configuration which is statically defined
  • Zephyr Dom0 creates and starts Dom1
  • Zephyr Dom0 creates and starts Dom2
  • Dom1 and Dom2 can be paused/unpaused by using shell commands

Prerequisites

  1. check and follow RPI 5 u‐boot
  2. check and follow RPI 5 Xen
  3. check and follow RPI 5 Zephyr
  4. enable RPI 5 Zephyr xenlib

Zephyr sources

Update Zephyr sources from:

repo: https://github.com/xen-troops/zephyr.git

branch: rpi5_dev

Zephyr zephyr-dom0-xt Dom0 application

zephyr-dom0-xt sources

repo: https://github.com/GrygiriiS/zephyr-dom0-xt.git

branch: dom0-xt_rpi_5_dev_v1

Checkout and add zephyr-dom0-xt in Zephyr as Git submodule:

git submodule add -b dom0-xt_rpi_5_dev_v1 https://github.com/GrygiriiS/zephyr-dom0-xt.git

The zephyr-dom0-xt will be placed at:

<zephyr_root>
|- zephyr
   |- zephyr-dom0-xt  <-------
|- modules/
| ...
|- zephyr-xenlib/  

Dom1 preparation

The Xen Dom1 is Zephyr samples/basic/blinky application, which shell be built using test RPI 5 snippet rpi_5_xen_domd, as it uses real GPIO HW "/soc/gpio@7d517c00" which is passed through to Dom1 by Zephyr Dom0 and Xen.

Use below command to build Dom1 Zephyr Blinky application:

west build -b xenvm -p always -S rpi_5_xen_domd samples/basic/blinky

Once build is finished copy zephyr.bin into the zephyr/zephyr-dom0-xt/prebuilt/domd_img.bin

Dom2 preparation

The Xen Dom2 is pure Xen DomU which doesn't use any real SoC HW. The Dom2 is Zephyr samples/synchronization application, which shell be built using xenvm platform.

Use below command to build Dom2 Zephyr Synchronization application:

west build -b xenvm -p always samples/synchronization

Once build is finished copy zephyr.bin into the zephyr/zephyr-dom0-xt/prebuilt/domu_img.bin

Dom0 zephyr-dom0-xt preparation

Use below command to build Zephyr Dom0 zephyr-dom0-xt application:

    west build -b rpi_5 -p always -S xen_dom0 zephyr-dom0-xt -- \
    -DCONFIG_USE_DEFAULT_DOM_CFG=n -DCONFIG_DOM_CFG_NUMBER=2

Once build is finished copy zephyr.bin to RPI5 bootfs boot partition.

Dom0 zephyr-dom0-xt boot

Follow instructions in Zephyr boot under XEN from u-boot using boot script to boot the system.

Dom0 get list of available configurations

Run xu config_list to see list of available configurations:

    uart:~$ xu config_list
    rpi_5_domd
    rpi_5_domu

Dom0 create Dom1

Create Dom1 by using xu create with DomD configuration and Xen domainId -d 1. Note the zephyr-xenlib_ starts automatically domain with Xen domainId 1.

    uart:~$ xu create rpi_5_domd -d 1
    W: Domain device tree generation is not supported
    I: rambase = 40000000, ramsize = 16777216
    I: kernbase = 40000000 kernsize = 360452, dtbsize = 11058
    I: kernsize_aligned = 2097152
    I: DTB will be placed on addr = 0x40e00000
    (XEN) memory_map:add: dom1 gfn=107d517 mfn=107d517 nr=1
    uart:~$ (XEN) d1v0: vGICD: unhandled word write 0x000000ffffffff to ICACTIVER0
    (XEN) common/grant_table.c:1909:d1v0 Expanding d1 grant table from 1 to 2 frames
    ...
    (XEN) common/grant_table.c:1909:d1v0 Expanding d1 grant table from 15 to 16 frames

Dom0 create Dom2

Create Dom2 by using xu create with DomU configuration and Xen domainId -d 2.

    uart:~$ xu create rpi_5_domu -d 2
    W: Domain device tree generation is not supported
    I: rambase = 40000000, ramsize = 16777216
    I: kernbase = 40000000 kernsize = 364548, dtbsize = 11058
    I: kernsize_aligned = 2097152
    I: DTB will be placed on addr = 0x40e00000
    I: Created domain is paused
    To unpause issue: xu unpause 2

    uart:~$ xu unpause 2

Dom0 zephyr-dom0-xt attach Dom1/2 console

To see Dom1 console run command (to exit console press Ctrl-]):

xu console 1

The console output should be:

Attached to a domain console
*** Booting Zephyr OS build v3.6.0-65-gf93361527725 ***
LED state: OFF
LED state: ON
LED state: OFF
LED state: ON
LED state: OFF
LED state: ON
LED state: OFF
LED state: ON
LED state: OFF
LED state: ON
LED state: OFF
LED state: ON
LED state: OFF
Detached from console

To see Dom2 console run command (to exit console press Ctrl-]):

xu console 2

The console output should be:

Attached to a domain console
[00:00:00.000,000] <inf> xen_events: xen_events_init: events inited

[00:00:00.000,000] <inf> uart_hvc_xen: Xen HVC inited successfully

*** Booting Zephyr OS build v3.6.0-65-gf93361527725 ***
thread_a: Hello World from cpu 0 on xenvm!
thread_b: Hello World from cpu 0 on xenvm!
thread_a: Hello World from cpu 0 on xenvm!
thread_b: Hello World from cpu 0 on xenvm!
thread_a: Hello World from cpu 0 on xenvm!
thread_b: Hello World from cpu 0 on xenvm!
thread_a: Hello World from cpu 0 on xenvm!
thread_b: Hello World from cpu 0 on xenvm!
Detached from console

Dom0 zephyr-dom0-xt domain control

# domain 1 pause
xu pause 1

# domain 1 unpause
xu unpause 1

Dom0 zephyr-dom0-xt log with default vuart "arm,sbsa-uart"

NOTICE:  BL31: v2.6(release):v2.6-239-g2a9ede0bd
NOTICE:  BL31: Built : 14:26:57, Jun 22 2023


U-Boot 2024.04-00549-g2d357e4dbe (Apr 12 2024 - 16:01:24 +0300)

DRAM:  1020 MiB (effective 8 GiB)
mbox: Header response code invalid
RPI 5 Model B (0xd04170)
Core:  21 devices, 10 uclasses, devicetree: board
MMC:   mmc@fff000: 0, mmc@1100000: 1
Loading Environment from FAT... Unable to read "uboot.env" from mmc0:1... 
In:    serial,usbkbd
Out:   serial,vidconsole
Err:   serial,vidconsole
mbox: Header response code invalid
bcm2835: Could not query MAC address
Net:   No ethernet found.
starting USB...
No working controllers found
Hit any key to stop autoboot:  0 
No EFI system partition
No EFI system partition
Failed to persist EFI variables
No EFI system partition
Failed to persist EFI variables
No EFI system partition
Failed to persist EFI variables
** Booting bootflow '<NULL>' with efi_mgr
Loading Boot0000 'mmc 0' failed
EFI boot manager: Cannot load any image
Boot failed (err=-14)
No working controllers found
No ethernet found.
No ethernet found.
U-Boot> fatload mmc 0 ${scriptaddr} boot-xen-zephyr.scr 
978 bytes read in 2 ms (477.5 KiB/s)
U-Boot> source ${scriptaddr}
## Executing script at 02400000
3563524 bytes read in 150 ms (22.7 MiB/s)
Working FDT set to 2df96b00
chosen {
        xen,xen-bootargs = "console=dtuart dtuart=/soc/serial@7d001000 dom0_mem=128M";
        #size-cells = <0x00000001>;
        #address-cells = <0x00000001>;
        u-boot,version = "2024.04-00549-g2d357e4dbe";
        linux,initrd-end = <0x2efff4fe>;
        linux,initrd-start = "-��";
        rng-seed = <0x04000000 0x04000000 0x04000000 0x04000000 0x04000000 0x04000000 0x04000000 0x04000000 0x04000000 0x04000000 0x04000000 0x04000000 0x04000000 0x04000000 0x04000000 0x04000000>;
        kaslr-seed = <0x04000000 0x04000000>;
        rpi-duid = "0000911042504345";
        os_prefix = [00];
        overlay_prefix = "overlays/";
        rpi-boardrev-ext = <0x00000000>;
        log = <0x3ff16000 0x00080000>;
        bootargs = "reboot=w coherent_pool=1M 8250.nr_uarts=1 pci=pcie_bus_safe snd_bcm2835.enable_compat_alsa=0 snd_bcm2835.enable_hdmi=1  smsc95xx.macaddr=2C:CF:67:32:84:23 vc_mem.mem_base=0x3fc00000 v;
        stdout-path = "serial10:115200n8";
        phandle = <0x00000110>;
        module@0 {
                reg = <0x00080000 0x00366004>;
                compatible = "xen,linux-zimage", "xen,multiboot-module";
        };
        bootloader {
                boot-mode = <0x00000001>;
                version = "30cc5f37d65b279e820adb1d9840ad3c1cc98229";
                capabilities = <0x0000007f>;
                update-timestamp = <0x00000000>;
                build-timestamp = <0x659826f4>;
                tryboot = <0x00000000>;
                rsts = <0x00001000>;
                partition = <0x00000000>;
        };
        power {
                rpi_power_supply = <0x00002e8a 0x000f0000>;
                usb_max_current_enable = <0x00000001>;
                usb_over_current_detected = <0x00000000>;
                usbpd_power_data_objects = <0x0a0191f4 0x0002d12c 0x0003c0e1 0x0004b0b4 0x00000000 0x00000000 0x00000000>;
                max_current = <0x00001388>;
                power_reset = <0x00000000>;
        };
};
arch=arm
baudrate=115200
board=rpi
board_name=5 Model B
board_rev=0x17
board_rev_scheme=1
board_revision=0xD04170
boot_targets=mmc usb pxe dhcp
bootargs=console=dtuart dtuart=/soc/serial@7d001000 dom0_mem=128M
bootcmd=bootflow scan
bootdelay=2
cpu=armv8
dhcpuboot=usb start; dhcp u-boot.uimg; bootm
fdt_addr=2df96b00
fdt_addr_r=0x02600000
fdt_high=ffffffffffffffff
fdtaddr=2df96b00
fdtcontroladdr=3f733860
fdtfile=broadcom/bcm2712-rpi-5-b.dtb
fileaddr=80000
filesize=366004
initrd_high=ffffffffffffffff
kernel_addr_r=0x00080000
loadaddr=0x1000000
preboot=pci enum; usb start;
pxefile_addr_r=0x02500000
ramdisk_addr_r=0x02700000
scriptaddr=0x02400000
serial#=41c149f4c727eccd
soc=bcm283x
stderr=serial,vidconsole
stdin=serial,usbkbd
stdout=serial,vidconsole
vendor=raspberrypi
xen_addr_r=0x02700000

Environment size: 799/16380 bytes
1114120 bytes read in 48 ms (22.1 MiB/s)
Moving Image from 0x2700000 to 0x2800000, end=295d000
## Flattened Device Tree blob at 2df96b00
   Booting using the fdt blob at 0x2df96b00
Working FDT set to 2df96b00
   Using Device Tree in place at 000000002df96b00, end 000000002dfadfff
Working FDT set to 2df96b00

Starting kernel ...

 Xen 4.19-unstable
(XEN) Xen version 4.19-unstable (grygorii@) (aarch64-zephyr-elf-gcc (Zephyr SDK 0.16.3) 12.2.0) debug=y Tue Apr 16 17:46:29 EEST 2024
(XEN) Latest ChangeSet: Fri Jan 5 10:46:44 2024 +0200 git:8ff1f6708a-dirty
(XEN) build-id: 47ee2db9bdbedcd3d88043d51407e052cea93868
(XEN) Processor: 00000000414fd0b1: "ARM Limited", variant: 0x4, part 0xd0b,rev 0x1
(XEN) 64-bit Execution:
(XEN)   Processor Features: 1100000010111112 0000000000000010
(XEN)     Exception Levels: EL3:64 EL2:64 EL1:64 EL0:64+32
(XEN)     Extensions: FloatingPoint AdvancedSIMD
(XEN)   Debug Features: 0000000010305408 0000000000000000
(XEN)   Auxiliary Features: 0000000000000000 0000000000000000
(XEN)   Memory Model Features: 0000000000101122 0000000010212122
(XEN)   ISA Features:  0000100010211120 0000000000100001
(XEN) 32-bit Execution:
(XEN)   Processor Features: 0000000010010131:0000000000010000
(XEN)     Instruction Sets: AArch32 A32 Thumb Thumb-2 Jazelle
(XEN)     Extensions: GenericTimer
(XEN)   Debug Features: 0000000004010088
(XEN)   Auxiliary Features: 0000000000000000
(XEN)   Memory Model Features: 0000000010201105 0000000040000000
(XEN)                          0000000001260000 0000000002122211
(XEN)   ISA Features: 0000000002101110 0000000013112111 0000000021232042
(XEN)                 0000000001112131 0000000000010142 0000000001011121
(XEN) Using SMC Calling Convention v1.2
(XEN) Using PSCI v1.1
(XEN) SMP: Allowing 4 CPUs
(XEN) Generic Timer IRQ: phys=30 hyp=26 virt=27 Freq: 54000 KHz
(XEN) GICv2 initialization:
(XEN)         gic_dist_addr=000000107fff9000
(XEN)         gic_cpu_addr=000000107fffa000
(XEN)         gic_hyp_addr=000000107fffc000
(XEN)         gic_vcpu_addr=000000107fffe000
(XEN)         gic_maintenance_irq=25
(XEN) GICv2: 320 lines, 4 cpus, secure (IID 0200143b).
(XEN) XSM Framework v1.0.1 initialized
(XEN) Initialising XSM SILO mode
(XEN) Initialized GSX IRQ
(XEN) Using scheduler: SMP Credit Scheduler rev2 (credit2)
(XEN) Initializing Credit2 scheduler
(XEN)  load_precision_shift: 18
(XEN)  load_window_shift: 30
(XEN)  underload_balance_tolerance: 0
(XEN)  overload_balance_tolerance: -3
(XEN)  runqueues arrangement: socket
(XEN)  cap enforcement granularity: 10ms
(XEN) load tracking window length 1073741824 ns
(XEN) Allocated console ring of 32 KiB.
(XEN) CPU0: Guest atomics will try 17 times before pausing the domain
(XEN) Bringing up CPU1
(XEN) CPU1: Guest atomics will try 15 times before pausing the domain
(XEN) CPU 1 booted.
(XEN) Bringing up CPU2
(XEN) CPU2: Guest atomics will try 15 times before pausing the domain
(XEN) CPU 2 booted.
(XEN) Bringing up CPU3
(XEN) CPU3: Guest atomics will try 9 times before pausing the domain
(XEN) Brought up 4 CPUs
(XEN) CPU 3 booted.
(XEN) I/O virtualisation disabled
(XEN) P2M: 40-bit IPA with 40-bit PA and 16-bit VMID
(XEN) P2M: 3 levels with order-1 root, VTCR 0x00000000800a3558
(XEN) Scheduling granularity: cpu, 1 CPU per sched-resource
(XEN) Initializing Credit2 scheduler
(XEN)  load_precision_shift: 18
(XEN)  load_window_shift: 30
(XEN)  underload_balance_tolerance: 0
(XEN)  overload_balance_tolerance: -3
(XEN)  runqueues arrangement: socket
(XEN)  cap enforcement granularity: 10ms
(XEN) load tracking window length 1073741824 ns
(XEN) Adding cpu 0 to runqueue 0
(XEN)  First cpu on runqueue, activating
(XEN) Adding cpu 1 to runqueue 0
(XEN) Adding cpu 2 to runqueue 0
(XEN) Adding cpu 3 to runqueue 0
(XEN) alternatives: Patching with alt table 00000a00002e5b60 -> 00000a00002e6cd0
(XEN) CPU0 will use 24 loops workaround on exception entry
(XEN) CPU2 will use 24 loops workaround on exception entry
(XEN) CPU3 will use 24 loops workaround on exception entry
(XEN) CPU1 will use 24 loops workaround on exception entry
(XEN) *** LOADING DOMAIN 0 ***
(XEN) Loading d0 kernel from boot module @ 0000000000080000
(XEN) Loading ramdisk from boot module @ 000000002dfaa000
(XEN) Allocating 1:1 mappings totalling 128MB for dom0:
(XEN) BANK[0] 0x00000008000000-0x00000010000000 (128MB)
(XEN) Grant table range: 0x00000002800000-0x00000002840000
(XEN) Allocating PPI 16 for event channel interrupt
(XEN) d0: extended region 0: 0x2a00000->0x7e00000
(XEN) d0: extended region 1: 0x10000000->0x3fa00000
(XEN) d0: extended region 2: 0x40000000->0x1ffe00000
(XEN) Loading zImage from 0000000000080000 to 0000000008000000-0000000008366004
(XEN) Loading d0 initrd from 000000002dfaa000 to 0x000000000ee00000-0x000000000fe554fe
(XEN) Loading d0 DTB to 0x000000000ec00000-0x000000000ec130ea
(XEN) Initial low memory virq threshold set at 0x4000 pages.
(XEN) Scrubbing Free RAM in background
(XEN) Std. Loglevel: All
(XEN) Guest Loglevel: All
(XEN) *** Serial input to DOM0 (type 'CTRL-a' three times to switch input)
(XEN) Freed 348kB init memory.
(XEN) d0v0: vGICD: unhandled word write 0x000000ffffffff to ICACTIVER4
(XEN) d0v0: vGICD: unhandled word write 0x000000ffffffff to ICACTIVER8
(XEN) d0v0: vGICD: unhandled word write 0x000000ffffffff to ICACTIVER12
(XEN) d0v0: vGICD: unhandled word write 0x000000ffffffff to ICACTIVER16
(XEN) d0v0: vGICD: unhandled word write 0x000000ffffffff to ICACTIVER20
(XEN) d0v0: vGICD: unhandled word write 0x000000ffffffff to ICACTIVER24
(XEN) d0v0: vGICD: unhandled word write 0x000000ffffffff to ICACTIVER28
(XEN) d0v0: vGICD: unhandled word write 0x000000ffffffff to ICACTIVER32
(XEN) d0v0: vGICD: unhandled word write 0x000000ffffffff to ICACTIVER36
(XEN) d0v0: vGICD: unhandled word write 0x000000ffffffff to ICACTIVER0
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 1 to 2 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 2 to 3 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 3 to 4 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 4 to 5 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 5 to 6 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 6 to 7 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 7 to 8 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 8 to 9 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 9 to 10 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 10 to 11 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 11 to 12 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 12 to 13 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 13 to 14 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 14 to 15 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 15 to 16 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 16 to 17 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 17 to 18 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 18 to 19 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 19 to 20 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 20 to 21 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 21 to 22 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 22 to 23 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 23 to 24 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 24 to 25 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 25 to 26 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 26 to 27 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 27 to 28 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 28 to 29 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 29 to 30 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 30 to 31 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 31 to 32 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 32 to 33 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 33 to 34 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 34 to 35 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 35 to 36 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 36 to 37 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 37 to 38 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 38 to 39 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 39 to 40 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 40 to 41 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 41 to 42 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 42 to 43 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 43 to 44 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 44 to 45 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 45 to 46 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 46 to 47 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 47 to 48 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 48 to 49 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 49 to 50 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 50 to 51 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 51 to 52 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 52 to 53 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 53 to 54 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 54 to 55 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 55 to 56 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 56 to 57 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 57 to 58 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 58 to 59 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 59 to 60 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 60 to 61 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 61 to 62 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 62 to 63 frames
(XEN) common/grant_table.c:1909:d0v0 Expanding d0 grant table from 63 to 64 frames
(XEN) vpl011: domain_vpl011_init.
(XEN) memory_map:add: dom1 gfn=107d517 mfn=107d517 nr=1
(XEN) vpl011: domain_vpl011_init.


[00:00:00.000,000] <inf> xen_events: xen_events_init: events inited

*** Booting Zephyr OS build v3.6.0-66-g1571b3bacf36 ***
[00:00:00.473,000] <inf> xen_dom_mgmt: bootargs = 
[00:00:00.473,000] <inf> xen_dom_mgmt: Extended region 0: 0x41000000->0x100000000
[00:00:00.473,000] (XEN) d1v0: vGICD: unhandled word write 0x000000ffffffff to ICACTIVER4
<(XEN) d1v0: vGICD: unhandled word write 0x000000ffffffff to ICACTIVER0
inf(XEN) DOM1: *** Booting Zephyr OS build v3.6.0-66-g1571b3bacf36 ***
>(XEN) DOM1: LED state: OFF
 xen_dom_mgmt: Extended region 1: 0x200000000->0x10000000000
[00:00:00.473,000] <inf> xen_dom_mgmt: rambase = 40000000, ramsize = 16777216
[00:00:00.473,000] <inf> xen_dom_mgmt: kernbase = 40000000 kernsize = 229380, dtbsize = 131072
[00:00:00.473,000] <inf> xen_dom_mgmt: kernsize_aligned = 2097152
[00:00:00.473,000] <inf> xen_dom_mgmt: DTB will be placed on addr = 0x40e00000
[0(XEN) d2v0: vGICD: unhandled word write 0x000000ffffffff to ICACTIVER4
0(XEN) d2v0: vGICD: unhandled word write 0x000000ffffffff to ICACTIVER0
:00:00.4(XEN) common/grant_table.c:1909:d2v0 Expanding d2 grant table from 1 to 2 frames
8(XEN) common/grant_table.c:1909:d2v0 Expanding d2 grant table from 2 to 3 frames
4(XEN) common/grant_table.c:1909:d2v0 Expanding d2 grant table from 3 to 4 frames
,(XEN) common/grant_table.c:1909:d2v0 Expanding d2 grant table from 4 to 5 frames
0(XEN) common/grant_table.c:1909:d2v0 Expanding d2 grant table from 5 to 6 frames
0(XEN) common/grant_table.c:1909:d2v0 Expanding d2 grant table from 6 to 7 frames
0(XEN) common/grant_table.c:1909:d2v0 Expanding d2 grant table from 7 to 8 frames
](XEN) common/grant_table.c:1909:d2v0 Expanding d2 grant table from 8 to 9 frames
 (XEN) common/grant_table.c:1909:d2v0 Expanding d2 grant table from 9 to 10 frames
EN) common/grant_table.c:1909:d2v0 Expanding d2 grant table from 10 to 11 frames
[(XEN) common/grant_table.c:1909:d2v0 Expanding d2 grant table from 11 to 12 frames
0(XEN) common/grant_table.c:1909:d2v0 Expanding d2 grant table from 12 to 13 frames
m(XEN) common/grant_table.c:1909:d2v0 Expanding d2 grant table from 13 to 14 frames
<(XEN) common/grant_table.c:1909:d2v0 Expanding d2 grant table from 14 to 15 frames
i(XEN) common/grant_table.c:1909:d2v0 Expanding d2 grant table from 15 to 16 frames
nf> xen_dom_mgmt: bootargs = 
[00:00:00.484,000] <inf> xen_dom_mgmt: Extended region 0: 0x41000000->0x100000000
[00:00:00.484,000] <inf> xen_dom_mgmt: Extended region 1: 0x200000000->0x10000000000
[00:00:00.484,000] <inf> xen_dom_mgmt: rambase = 40000000, ramsize = 16777216
[00:00:00.484,000] <inf> xen_dom_mgmt: kernbase = 40000000 kernsize = 364548, dtbsize = 131072
[00:00:00.484,000] <inf> xen_dom_mgmt: kernsize_aligned = 2097152
[00:00:00.484,000] <inf> xen_dom_mgmt: DTB will be placed on addr = 0x40e00000
[00:00:00.486,000] <inf> xen_dom_mgmt: Created domain is paused
To unpause issue: xu unpause 2
uart:~$ (XEN) DOM2: [00:00:00.000,000] <inf> xen_events: xen_events_init: events inited
(XEN) DOM2: 
(XEN) DOM2: *** Booting Zephyr OS build v3.6.0-66-g1571b3bacf36 ***
(XEN) DOM2: thread_a: Hello World from cpu 0 on xenvm!
(XEN) DOM1: LED state: ON
(XEN) DOM2: thread_b: Hello World from cpu 0 on xenvm!
(XEN) DOM2: thread_a: Hello World from cpu 0 on xenvm!
(XEN) DOM1: LED state: OFF
(XEN) DOM2: thread_b: Hello World from cpu 0 on xenvm!
(XEN) DOM2: thread_a: Hello World from cpu 0 on xenvm!
(XEN) DOM1: LED state: ON
(XEN) DOM1: LED state: OFF