diff mbox series

[v2,3/6] scripts/dtc: Update to upstream version v1.4.5-6-gc1e55a5513e9

Message ID 20180512171331.19693-3-erosca@de.adit-jv.com
State Superseded
Headers show
Series None | expand

Commit Message

Eugeniu Rosca May 12, 2018, 5:13 p.m. UTC
From: Rob Herring <robh@kernel.org>

Pickup the fix for handling unresolved phandles in overlays.

This adds the following commits from upstream:

c1e55a5513e9 checks: fix handling of unresolved phandles for dts plugins
f8872e29ce06 tests: Avoid 64-bit arithmetic in assembler
48c91c08bcfa libfdt: add stringlist functions to linker script

Signed-off-by: Rob Herring <robh@kernel.org>
[ Linux commit: e45fe7f788dd1395befe5639149ad8dacfbd94ab ]
Signed-off-by: Eugeniu Rosca <erosca@de.adit-jv.com>
---

v1->v2:
* Newly pushed

 scripts/dtc/checks.c      | 9 +++++++++
 scripts/dtc/version_gen.h | 2 +-
 2 files changed, 10 insertions(+), 1 deletion(-)

Comments

Simon Glass May 13, 2018, 10 p.m. UTC | #1
On 13 May 2018 at 03:13, Eugeniu Rosca <roscaeugeniu@gmail.com> wrote:
> From: Rob Herring <robh@kernel.org>
>
> Pickup the fix for handling unresolved phandles in overlays.
>
> This adds the following commits from upstream:
>
> c1e55a5513e9 checks: fix handling of unresolved phandles for dts plugins
> f8872e29ce06 tests: Avoid 64-bit arithmetic in assembler
> 48c91c08bcfa libfdt: add stringlist functions to linker script
>
> Signed-off-by: Rob Herring <robh@kernel.org>
> [ Linux commit: e45fe7f788dd1395befe5639149ad8dacfbd94ab ]
> Signed-off-by: Eugeniu Rosca <erosca@de.adit-jv.com>
> ---
>
> v1->v2:
> * Newly pushed
>
>  scripts/dtc/checks.c      | 9 +++++++++
>  scripts/dtc/version_gen.h | 2 +-
>  2 files changed, 10 insertions(+), 1 deletion(-)

Reviewed-by: Simon Glass <sjg@chromium.org>
Masahiro Yamada May 16, 2018, 1:54 a.m. UTC | #2
2018-05-13 2:13 GMT+09:00 Eugeniu Rosca <roscaeugeniu@gmail.com>:
> From: Rob Herring <robh@kernel.org>
>
> Pickup the fix for handling unresolved phandles in overlays.
>
> This adds the following commits from upstream:
>
> c1e55a5513e9 checks: fix handling of unresolved phandles for dts plugins
> f8872e29ce06 tests: Avoid 64-bit arithmetic in assembler
> 48c91c08bcfa libfdt: add stringlist functions to linker script
>
> Signed-off-by: Rob Herring <robh@kernel.org>
> [ Linux commit: e45fe7f788dd1395befe5639149ad8dacfbd94ab ]
> Signed-off-by: Eugeniu Rosca <erosca@de.adit-jv.com>
> ---
>
> v1->v2:
> * Newly pushed


Reviewed-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Eugeniu Rosca May 16, 2018, 11:51 a.m. UTC | #3
On Wed, May 16, 2018 at 10:54:04AM +0900, Masahiro Yamada wrote:
> 2018-05-13 2:13 GMT+09:00 Eugeniu Rosca <roscaeugeniu@gmail.com>:
> > From: Rob Herring <robh@kernel.org>
> >
> > Pickup the fix for handling unresolved phandles in overlays.
> >
> > This adds the following commits from upstream:
> >
> > c1e55a5513e9 checks: fix handling of unresolved phandles for dts plugins
> > f8872e29ce06 tests: Avoid 64-bit arithmetic in assembler
> > 48c91c08bcfa libfdt: add stringlist functions to linker script
> >
> > Signed-off-by: Rob Herring <robh@kernel.org>
> > [ Linux commit: e45fe7f788dd1395befe5639149ad8dacfbd94ab ]
> > Signed-off-by: Eugeniu Rosca <erosca@de.adit-jv.com>
> > ---
> >
> > v1->v2:
> > * Newly pushed
> 
> 
> Reviewed-by: Masahiro Yamada <yamada.masahiro@socionext.com>

Thanks for the recent reviews!

> 
> -- 
> Best Regards
> Masahiro Yamada

Best regards,
Eugeniu.
diff mbox series

Patch

diff --git a/scripts/dtc/checks.c b/scripts/dtc/checks.c
index 08a3a29edae3..e66138449886 100644
--- a/scripts/dtc/checks.c
+++ b/scripts/dtc/checks.c
@@ -988,6 +988,10 @@  static void check_property_phandle_args(struct check *c,
 		 * entries when each index position has a specific definition.
 		 */
 		if (phandle == 0 || phandle == -1) {
+			/* Give up if this is an overlay with external references */
+			if (dti->dtsflags & DTSF_PLUGIN)
+				break;
+
 			cellsize = 0;
 			continue;
 		}
@@ -1176,6 +1180,11 @@  static void check_interrupts_property(struct check *c,
 		prop = get_property(parent, "interrupt-parent");
 		if (prop) {
 			phandle = propval_cell(prop);
+			/* Give up if this is an overlay with external references */
+			if ((phandle == 0 || phandle == -1) &&
+			    (dti->dtsflags & DTSF_PLUGIN))
+					return;
+
 			irq_node = get_node_by_phandle(root, phandle);
 			if (!irq_node) {
 				FAIL(c, dti, "Bad interrupt-parent phandle for %s",
diff --git a/scripts/dtc/version_gen.h b/scripts/dtc/version_gen.h
index d88393cab14a..6a4e84798966 100644
--- a/scripts/dtc/version_gen.h
+++ b/scripts/dtc/version_gen.h
@@ -1 +1 @@ 
-#define DTC_VERSION "DTC 1.4.5-gb1a60033"
+#define DTC_VERSION "DTC 1.4.5-gc1e55a55"