Skip to contentSkip to conversation

Revert "dm: pinctrl: Prevent (re-)configuring pins when already done before relocation"

PATCH In review Lukasz Majewski 3 participants 3 messages Jan 9, 2019 – Jan 12, 2019 Pin control

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Revert "dm: pinctrl: Prevent (re-)configuring pins when already done before relocation"

This reverts commit a7f4b4b344396590845e6552c82829ef68ef9f89.

As reported by Alex Kiernan the above optimization introduces a regression in the below use case where:

1. Device has defined 'u-boot,dm-spl' property (@ eMMC DTS node)

2. The device downloads its MLO/SPL via UART (not eMMC - the eMMC pinmux pins are NOT probed/configured in MLO/SPL).

3. The loaded via UART MLO/SPL wants to load Linux from eMMC. In this case the DM core and pinctrl uclass checks 'u-boot,dm-spl' and don't configure pins (as it thinks that those were initialized in MLO/SPL).

As we are very close to release - please revert this commit.

---

 drivers/pinctrl/pinctrl-uclass.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/pinctrl/pinctrl-uclass.c +2 -2
index 29c910c55f..6db0445067 100644
@@ -117,9 +117,9 @@ static int pinconfig_post_bind(struct udevice *dev)
 	int ret;
 
 	dev_for_each_subnode(node, dev) {
-		if (pre_reloc_only ^ ofnode_pre_reloc(node))
+		if (pre_reloc_only &&
+		    !ofnode_pre_reloc(node))
 			continue;
-
 		/*
 		 * If this node has "compatible" property, this is not
 		 * a pin configuration node, but a normal device. skip.
Signature · 1 line
2.11.0
#1 lore raw

PATCH 1/1 Revert "dm: pinctrl: Prevent (re-)configuring pins when already done before relocation"

Quoted 17 lines · Lukasz Majewski

This reverts commit a7f4b4b344396590845e6552c82829ef68ef9f89.

As reported by Alex Kiernan the above optimization introduces a regression in the below use case where:

1. Device has defined 'u-boot,dm-spl' property (@ eMMC DTS node)

2. The device downloads its MLO/SPL via UART (not eMMC - the eMMC pinmux pins are NOT probed/configured in MLO/SPL).

3. The loaded via UART MLO/SPL wants to load Linux from eMMC. In this case the DM core and pinctrl uclass checks 'u-boot,dm-spl' and don't configure pins (as it thinks that those were initialized in MLO/SPL).

As we are very close to release - please revert this commit.

Quoted 7 lines

---

 drivers/pinctrl/pinctrl-uclass.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
#2 lore raw
In reply to Lukasz Majewski
Quoted 14 lines · Lukasz Majewski

This reverts commit a7f4b4b344396590845e6552c82829ef68ef9f89.

As reported by Alex Kiernan the above optimization introduces a regression in the below use case where:

1. Device has defined 'u-boot,dm-spl' property (@ eMMC DTS node)

2. The device downloads its MLO/SPL via UART (not eMMC - the eMMC pinmux pins are NOT probed/configured in MLO/SPL).

3. The loaded via UART MLO/SPL wants to load Linux from eMMC. In this case the DM core and pinctrl uclass checks 'u-boot,dm-spl' and don't configure pins (as it thinks that those were initialized in MLO/SPL).

Quoted 5 lines

As we are very close to release - please revert this commit.

Applied to u-boot/master, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20190112/34a86891/attachment.sig>