All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chris Morgan <macroalpha82@gmail.com>
To: u-boot@lists.denx.de
Cc: quentin.schulz@cherry.de, clamor95@gmail.com, trini@konsulko.com,
	peng.fan@nxp.com, jh80.chung@samsung.com, chenjh@rock-chips.com,
	zhangqing@rock-chips.com, kever.yang@rock-chips.com,
	Chris Morgan <macromorgan@hotmail.com>
Subject: [PATCH] power: pmic: rk8xx: Don't set RK817_POWER_EN_SAVE bits
Date: Thu,  5 Nov 2026 09:10:57 -0600	[thread overview]
Message-ID: <20261105151057.477529-1-macroalpha82@gmail.com> (raw)

From: Chris Morgan <macromorgan@hotmail.com>

Don't set the RK817_POWER_EN_SAVE0 or RK817_POWER_EN_SAVE1 bits. These
bits are not used by mainline Linux and actively setting them in U-boot
interferes with their function for BSP kernels, causing systems to
hang when regulators are enabled or disabled incorrectly. [1]

[1] https://gist.github.com/fr0z3n-cs/047b24a6fd430e816fe02a877ad7ab8c

Signed-off-by: Chris Morgan <macromorgan@hotmail.com>
---
 drivers/power/pmic/rk8xx.c | 11 -----------
 1 file changed, 11 deletions(-)

diff --git a/drivers/power/pmic/rk8xx.c b/drivers/power/pmic/rk8xx.c
index 95b71d2fe49..16b3dc7cb1c 100644
--- a/drivers/power/pmic/rk8xx.c
+++ b/drivers/power/pmic/rk8xx.c
@@ -251,8 +251,6 @@ static int rk8xx_probe(struct udevice *dev)
 	int ret = 0, i, show_variant;
 	u8 msb, lsb, id_msb, id_lsb;
 	u8 on_source = 0, off_source = 0;
-	u8 power_en0, power_en1, power_en2, power_en3;
-	u8 value;
 
 	/* read Chip variant */
 	if (device_is_compatible(dev, "rockchip,rk817") ||
@@ -293,15 +291,6 @@ static int rk8xx_probe(struct udevice *dev)
 		off_source = RK817_OFF_SOURCE;
 		init_data = rk817_init_reg;
 		init_data_num = ARRAY_SIZE(rk817_init_reg);
-		power_en0 = pmic_reg_read(dev, RK817_POWER_EN0);
-		power_en1 = pmic_reg_read(dev, RK817_POWER_EN1);
-		power_en2 = pmic_reg_read(dev, RK817_POWER_EN2);
-		power_en3 = pmic_reg_read(dev, RK817_POWER_EN3);
-
-		value = (power_en0 & 0x0f) | ((power_en1 & 0x0f) << 4);
-		pmic_reg_write(dev, RK817_POWER_EN_SAVE0, value);
-		value = (power_en2 & 0x0f) | ((power_en3 & 0x0f) << 4);
-		pmic_reg_write(dev, RK817_POWER_EN_SAVE1, value);
 		break;
 	case RK806_ID: {
 		u32 rst_fun = 2;
-- 
2.53.0


             reply	other threads:[~2026-11-05 15:11 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-05 15:10 Chris Morgan [this message]
2026-11-05 16:13 ` [PATCH] power: pmic: rk8xx: Don't set RK817_POWER_EN_SAVE bits Quentin Schulz
2026-11-05 17:32   ` Chris Morgan
2026-11-06  8:57     ` Joseph Chen
2026-11-06 14:24       ` Chris Morgan
2026-11-07  8:10         ` Joseph Chen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261105151057.477529-1-macroalpha82@gmail.com \
    --to=macroalpha82@gmail.com \
    --cc=chenjh@rock-chips.com \
    --cc=clamor95@gmail.com \
    --cc=jh80.chung@samsung.com \
    --cc=kever.yang@rock-chips.com \
    --cc=macromorgan@hotmail.com \
    --cc=peng.fan@nxp.com \
    --cc=quentin.schulz@cherry.de \
    --cc=trini@konsulko.com \
    --cc=u-boot@lists.denx.de \
    --cc=zhangqing@rock-chips.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.