diff options
| author | Mark Hatle <mark.hatle@amd.com> | 2025-02-13 10:30:33 -0700 |
|---|---|---|
| committer | Mark Hatle <mark.hatle@amd.com> | 2025-03-30 14:16:15 -0600 |
| commit | e56c47c22b297edf1794abc86b7fa41fb89c9ed8 (patch) | |
| tree | 02364ec148290969fba35d8bec54aecc55061313 /meta-xilinx-virtualization | |
| parent | 5463a2941d5bb24fd58c235640d1f2fec00f4d9d (diff) | |
| download | meta-xilinx-e56c47c22b297edf1794abc86b7fa41fb89c9ed8.tar.gz | |
device-tree: Disable meta-virtualization xen DTSI and apply it only for Linux
In meta-virtualization, when used with meta-xilinx-core, the XEN dtsi was
always enabled, even in a non-Linux based build. This caused compilation
issues as cortex-r5 and other CPUs are missing required parameters for Xen.
Signed-off-by: Mark Hatle <mark.hatle@amd.com>
Diffstat (limited to 'meta-xilinx-virtualization')
8 files changed, 276 insertions, 0 deletions
diff --git a/meta-xilinx-virtualization/conf/layer.conf b/meta-xilinx-virtualization/conf/layer.conf index 1ce8ccfe..1f759ffc 100644 --- a/meta-xilinx-virtualization/conf/layer.conf +++ b/meta-xilinx-virtualization/conf/layer.conf | |||
| @@ -22,3 +22,5 @@ XILINX_XEN_VERSION[v2024.1] = "4.18+stable-xilinx+git%" | |||
| 22 | XILINX_XEN_VERSION[v2024.2] = "4.18+stable-xilinx+git%" | 22 | XILINX_XEN_VERSION[v2024.2] = "4.18+stable-xilinx+git%" |
| 23 | PREFERRED_VERSION_xen ?= "${@d.getVarFlag('XILINX_XEN_VERSION', d.getVar('XILINX_RELEASE_VERSION')) or '4.18+stable-xilinx+git%'}" | 23 | PREFERRED_VERSION_xen ?= "${@d.getVarFlag('XILINX_XEN_VERSION', d.getVar('XILINX_RELEASE_VERSION')) or '4.18+stable-xilinx+git%'}" |
| 24 | PREFERRED_VERSION_xen-tools ?= "${@d.getVarFlag('XILINX_XEN_VERSION', d.getVar('XILINX_RELEASE_VERSION')) or '4.18+stable-xilinx+git%'}" | 24 | PREFERRED_VERSION_xen-tools ?= "${@d.getVarFlag('XILINX_XEN_VERSION', d.getVar('XILINX_RELEASE_VERSION')) or '4.18+stable-xilinx+git%'}" |
| 25 | |||
| 26 | BBMASK += "dynamic-layers/xilinx/recipes-bsp/device-tree/device-tree.bbappend" | ||
diff --git a/meta-xilinx-virtualization/recipes-bsp/device-tree/device-tree.bbappend b/meta-xilinx-virtualization/recipes-bsp/device-tree/device-tree.bbappend new file mode 100644 index 00000000..34e15021 --- /dev/null +++ b/meta-xilinx-virtualization/recipes-bsp/device-tree/device-tree.bbappend | |||
| @@ -0,0 +1,19 @@ | |||
| 1 | FILESEXTRAPATHS:prepend := "${THISDIR}/files:" | ||
| 2 | |||
| 3 | ENABLE_XEN_DTSI ?= "" | ||
| 4 | ENABLE_XEN_QEMU_DTSI ?= "" | ||
| 5 | |||
| 6 | XEN_EXTRA_DT_INCLUDE_FILES = "" | ||
| 7 | XEN_EXTRA_QEMU_DT_INCLUDE_FILES = "" | ||
| 8 | |||
| 9 | XEN_EXTRA_DT_INCLUDE_FILES:zynqmp = "zynqmp-xen.dtsi" | ||
| 10 | XEN_EXTRA_QEMU_DT_INCLUDE_FILES:zynqmp = "zynqmp-xen.dtsi zynqmp-xen-qemu.dtsi" | ||
| 11 | |||
| 12 | XEN_EXTRA_DT_INCLUDE_FILES:versal = "versal-xen.dtsi" | ||
| 13 | XEN_EXTRA_QEMU_DT_INCLUDE_FILES:versal = "versal-xen.dtsi versal-xen-qemu.dtsi" | ||
| 14 | |||
| 15 | XEN_EXTRA_DT_INCLUDE_FILES:versal-net = "versal-net-xen.dtsi" | ||
| 16 | XEN_EXTRA_QEMU_DT_INCLUDE_FILES:versal-net = "versal-net-xen.dtsi versal-net-xen-qemu.dtsi" | ||
| 17 | |||
| 18 | EXTRA_DT_INCLUDE_FILES:append = "${@' ${XEN_EXTRA_DT_INCLUDE_FILES}' if d.getVar('ENABLE_XEN_DTSI') == '1' and d.getVar('TARGET_OS') == 'linux' else ''}" | ||
| 19 | EXTRA_DT_INCLUDE_FILES:append = "${@' ${XEN_EXTRA_QEMU_DT_INCLUDE_FILES}' if d.getVar('ENABLE_XEN_QEMU_DTSI') == '1' and d.getVar('TARGET_OS') == 'linux' else ''}" | ||
diff --git a/meta-xilinx-virtualization/recipes-bsp/device-tree/files/versal-net-xen-qemu.dtsi b/meta-xilinx-virtualization/recipes-bsp/device-tree/files/versal-net-xen-qemu.dtsi new file mode 100644 index 00000000..336d7a25 --- /dev/null +++ b/meta-xilinx-virtualization/recipes-bsp/device-tree/files/versal-net-xen-qemu.dtsi | |||
| @@ -0,0 +1,2 @@ | |||
| 1 | / { | ||
| 2 | }; | ||
diff --git a/meta-xilinx-virtualization/recipes-bsp/device-tree/files/versal-net-xen.dtsi b/meta-xilinx-virtualization/recipes-bsp/device-tree/files/versal-net-xen.dtsi new file mode 100644 index 00000000..7da1f9f1 --- /dev/null +++ b/meta-xilinx-virtualization/recipes-bsp/device-tree/files/versal-net-xen.dtsi | |||
| @@ -0,0 +1,67 @@ | |||
| 1 | &smmu { | ||
| 2 | status = "okay"; | ||
| 3 | }; | ||
| 4 | |||
| 5 | &adma0 { | ||
| 6 | iommus = <&smmu 0x210>; | ||
| 7 | }; | ||
| 8 | |||
| 9 | &adma1 { | ||
| 10 | iommus = <&smmu 0x212>; | ||
| 11 | }; | ||
| 12 | |||
| 13 | &adma2 { | ||
| 14 | iommus = <&smmu 0x214>; | ||
| 15 | }; | ||
| 16 | |||
| 17 | &adma3 { | ||
| 18 | iommus = <&smmu 0x216>; | ||
| 19 | }; | ||
| 20 | |||
| 21 | &adma4 { | ||
| 22 | iommus = <&smmu 0x218>; | ||
| 23 | }; | ||
| 24 | |||
| 25 | &adma5 { | ||
| 26 | iommus = <&smmu 0x21a>; | ||
| 27 | }; | ||
| 28 | |||
| 29 | &adma6 { | ||
| 30 | iommus = <&smmu 0x21c>; | ||
| 31 | }; | ||
| 32 | |||
| 33 | &adma7 { | ||
| 34 | iommus = <&smmu 0x21e>; | ||
| 35 | }; | ||
| 36 | |||
| 37 | &dwc3_0 { | ||
| 38 | iommus = <&smmu 0x230>; | ||
| 39 | }; | ||
| 40 | |||
| 41 | &dwc3_1 { | ||
| 42 | iommus = <&smmu 0x232>; | ||
| 43 | }; | ||
| 44 | |||
| 45 | &gem0 { | ||
| 46 | iommus = <&smmu 0x234>; | ||
| 47 | }; | ||
| 48 | |||
| 49 | &gem1 { | ||
| 50 | iommus = <&smmu 0x235>; | ||
| 51 | }; | ||
| 52 | |||
| 53 | &sdhci0 { | ||
| 54 | iommus = <&smmu 0x242>; | ||
| 55 | }; | ||
| 56 | |||
| 57 | &sdhci1 { | ||
| 58 | iommus = <&smmu 0x243>; | ||
| 59 | }; | ||
| 60 | |||
| 61 | &qspi { | ||
| 62 | iommus = <&smmu 0x244>; | ||
| 63 | }; | ||
| 64 | |||
| 65 | &ospi { | ||
| 66 | iommus = <&smmu 0x245>; | ||
| 67 | }; | ||
diff --git a/meta-xilinx-virtualization/recipes-bsp/device-tree/files/versal-xen-qemu.dtsi b/meta-xilinx-virtualization/recipes-bsp/device-tree/files/versal-xen-qemu.dtsi new file mode 100644 index 00000000..336d7a25 --- /dev/null +++ b/meta-xilinx-virtualization/recipes-bsp/device-tree/files/versal-xen-qemu.dtsi | |||
| @@ -0,0 +1,2 @@ | |||
| 1 | / { | ||
| 2 | }; | ||
diff --git a/meta-xilinx-virtualization/recipes-bsp/device-tree/files/versal-xen.dtsi b/meta-xilinx-virtualization/recipes-bsp/device-tree/files/versal-xen.dtsi new file mode 100644 index 00000000..6782e925 --- /dev/null +++ b/meta-xilinx-virtualization/recipes-bsp/device-tree/files/versal-xen.dtsi | |||
| @@ -0,0 +1,59 @@ | |||
| 1 | &smmu { | ||
| 2 | status = "okay"; | ||
| 3 | }; | ||
| 4 | |||
| 5 | &gem0 { | ||
| 6 | iommus = <&smmu 0x234>; | ||
| 7 | }; | ||
| 8 | |||
| 9 | &gem1 { | ||
| 10 | iommus = <&smmu 0x235>; | ||
| 11 | }; | ||
| 12 | |||
| 13 | &dwc3_0 { | ||
| 14 | iommus = <&smmu 0x230>; | ||
| 15 | }; | ||
| 16 | |||
| 17 | &qspi { | ||
| 18 | iommus = <&smmu 0x244>; | ||
| 19 | }; | ||
| 20 | |||
| 21 | &lpd_dma_chan0 { | ||
| 22 | iommus = <&smmu 0x210>; | ||
| 23 | }; | ||
| 24 | |||
| 25 | &lpd_dma_chan1 { | ||
| 26 | iommus = <&smmu 0x212>; | ||
| 27 | }; | ||
| 28 | |||
| 29 | &lpd_dma_chan2 { | ||
| 30 | iommus = <&smmu 0x214>; | ||
| 31 | }; | ||
| 32 | |||
| 33 | &lpd_dma_chan3 { | ||
| 34 | iommus = <&smmu 0x216>; | ||
| 35 | }; | ||
| 36 | |||
| 37 | &lpd_dma_chan4 { | ||
| 38 | iommus = <&smmu 0x218>; | ||
| 39 | }; | ||
| 40 | |||
| 41 | &lpd_dma_chan5 { | ||
| 42 | iommus = <&smmu 0x21a>; | ||
| 43 | }; | ||
| 44 | |||
| 45 | &lpd_dma_chan6 { | ||
| 46 | iommus = <&smmu 0x21c>; | ||
| 47 | }; | ||
| 48 | |||
| 49 | &lpd_dma_chan7 { | ||
| 50 | iommus = <&smmu 0x21e>; | ||
| 51 | }; | ||
| 52 | |||
| 53 | &sdhci0 { | ||
| 54 | iommus = <&smmu 0x242>; | ||
| 55 | }; | ||
| 56 | |||
| 57 | &sdhci1 { | ||
| 58 | iommus = <&smmu 0x243>; | ||
| 59 | }; | ||
diff --git a/meta-xilinx-virtualization/recipes-bsp/device-tree/files/zynqmp-xen-qemu.dtsi b/meta-xilinx-virtualization/recipes-bsp/device-tree/files/zynqmp-xen-qemu.dtsi new file mode 100644 index 00000000..336d7a25 --- /dev/null +++ b/meta-xilinx-virtualization/recipes-bsp/device-tree/files/zynqmp-xen-qemu.dtsi | |||
| @@ -0,0 +1,2 @@ | |||
| 1 | / { | ||
| 2 | }; | ||
diff --git a/meta-xilinx-virtualization/recipes-bsp/device-tree/files/zynqmp-xen.dtsi b/meta-xilinx-virtualization/recipes-bsp/device-tree/files/zynqmp-xen.dtsi new file mode 100644 index 00000000..3d75be65 --- /dev/null +++ b/meta-xilinx-virtualization/recipes-bsp/device-tree/files/zynqmp-xen.dtsi | |||
| @@ -0,0 +1,123 @@ | |||
| 1 | &smmu { | ||
| 2 | status = "okay"; | ||
| 3 | }; | ||
| 4 | |||
| 5 | &gem0 { | ||
| 6 | iommus = <&smmu 0x874>; | ||
| 7 | }; | ||
| 8 | |||
| 9 | &gem1 { | ||
| 10 | iommus = <&smmu 0x875>; | ||
| 11 | }; | ||
| 12 | |||
| 13 | &gem2 { | ||
| 14 | iommus = <&smmu 0x876>; | ||
| 15 | }; | ||
| 16 | |||
| 17 | &gem3 { | ||
| 18 | iommus = <&smmu 0x877>; | ||
| 19 | }; | ||
| 20 | |||
| 21 | &dwc3_0 { | ||
| 22 | iommus = <&smmu 0x860>; | ||
| 23 | }; | ||
| 24 | |||
| 25 | &dwc3_1 { | ||
| 26 | iommus = <&smmu 0x861>; | ||
| 27 | }; | ||
| 28 | |||
| 29 | &qspi { | ||
| 30 | iommus = <&smmu 0x873>; | ||
| 31 | }; | ||
| 32 | |||
| 33 | &lpd_dma_chan1 { | ||
| 34 | iommus = <&smmu 0x868>; | ||
| 35 | }; | ||
| 36 | |||
| 37 | &lpd_dma_chan2 { | ||
| 38 | iommus = <&smmu 0x869>; | ||
| 39 | }; | ||
| 40 | |||
| 41 | &lpd_dma_chan3 { | ||
| 42 | iommus = <&smmu 0x86a>; | ||
| 43 | }; | ||
| 44 | |||
| 45 | &lpd_dma_chan4 { | ||
| 46 | iommus = <&smmu 0x86b>; | ||
| 47 | }; | ||
| 48 | |||
| 49 | &lpd_dma_chan5 { | ||
| 50 | iommus = <&smmu 0x86c>; | ||
| 51 | }; | ||
| 52 | |||
| 53 | &lpd_dma_chan6 { | ||
| 54 | iommus = <&smmu 0x86d>; | ||
| 55 | }; | ||
| 56 | |||
| 57 | &lpd_dma_chan7 { | ||
| 58 | iommus = <&smmu 0x86e>; | ||
| 59 | }; | ||
| 60 | |||
| 61 | &lpd_dma_chan8 { | ||
| 62 | iommus = <&smmu 0x86f>; | ||
| 63 | }; | ||
| 64 | |||
| 65 | &fpd_dma_chan1 { | ||
| 66 | iommus = <&smmu 0x14e8>; | ||
| 67 | }; | ||
| 68 | |||
| 69 | &fpd_dma_chan2 { | ||
| 70 | iommus = <&smmu 0x14e9>; | ||
| 71 | }; | ||
| 72 | |||
| 73 | &fpd_dma_chan3 { | ||
| 74 | iommus = <&smmu 0x14ea>; | ||
| 75 | }; | ||
| 76 | |||
| 77 | &fpd_dma_chan4 { | ||
| 78 | iommus = <&smmu 0x14eb>; | ||
| 79 | }; | ||
| 80 | |||
| 81 | &fpd_dma_chan5 { | ||
| 82 | iommus = <&smmu 0x14ec>; | ||
| 83 | }; | ||
| 84 | |||
| 85 | &fpd_dma_chan6 { | ||
| 86 | iommus = <&smmu 0x14ed>; | ||
| 87 | }; | ||
| 88 | |||
| 89 | &fpd_dma_chan7 { | ||
| 90 | iommus = <&smmu 0x14ee>; | ||
| 91 | }; | ||
| 92 | |||
| 93 | &fpd_dma_chan8 { | ||
| 94 | iommus = <&smmu 0x14ef>; | ||
| 95 | }; | ||
| 96 | |||
| 97 | &sdhci0 { | ||
| 98 | iommus = <&smmu 0x870>; | ||
| 99 | }; | ||
| 100 | |||
| 101 | &sdhci1 { | ||
| 102 | iommus = <&smmu 0x871>; | ||
| 103 | }; | ||
| 104 | |||
| 105 | &nand0 { | ||
| 106 | iommus = <&smmu 0x872>; | ||
| 107 | }; | ||
| 108 | |||
| 109 | &pcie { | ||
| 110 | iommus = <&smmu 0x4d0>; | ||
| 111 | }; | ||
| 112 | |||
| 113 | &zynqmp_dpsub { | ||
| 114 | iommus = <&smmu 0xce3>; | ||
| 115 | }; | ||
| 116 | |||
| 117 | &zynqmp_dpdma { | ||
| 118 | iommus = <&smmu 0xce4>; | ||
| 119 | }; | ||
| 120 | |||
| 121 | &sata { | ||
| 122 | iommus = <&smmu 0x4c0>, <&smmu 0x4c1>, <&smmu 0x4c2>, <&smmu 0x4c3>; | ||
| 123 | }; | ||
