Skip to content

iq-x5121-evk: add x1 el2 DTBO building and FIT DTB mapping#2248

Open
xinlon-z wants to merge 2 commits into
qualcomm-linux:masterfrom
xinlon-z:purwa-kvm-fit-dtb
Open

iq-x5121-evk: add x1 el2 DTBO building and FIT DTB mapping#2248
xinlon-z wants to merge 2 commits into
qualcomm-linux:masterfrom
xinlon-z:purwa-kvm-fit-dtb

Conversation

@xinlon-z
Copy link
Copy Markdown
Contributor

@xinlon-z xinlon-z commented May 20, 2026

KVM support on IQ-X5121 Evaluation Kit requires applying the el2 DTBO at boot. Add FIT_DTB_COMPATIBLE entries to allow UEFI to correctly match and apply the x1-el2.dtbo(shared the same one with IQ-X7181 #2234 ) overlay when booting with KVM.

Generated ITS file overview

$ cat build/tmp/deploy/images/iq-x5121-evk/qclinux-fit-image.its
/dts-v1/;

/ {
        description = "Kernel fitImage for Qualcomm Linux Reference Distro/7.0+git/iq-x5121-evk";
        #address-cells = <1>;
        images {
                fdt-qcom-metadata.dtb {
                        description = "Flattened Device Tree blob";
                        type = "qcom_metadata";
                        compression = "none";
                        data = /incbin/("/local/mnt/workspace/xinlon/work/hamoa_mainline/build/tmp/work/iq_x5121_evk-qcom-linux/linux-qcom-next/7.0+git/linux-qcom-next-7.0+git/arch/arm64/boot/dts/qcom/qcom-metadata.dtb");
                        arch = "arm64";
                };
                fdt-x1-el2.dtbo {
                        description = "Flattened Device Tree blob";
                        type = "flat_dt";
                        compression = "none";
                        data = /incbin/("/local/mnt/workspace/xinlon/work/hamoa_mainline/build/tmp/work/iq_x5121_evk-qcom-linux/linux-qcom-next/7.0+git/linux-qcom-next-7.0+git/arch/arm64/boot/dts/qcom/x1-el2.dtbo");
                        arch = "arm64";
                };
                fdt-purwa-iot-evk.dtb {
                        description = "Flattened Device Tree blob";
                        type = "flat_dt";
                        compression = "none";
                        data = /incbin/("/local/mnt/workspace/xinlon/work/hamoa_mainline/build/tmp/work/iq_x5121_evk-qcom-linux/linux-qcom-next/7.0+git/linux-qcom-next-7.0+git/arch/arm64/boot/dts/qcom/purwa-iot-evk.dtb");
                        arch = "arm64";
                };
        };
        configurations {
                conf-1 {
                        description = "FDT Blob";
                        fdt = "fdt-purwa-iot-evk.dtb";
                        compatible = "qcom,purwa-evk";
                };
                conf-2 {
                        description = "FDT Blob";
                        fdt = "fdt-purwa-iot-evk.dtb", "fdt-x1-el2.dtbo";
                        compatible = "qcom,purwa-evk";
                };
        };
};

KVM Boot log:

root@iq-x5121-evk:~# dmesg | grep kvm
[    0.092851] kvm [1]: nv: 570 coarse grained trap handlers
[    0.092985] kvm [1]: nv: 710 fine grained trap handlers
[    0.093060] kvm [1]: IPA Size Limit: 44 bits
[    0.093071] kvm [1]: GICv4 support disabled
[    0.093072] kvm [1]: GICv3: no GICV resource entry
[    0.093073] kvm [1]: disabling GICv2 emulation
[    0.093088] kvm [1]: GIC system register CPU interface enabled
[    0.093100] kvm [1]: vgic interrupt IRQ9
[    0.093119] kvm [1]: Broken CNTVOFF_EL2, trapping virtual timer
[    0.093123] kvm [1]: VHE mode initialized successfully
root@iq-x5121-evk:~# ls -alh /dev/kvm
crw-rw-rw- 1 root kvm 10, 232 Mar 13 15:35 /dev/kvm

Pending by issue: #1962

@xinlon-z xinlon-z marked this pull request as ready for review May 25, 2026 07:09
@xinlon-z
Copy link
Copy Markdown
Contributor Author

This PR depends on PR #2165 being merged to resolve issue #1962.

@xinlon-z xinlon-z marked this pull request as draft May 25, 2026 07:13
@xinlon-z xinlon-z force-pushed the purwa-kvm-fit-dtb branch from ed25d39 to 4aca6e3 Compare May 25, 2026 07:27
xinlon-z added 2 commits May 26, 2026 19:09
KVM support on iq-x5121-evk requires the X1 EL2 DTBO, which is shared with iq-x7181-evk.
To support this, enable EL2 DTBO generation in the kernel DT list.

Signed-off-by: Xinzheng Long <xinzheng.long@oss.qualcomm.com>
KVM support on IQ-X5121 Evaluation Kit requires applying the el2 DTBO at boot.
Add FIT_DTB_COMPATIBLE entries to allow UEFI to correctly match and apply
the `x1-el2.dtbo` overlay when booting with KVM.

Signed-off-by: Xinzheng Long <xinzheng.long@oss.qualcomm.com>
@xinlon-z xinlon-z force-pushed the purwa-kvm-fit-dtb branch from 4aca6e3 to 203e822 Compare May 26, 2026 11:09
@xinlon-z xinlon-z marked this pull request as ready for review May 26, 2026 11:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant