Merge pull request #6975 from jernejsk/aw_atf

[LE11] Allwinner: atf: update power patch
This commit is contained in:
Rudi Heitbaum 2022-10-08 20:04:31 +11:00 committed by GitHub
commit 4471b14f7d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 32 additions and 22 deletions

View File

@ -0,0 +1,32 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Jernej Skrabec <jernej.skrabec@gmail.com>
Date: Sat, 8 Oct 2022 10:40:12 +0200
Subject: [PATCH] HACK: Allwinner: Don't set up PMIC
There are two issues:
1. Regulators must be bring up in certain order with delays between
steps which are not considered here.
2. PMIC setup fails on board without PMIC, like Tanix TX6.
Since LibreELEC doesn't need things that need additional regulators to
be set up in U-Boot like networking, disable PMIC completely in order to
avoid above issues.
Signed-off-by: Jernej Skrabec <jernej.skrabec@gmail.com>
---
plat/allwinner/common/sunxi_bl31_setup.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/plat/allwinner/common/sunxi_bl31_setup.c b/plat/allwinner/common/sunxi_bl31_setup.c
index a32124a182a8..34a68dd80e70 100644
--- a/plat/allwinner/common/sunxi_bl31_setup.c
+++ b/plat/allwinner/common/sunxi_bl31_setup.c
@@ -177,8 +177,6 @@ void bl31_platform_setup(void)
if (soc_id == SUNXI_SOC_A64 || soc_id == SUNXI_SOC_H5)
mmio_write_32(SUNXI_CCU_BASE + 0x5c, 0x1);
- sunxi_pmic_setup(soc_id, fdt);
-
INFO("BL31: Platform setup done\n");
}

View File

@ -1,22 +0,0 @@
From 89a2da7c8bae95cf9225015489736e2fc434f4d9 Mon Sep 17 00:00:00 2001
From: Jernej Skrabec <jernej.skrabec@siol.net>
Date: Sat, 2 Jan 2021 16:35:31 +0100
Subject: [PATCH] sunxi: Don't enable referenced regulators
This break certain devices which need appropriate power on sequence.
---
drivers/allwinner/axp/common.c | 3 ---
1 file changed, 3 deletions(-)
--- a/drivers/allwinner/axp/common.c
+++ b/drivers/allwinner/axp/common.c
@@ -112,9 +112,6 @@ static bool should_enable_regulator(const void *fdt,
if (is_node_disabled(fdt, node)) {
return false;
}
- if (fdt_getprop(fdt, node, "phandle", NULL) != NULL) {
- return true;
- }
if (fdt_getprop(fdt, node, "regulator-always-on", NULL) != NULL) {
return true;
}