* [PATCH] kbuild: Don't report disabled nodes with duplicate addresses
@ 2022-02-10 6:51 Vinod Koul
2022-02-10 14:39 ` Rob Herring
0 siblings, 1 reply; 3+ messages in thread
From: Vinod Koul @ 2022-02-10 6:51 UTC (permalink / raw)
To: Rob Herring, Masahiro Yamada
Cc: linux-arm-msm, Bjorn Andersson, Vinod Koul, Michal Marek,
Nick Desaulniers, linux-kbuild, linux-kernel
Duplicated unit address is okay if we have only one such node enabled.
So, remove '-Wno-unique_unit_address' from DTC_FLAGS.
This helps in reducing warnings in qcom dts from
6483 unique_unit_address
1108 simple_bus_reg
764 avoid_unnecessary_addr_size
712 unit_address_vs_reg
120 graph_child_address
32 unique_unit_address_if_enabled
after this patch:
277 simple_bus_reg
191 avoid_unnecessary_addr_size
178 unit_address_vs_reg
32 unique_unit_address_if_enabled
30 graph_child_address
which would help people focus on the actual warnings and fix them.
Suggested-by: Rob Herring <robh@kernel.org>
Signed-off-by: Vinod Koul <vkoul@kernel.org>
---
scripts/Makefile.lib | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
index 79be57fdd32a..7e4f6671d950 100644
--- a/scripts/Makefile.lib
+++ b/scripts/Makefile.lib
@@ -299,7 +299,8 @@ quiet_cmd_gzip = GZIP $@
# DTC
# ---------------------------------------------------------------------------
DTC ?= $(objtree)/scripts/dtc/dtc
-DTC_FLAGS += -Wno-interrupt_provider
+DTC_FLAGS += -Wno-interrupt_provider \
+ -Wno-unique_unit_address
# Disable noisy checks by default
ifeq ($(findstring 1,$(KBUILD_EXTRA_WARN)),)
@@ -307,8 +308,9 @@ DTC_FLAGS += -Wno-unit_address_vs_reg \
-Wno-avoid_unnecessary_addr_size \
-Wno-alias_paths \
-Wno-graph_child_address \
- -Wno-simple_bus_reg \
- -Wno-unique_unit_address
+ -Wno-simple_bus_reg
+else
+DTC_FLAGS += -Wunique_unit_address_if_enabled
endif
ifneq ($(findstring 2,$(KBUILD_EXTRA_WARN)),)
--
2.31.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] kbuild: Don't report disabled nodes with duplicate addresses
2022-02-10 6:51 [PATCH] kbuild: Don't report disabled nodes with duplicate addresses Vinod Koul
@ 2022-02-10 14:39 ` Rob Herring
2022-03-28 7:12 ` Vinod Koul
0 siblings, 1 reply; 3+ messages in thread
From: Rob Herring @ 2022-02-10 14:39 UTC (permalink / raw)
To: Vinod Koul
Cc: Masahiro Yamada, linux-arm-msm, Bjorn Andersson, Michal Marek,
Nick Desaulniers, Linux Kbuild mailing list, linux-kernel
On Thu, Feb 10, 2022 at 12:51 AM Vinod Koul <vkoul@kernel.org> wrote:
>
> Duplicated unit address is okay if we have only one such node enabled.
> So, remove '-Wno-unique_unit_address' from DTC_FLAGS.
>
> This helps in reducing warnings in qcom dts from
>
> 6483 unique_unit_address
> 1108 simple_bus_reg
> 764 avoid_unnecessary_addr_size
> 712 unit_address_vs_reg
> 120 graph_child_address
> 32 unique_unit_address_if_enabled
>
> after this patch:
> 277 simple_bus_reg
> 191 avoid_unnecessary_addr_size
> 178 unit_address_vs_reg
> 32 unique_unit_address_if_enabled
> 30 graph_child_address
I'm confused how unique_unit_address changes the count for others?
>
> which would help people focus on the actual warnings and fix them.
Hopefully you do a 'sort -u' on the warnings to dedup them...
>
> Suggested-by: Rob Herring <robh@kernel.org>
> Signed-off-by: Vinod Koul <vkoul@kernel.org>
> ---
> scripts/Makefile.lib | 8 +++++---
> 1 file changed, 5 insertions(+), 3 deletions(-)
>
> diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
> index 79be57fdd32a..7e4f6671d950 100644
> --- a/scripts/Makefile.lib
> +++ b/scripts/Makefile.lib
> @@ -299,7 +299,8 @@ quiet_cmd_gzip = GZIP $@
> # DTC
> # ---------------------------------------------------------------------------
> DTC ?= $(objtree)/scripts/dtc/dtc
> -DTC_FLAGS += -Wno-interrupt_provider
> +DTC_FLAGS += -Wno-interrupt_provider \
> + -Wno-unique_unit_address
>
> # Disable noisy checks by default
> ifeq ($(findstring 1,$(KBUILD_EXTRA_WARN)),)
> @@ -307,8 +308,9 @@ DTC_FLAGS += -Wno-unit_address_vs_reg \
> -Wno-avoid_unnecessary_addr_size \
> -Wno-alias_paths \
> -Wno-graph_child_address \
> - -Wno-simple_bus_reg \
> - -Wno-unique_unit_address
> + -Wno-simple_bus_reg
> +else
> +DTC_FLAGS += -Wunique_unit_address_if_enabled
> endif
>
> ifneq ($(findstring 2,$(KBUILD_EXTRA_WARN)),)
> --
> 2.31.1
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] kbuild: Don't report disabled nodes with duplicate addresses
2022-02-10 14:39 ` Rob Herring
@ 2022-03-28 7:12 ` Vinod Koul
0 siblings, 0 replies; 3+ messages in thread
From: Vinod Koul @ 2022-03-28 7:12 UTC (permalink / raw)
To: Rob Herring
Cc: Masahiro Yamada, linux-arm-msm, Bjorn Andersson, Michal Marek,
Nick Desaulniers, Linux Kbuild mailing list, linux-kernel
Hi Rob,
On 10-02-22, 08:39, Rob Herring wrote:
> On Thu, Feb 10, 2022 at 12:51 AM Vinod Koul <vkoul@kernel.org> wrote:
> >
> > Duplicated unit address is okay if we have only one such node enabled.
> > So, remove '-Wno-unique_unit_address' from DTC_FLAGS.
> >
> > This helps in reducing warnings in qcom dts from
> >
> > 6483 unique_unit_address
> > 1108 simple_bus_reg
> > 764 avoid_unnecessary_addr_size
> > 712 unit_address_vs_reg
> > 120 graph_child_address
> > 32 unique_unit_address_if_enabled
> >
> > after this patch:
> > 277 simple_bus_reg
> > 191 avoid_unnecessary_addr_size
> > 178 unit_address_vs_reg
> > 32 unique_unit_address_if_enabled
> > 30 graph_child_address
>
> I'm confused how unique_unit_address changes the count for others?
It does, I reran this and comparing before and after logs and looking
at the diff, few other warnings seems to disappear as well:
For example these are not shown now after applying the patch and they
seem legit to me
arch/arm64/boot/dts/qcom/ipq6018.dtsi:181.11-764.4: Warning (unit_address_vs_reg): /soc: node has a reg or ranges property, but no unit name
arch/arm64/boot/dts/qcom/ipq6018.dtsi:188.20-193.5: Warning (simple_bus_reg): /soc/qrng@e1000: simple-bus unit address format error, expected "e3000"
arch/arm64/boot/dts/qcom/ipq6018.dtsi:519.9-525.5: Warning (simple_bus_reg): /soc/timer: missing or empty reg/ranges property
arch/arm64/boot/dts/qcom/ipq6018.dtsi:646.22-679.5: Warning (simple_bus_reg): /soc/usb2@7000000: simple-bus unit address format error, expected "70f8800"
also defined at arch/arm64/boot/dts/qcom/ipq6018-cp01-c1.dts:86.7-88.3
arch/arm64/boot/dts/qcom/ipq6018.dtsi:723.22-763.5: Warning (simple_bus_reg): /soc/usb3@8A00000: simple-bus unit address format error, expected "8af8800"
arch/arm64/boot/dts/qcom/ipq6018.dtsi:300.22-313.5: Warning (unique_unit_address): /soc/spi@78b6000: duplicate unit-address (also used in node /soc/i2c@78b6000)
arch/arm64/boot/dts/qcom/msm8996.dtsi:427.18-436.5: Warning (unit_address_vs_reg): /reserved-memory/rmtfs@86700000: node has a unit name, but no reg or ranges property
arch/arm64/boot/dts/qcom/msm8996.dtsi:576.11-3188.4: Warning (unit_address_vs_reg): /soc: node has a reg or ranges property, but no unit name
arch/arm64/boot/dts/qcom/msm8996.dtsi:1569.11-1730.5: Warning (unit_address_vs_reg): /soc/agnoc@0: node has a unit name, but no reg or ranges property
arch/arm64/boot/dts/qcom/msm8996.dtsi:2994.24-2997.7: Warning (unit_address_vs_reg): /soc/slim@91c0000/ngd@1/tas-ifd: node has a reg or ranges property, but no unit name
arch/arm64/boot/dts/qcom/msm8996.dtsi:3063.13-3066.8: Warning (unit_address_vs_reg): /soc/remoteproc@9300000/smd-edge/apr/q6core: node has a reg or ranges property, but no unit name
arch/arm64/boot/dts/qcom/msm8996.dtsi:3068.19-3080.8: Warning (unit_address_vs_reg): /soc/remoteproc@9300000/smd-edge/apr/q6afe: node has a reg or ranges property, but no unit name
arch/arm64/boot/dts/qcom/msm8996.dtsi:3082.19-3092.8: Warning (unit_address_vs_reg): /soc/remoteproc@9300000/smd-edge/apr/q6asm: node has a reg or ranges property, but no unit name
arch/arm64/boot/dts/qcom/msm8996.dtsi:3094.19-3101.8: Warning (unit_address_vs_reg): /soc/remoteproc@9300000/smd-edge/apr/q6adm: node has a reg or ranges property, but no unit name
arch/arm64/boot/dts/qcom/msm8996.dtsi:1569.11-1730.5: Warning (simple_bus_reg): /soc/agnoc@0: missing or empty reg/ranges property
arch/arm64/boot/dts/qcom/msm8996.dtsi:1810.23-1943.5: Warning (simple_bus_reg): /soc/camss@a00000: simple-bus unit address format error, expected "a34000"
arch/arm64/boot/dts/qcom/msm8996.dtsi:831.21-878.6: Warning (avoid_unnecessary_addr_size): /soc/mdss@900000/dsi@994000: unnecessary #address-cells/#size-cells without "ranges" or child "reg" property
arch/arm64/boot/dts/qcom/pm8994.dtsi:132.9-141.4: Warning (avoid_unnecessary_addr_size): /soc/spmi@400f000/pmic@1: unnecessary #address-cells/#size-cells without "ranges" or child "reg" property
arch/arm64/boot/dts/qcom/msm8996.dtsi:3046.13-3104.6: Warning (avoid_unnecessary_addr_size): /soc/remoteproc@9300000/smd-edge: unnecessary #address-cells/#size-cells without "ranges" or child "reg" property
arch/arm64/boot/dts/qcom/msm8996.dtsi:2901.27-2916.5: Warning (unique_unit_address): /soc/i2c@75ba000: duplicate unit-address (also used in node /soc/spi@75ba000)
arch/arm64/boot/dts/qcom/msm8996.dtsi:927.11-937.7: Warning (graph_child_address): /soc/mdss@900000/hdmi-tx@9a0000/ports: graph node has single child node 'port@0', #address-cells/#size-cells are not necessary
arch/arm64/boot/dts/qcom/ipq8074.dtsi:104.11-849.4: Warning (unit_address_vs_reg): /soc: node has a reg or ranges property, but no unit name
arch/arm64/boot/dts/qcom/ipq8074.dtsi:651.9-657.5: Warning (simple_bus_reg): /soc/timer: missing or empty reg/ranges property
Thanks
>
> >
> > which would help people focus on the actual warnings and fix them.
>
> Hopefully you do a 'sort -u' on the warnings to dedup them...
>
> >
> > Suggested-by: Rob Herring <robh@kernel.org>
> > Signed-off-by: Vinod Koul <vkoul@kernel.org>
> > ---
> > scripts/Makefile.lib | 8 +++++---
> > 1 file changed, 5 insertions(+), 3 deletions(-)
> >
> > diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
> > index 79be57fdd32a..7e4f6671d950 100644
> > --- a/scripts/Makefile.lib
> > +++ b/scripts/Makefile.lib
> > @@ -299,7 +299,8 @@ quiet_cmd_gzip = GZIP $@
> > # DTC
> > # ---------------------------------------------------------------------------
> > DTC ?= $(objtree)/scripts/dtc/dtc
> > -DTC_FLAGS += -Wno-interrupt_provider
> > +DTC_FLAGS += -Wno-interrupt_provider \
> > + -Wno-unique_unit_address
> >
> > # Disable noisy checks by default
> > ifeq ($(findstring 1,$(KBUILD_EXTRA_WARN)),)
> > @@ -307,8 +308,9 @@ DTC_FLAGS += -Wno-unit_address_vs_reg \
> > -Wno-avoid_unnecessary_addr_size \
> > -Wno-alias_paths \
> > -Wno-graph_child_address \
> > - -Wno-simple_bus_reg \
> > - -Wno-unique_unit_address
> > + -Wno-simple_bus_reg
> > +else
> > +DTC_FLAGS += -Wunique_unit_address_if_enabled
> > endif
> >
> > ifneq ($(findstring 2,$(KBUILD_EXTRA_WARN)),)
> > --
> > 2.31.1
> >
--
~Vinod
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-03-28 7:12 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-02-10 6:51 [PATCH] kbuild: Don't report disabled nodes with duplicate addresses Vinod Koul
2022-02-10 14:39 ` Rob Herring
2022-03-28 7:12 ` Vinod Koul
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.