Skip to content

Commit

Permalink
Revert "dm: pinctrl: Prevent (re-)configuring pins when already done …
Browse files Browse the repository at this point in the history
…before relocation"

This reverts commit a7f4b4b.

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.

Reported-by: Alex Kiernan <[email protected]>
Signed-off-by: Lukasz Majewski <[email protected]>
Reviewed-by: Simon Glass <[email protected]>
  • Loading branch information
Lukasz Majewski authored and trini committed Jan 11, 2019
1 parent 64abfc9 commit b6a6238
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/pinctrl/pinctrl-uclass.c
Original file line number Diff line number Diff line change
Expand Up @@ -139,9 +139,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.
Expand Down

0 comments on commit b6a6238

Please sign in to comment.