Re: [PATCH] checks: Warn about missing #address-cells for interrupt parents

David Gibson <[email protected]>
Newsgroups org.kernel.vger.devicetree-compiler
Message-ID <Z2JYlybB2TditOhj@zatzit>
On Mon, Dec 16, 2024 at 01:37:01PM -0600, Rob Herring wrote:
> On Fri, Dec 13, 2024 at 8:14 AM Thierry Reding <[email protected]> wrote:
> >
> > From: Thierry Reding <[email protected]>
> >
> > The device tree specification (v0.4) suggests that #address-cells is
> > mandatory for interrupt parent nodes. If this property is missing, Linux
> > will default to the value of 0.
> >
> > A number of device tree files rely on Linux' fallback and don't specify
> > an explicit #address-cells as suggested by the specification. This can
> > cause issues when these device trees are passed to software with a more
> > pedantic interpretation of the DT spec.
> >
> > Add a warning when this case is detected so that device tree files can
> > be fixed.
> >
> > Reported-by: Brad Griffis <[email protected]>
> > Signed-off-by: Thierry Reding <[email protected]>
> > ---
> > Applying this to Linux' copy reports on the order of 1300 issues that
> > originate from 29 .dtsi files. If this proposal is acceptable/useful, I
> > volunteer to patch those up so we don't get spammed by them.
> 
> I could have sworn I did a check for this, but it seems not.
> 
> > ---
> >  checks.c | 4 ++++
> >  1 file changed, 4 insertions(+)
> 
> Reviewed-by: Rob Herring (Arm) <[email protected]>

Makes sense to me.  Applied.

-- 
David Gibson (he or they)	| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you, not the other way
				| around.
http://www.ozlabs.org/~dgibson
signature.asc (application/pgp-signature, 833 B)
-----BEGIN PGP SIGNATURE-----

iQIzBAEBCAAdFiEEO+dNsU4E3yXUXRK2zQJF27ox2GcFAmdiWJYACgkQzQJF27ox
2Gd7VA/+IicOGmnzPFLo1kezPzaLvmN8+mP0qA9/BkGWI5kbusgp3B52WL920sEq
EU99gHAH3/BukjL8/Kg1f4dHEey96OMA0sYkMxZSDCKcwRbZnPGF7QOoOmn73JJV
YHSyvRSy7S6gsRZDYj+XmFY3Zr2hJVhXCHK5XvahfM8qYFWfMKei2a2tGiwsH3hB
uD8+n8Nl2XvOnxXfijbwkcnUDcaymfrnw9czmZ3na1kZCmq3wco08Mv59yqnSsPM
cXD/fA7xnKEENTHVBGLuMjJqeo4ENiqWDln2DxXYw1Ysc26z6MGzva1+0CyIkx/Y
2Ghd1Xo+1rDjxEuuFtPasBZ/5ETzWxl0bsNiGGKd1hVSSMxg6Q1eTdxU2C6rSsBN
Zd7Sv65Oqz51ZdiZdnWRTmBzVo23pEhG5LiVqmDeLUVMgZBH+J9wjEFMi23wGGMw
r2PQaSlURlI2p5Sg0X/5R81O8LPfO8neBWde8sxzsJBiFG+xZniOhkebAs1iYUqt
uxz0ENPrgxMwBfPnQDLL7TxgV2CEA3z3Ac8OZtG1cxWa3Ua5S+BIUyCNumsLoQeD
+JS9g6uSPpRH2WD7n3sECkrrR+xepVdM3kqLX3+BDMtABl1QMjVcLyL9PB4YcOv1
1zXAnLKo4k1CPS8SJQe0OMsPJBlKF8g881Bxo7A5+W5YJhWmtLw=
=4/ez
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.