mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-04-11 10:43:46 -04:00
arm64: dts: qcom: x1e/x1p: Add EL2 overlay for WoA devices
WoA devices using x1e/x1p use android firmware to boot, which notably includes Gunyah hypervisor. This means that, so far, Linux-based OS could only boot in EL1 on those devices. However Windows can replace Gunyah upon boot with it's own hypervisor, and with the use of tools such as "slbounce", it's possible to do the same for Linux-based OS, in which case some modifications to the DT are necessary to facilitate the absence of Gunyah services. Add a EL2-specific DT overlay and apply it to x1e/x1p WoA devices to create -el2.dtb for each of them alongside "normal" dtb. Signed-off-by: Nikita Travkin <nikita@trvn.ru> Link: https://lore.kernel.org/r/20250503-sc-el2-overlays-v2-5-24e9b4572e15@trvn.ru Signed-off-by: Bjorn Andersson <andersson@kernel.org>
This commit is contained in:
committed by
Bjorn Andersson
parent
428f95f41f
commit
e01acd8f3c
@@ -299,15 +299,27 @@ dtb-$(CONFIG_ARCH_QCOM) += sm8650-mtp.dtb
|
||||
dtb-$(CONFIG_ARCH_QCOM) += sm8650-qrd.dtb
|
||||
dtb-$(CONFIG_ARCH_QCOM) += sm8750-mtp.dtb
|
||||
dtb-$(CONFIG_ARCH_QCOM) += sm8750-qrd.dtb
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e001de-devkit.dtb
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e78100-lenovo-thinkpad-t14s.dtb
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e78100-lenovo-thinkpad-t14s-oled.dtb
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e80100-asus-vivobook-s15.dtb
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e80100-crd.dtb
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e80100-dell-xps13-9345.dtb
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e80100-hp-omnibook-x14.dtb
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e80100-lenovo-yoga-slim7x.dtb
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e80100-microsoft-romulus13.dtb
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e80100-microsoft-romulus15.dtb
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e80100-qcp.dtb
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1p42100-crd.dtb
|
||||
x1e001de-devkit-el2-dtbs := x1e001de-devkit.dtb x1-el2.dtbo
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e001de-devkit.dtb x1e001de-devkit-el2.dtb
|
||||
x1e78100-lenovo-thinkpad-t14s-el2-dtbs := x1e78100-lenovo-thinkpad-t14s.dtb x1-el2.dtbo
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e78100-lenovo-thinkpad-t14s.dtb x1e78100-lenovo-thinkpad-t14s-el2.dtb
|
||||
x1e78100-lenovo-thinkpad-t14s-oled-el2-dtbs := x1e78100-lenovo-thinkpad-t14s-oled.dtb x1-el2.dtbo
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e78100-lenovo-thinkpad-t14s-oled.dtb x1e78100-lenovo-thinkpad-t14s-oled-el2.dtb
|
||||
x1e80100-asus-vivobook-s15-el2-dtbs := x1e80100-asus-vivobook-s15.dtb x1-el2.dtbo
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e80100-asus-vivobook-s15.dtb x1e80100-asus-vivobook-s15-el2.dtb
|
||||
x1e80100-crd-el2-dtbs := x1e80100-crd.dtb x1-el2.dtbo
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e80100-crd.dtb x1e80100-crd-el2.dtb
|
||||
x1e80100-dell-xps13-9345-el2-dtbs := x1e80100-dell-xps13-9345.dtb x1-el2.dtbo
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e80100-dell-xps13-9345.dtb x1e80100-dell-xps13-9345-el2.dtb
|
||||
x1e80100-hp-omnibook-x14-el2-dtbs := x1e80100-hp-omnibook-x14.dtb x1-el2.dtbo
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e80100-hp-omnibook-x14.dtb x1e80100-hp-omnibook-x14-el2.dtb
|
||||
x1e80100-lenovo-yoga-slim7x-el2-dtbs := x1e80100-lenovo-yoga-slim7x.dtb x1-el2.dtbo
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e80100-lenovo-yoga-slim7x.dtb x1e80100-lenovo-yoga-slim7x-el2.dtb
|
||||
x1e80100-microsoft-romulus13-el2-dtbs := x1e80100-microsoft-romulus13.dtb x1-el2.dtbo
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e80100-microsoft-romulus13.dtb x1e80100-microsoft-romulus13-el2.dtb
|
||||
x1e80100-microsoft-romulus15-el2-dtbs := x1e80100-microsoft-romulus15.dtb x1-el2.dtbo
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e80100-microsoft-romulus15.dtb x1e80100-microsoft-romulus15-el2.dtb
|
||||
x1e80100-qcp-el2-dtbs := x1e80100-qcp.dtb x1-el2.dtbo
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1e80100-qcp.dtb x1e80100-qcp-el2.dtb
|
||||
x1p42100-crd-el2-dtbs := x1p42100-crd.dtb x1-el2.dtbo
|
||||
dtb-$(CONFIG_ARCH_QCOM) += x1p42100-crd.dtb x1p42100-crd-el2.dtb
|
||||
|
||||
52
arch/arm64/boot/dts/qcom/x1-el2.dtso
Normal file
52
arch/arm64/boot/dts/qcom/x1-el2.dtso
Normal file
@@ -0,0 +1,52 @@
|
||||
// SPDX-License-Identifier: BSD-3-Clause
|
||||
|
||||
/*
|
||||
* x1 specific modifications required to boot in EL2.
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
/plugin/;
|
||||
|
||||
/* We can't and don't need to use zap shader in EL2 as linux can zap the gpu on it's own. */
|
||||
&gpu_zap_shader {
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
/*
|
||||
* When running under Gunyah, this IOMMU is controlled by the firmware,
|
||||
* however when we take ownership of it in EL2, we need to configure
|
||||
* it properly to use PCIe.
|
||||
*
|
||||
* Additionally, it seems like ITS emulation in Gunyah is broken so we
|
||||
* can't use MSI on some PCIe controllers in EL1. But we can add them
|
||||
* here for EL2.
|
||||
*/
|
||||
&pcie3 {
|
||||
iommu-map = <0 &pcie_smmu 0x30000 0x10000>;
|
||||
msi-map = <0 &gic_its 0xb0000 0x10000>;
|
||||
};
|
||||
|
||||
&pcie4 {
|
||||
iommu-map = <0 &pcie_smmu 0x40000 0x10000>;
|
||||
};
|
||||
|
||||
&pcie5 {
|
||||
iommu-map = <0 &pcie_smmu 0x50000 0x10000>;
|
||||
msi-map = <0 &gic_its 0xd0000 0x10000>;
|
||||
};
|
||||
|
||||
&pcie6a {
|
||||
iommu-map = <0 &pcie_smmu 0x60000 0x10000>;
|
||||
};
|
||||
|
||||
&pcie_smmu {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
/*
|
||||
* The "SBSA watchdog" is implemented in software in Gunyah
|
||||
* and can't be used when running in EL2.
|
||||
*/
|
||||
&sbsa_watchdog {
|
||||
status = "disabled";
|
||||
};
|
||||
@@ -8163,7 +8163,7 @@ frame@1780d000 {
|
||||
};
|
||||
};
|
||||
|
||||
watchdog@1c840000 {
|
||||
sbsa_watchdog: watchdog@1c840000 {
|
||||
compatible = "arm,sbsa-gwdt";
|
||||
reg = <0 0x1c840000 0 0x1000>,
|
||||
<0 0x1c850000 0 0x1000>;
|
||||
|
||||
Reference in New Issue
Block a user