Skip to contentSkip to conversation

power: imx8m-power-domain: Add delay to align with kernel driver

PATCH New Fabio Estevam 2 participants 2 messages May 6, 2023 – Jul 11, 2023 Arm i.MX and Layerscape

lore
Share & tools
lore

Fabio Estevam

author reviewer
#0 lore raw

PATCH 1/1 power: imx8m-power-domain: Add delay to align with kernel driver

From: Fabio Estevam <[email protected]>

In the imx8m power domain kernel driver, there is an extra udelay(5) prior to requesting the domain to power up:

https://github.com/torvalds/linux/blob/v6.3/drivers/soc/imx/gpcv2.c#L347-L375

Haven't observed any issues due to the lack of this delay in U-Boot yet, but better to align it with the kernel driver implementation.

---
Changes since RFC:
- Added Marek's Reviewed-by tag.

 drivers/power/domain/imx8m-power-domain.c | 3 +++
 1 file changed, 3 insertions(+)
drivers/power/domain/imx8m-power-domain.c +3 -0
index 145f6ec0cd32..df5d7d695621 100644
@@ -338,6 +338,9 @@ static int imx8m_power_domain_on(struct power_domain *power_domain)
 		}
 	}
 
+	/* delay for reset to propagate */
+	udelay(5);
+
 	if (domain->bits.pxx) {
 		/* request the domain to power up */
 		setbits_le32(base + regs->pup, domain->bits.pxx);
Signature · 1 line
2.34.1
#1 lore raw

PATCH 1/1 power: imx8m-power-domain: Add delay to align with kernel driver

Quoted 8 lines

From: Fabio Estevam <[email protected]>
In the imx8m power domain kernel driver, there is an extra udelay(5) prior to requesting the domain to power up:
https://github.com/torvalds/linux/blob/v6.3/drivers/soc/imx/gpcv2.c#L347-L375
Haven't observed any issues due to the lack of this delay in U-Boot yet, but better to align it with the kernel driver implementation.

Applied to u-boot-imx, master, thanks !

Best regards,
Stefano Babic

Signature · 5 lines
=====================================================================
DENX Software Engineering GmbH,        Managing Director: Erika Unter  
HRB 165235 Munich,   Office: Kirchenstr.5, 82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: [email protected]
=====================================================================