devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: <Conor.Dooley@microchip.com>
To: <Niklas.Cassel@wdc.com>
Cc: <airlied@linux.ie>, <daniel@ffwll.ch>, <robh+dt@kernel.org>,
	<krzysztof.kozlowski+dt@linaro.org>, <thierry.reding@gmail.com>,
	<sam@ravnborg.org>, <Eugeniy.Paltsev@synopsys.com>,
	<vkoul@kernel.org>, <lgirdwood@gmail.com>, <broonie@kernel.org>,
	<fancer.lancer@gmail.com>, <daniel.lezcano@linaro.org>,
	<palmer@dabbelt.com>, <palmer@rivosinc.com>, <tglx@linutronix.de>,
	<paul.walmsley@sifive.com>, <aou@eecs.berkeley.edu>,
	<Conor.Dooley@microchip.com>, <masahiroy@kernel.org>,
	<damien.lemoal@opensource.wdc.com>, <geert@linux-m68k.org>,
	<dillon.minfei@gmail.com>, <joabreu@synopsys.com>,
	<dri-devel@lists.freedesktop.org>, <devicetree@vger.kernel.org>,
	<linux-kernel@vger.kernel.org>, <dmaengine@vger.kernel.org>,
	<alsa-devel@alsa-project.org>, <linux-spi@vger.kernel.org>,
	<linux-riscv@lists.infradead.org>
Subject: Re: [PATCH v3 13/15] riscv: dts: canaan: fix bus {ranges,reg} warnings
Date: Thu, 30 Jun 2022 17:02:24 +0000	[thread overview]
Message-ID: <3fec7542-c5f9-8812-732a-d624b0506ca9@microchip.com> (raw)
In-Reply-To: <Yr3UKQ/772oFyvc6@x1-carbon>



On 30/06/2022 17:49, Niklas Cassel wrote:
> On Wed, Jun 29, 2022 at 07:43:42PM +0100, Conor Dooley wrote:
>> From: Conor Dooley <conor.dooley@microchip.com>
>>
>> The k210 devicetrees warn about missing/empty reg and/or ranges
>> properties:
>> arch/riscv/boot/dts/canaan/k210.dtsi:408.22-460.5: Warning (unit_address_vs_reg): /soc/bus@52000000: node has a unit name, but no reg or ranges property
>> arch/riscv/boot/dts/canaan/k210.dtsi:352.22-406.5: Warning (simple_bus_reg): /soc/bus@50400000: missing or empty reg/ranges property
>>
>> Add reg and ranges properties that naively cap the buses after the
>> allocation of their last devices.
>>
>> Signed-off-by: Conor Dooley <conor.dooley@microchip.com>
>> ---
>>  arch/riscv/boot/dts/canaan/k210.dtsi | 9 ++++++---
>>  1 file changed, 6 insertions(+), 3 deletions(-)
>>
>> diff --git a/arch/riscv/boot/dts/canaan/k210.dtsi b/arch/riscv/boot/dts/canaan/k210.dtsi
>> index 948dc235e39d..6a34dc4f3e51 100644
>> --- a/arch/riscv/boot/dts/canaan/k210.dtsi
>> +++ b/arch/riscv/boot/dts/canaan/k210.dtsi
>> @@ -163,7 +163,8 @@ apb0: bus@50200000 {
>>  			#address-cells = <1>;
>>  			#size-cells = <1>;
>>  			compatible = "simple-pm-bus";
>> -			ranges;
>> +			regs = <0x50200000 0x200000>;
>> +			ranges = <0x50200000 0x50200000 0x200000>;
> 
> This looks wrong.
> 
> The property is called "reg" not "regs".

Yeah...

> 
> And I don't think that you should provide "reg" at all,
> simply supplying "ranges" should be sufficient, no?

I don't recall why I put the regs in, I'll drop it if
possible & respond if I can't.
IIRC, it did actually complain.

> 
> 
> Kind regards,
> Niklas
> 
>>  			clocks = <&sysclk K210_CLK_APB0>;
>>  
>>  			gpio1: gpio@50200000 {
>> @@ -382,7 +383,8 @@ apb1: bus@50400000 {
>>  			#address-cells = <1>;
>>  			#size-cells = <1>;
>>  			compatible = "simple-pm-bus";
>> -			ranges;
>> +			regs = <0x50400000 0x40100>;
>> +			ranges = <0x50400000 0x50400000 0x40100>;
>>  			clocks = <&sysclk K210_CLK_APB1>;
>>  
>>  			wdt0: watchdog@50400000 {
>> @@ -437,7 +439,8 @@ apb2: bus@52000000 {
>>  			#address-cells = <1>;
>>  			#size-cells = <1>;
>>  			compatible = "simple-pm-bus";
>> -			ranges;
>> +			regs = <0x52000000 0x2000200>;
>> +			ranges = <0x52000000 0x52000000 0x2000200>;
>>  			clocks = <&sysclk K210_CLK_APB2>;
>>  
>>  			spi0: spi@52000000 {
>> -- 
>> 2.36.1

  reply	other threads:[~2022-06-30 17:02 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-29 18:43 [PATCH v3 00/15] Canaan devicetree fixes Conor Dooley
2022-06-29 18:43 ` [PATCH v3 01/15] dt-bindings: display: convert ilitek,ili9341.txt to dt-schema Conor Dooley
2022-06-29 18:43 ` [PATCH v3 02/15] dt-bindings: display: ili9341: document canaan kd233's lcd Conor Dooley
2022-07-01 19:38   ` Rob Herring
2022-06-29 18:43 ` [PATCH v3 03/15] ASoC: dt-bindings: convert designware-i2s to dt-schema Conor Dooley
2022-07-01 19:39   ` Rob Herring
2022-06-29 18:43 ` [PATCH v3 04/15] spi: dt-bindings: dw-apb-ssi: update spi-{r,t}x-bus-width Conor Dooley
2022-06-30 16:57   ` Rob Herring
2022-06-30 21:43   ` Serge Semin
2022-06-29 18:43 ` [PATCH v3 05/15] dt-bindings: dma: dw-axi-dmac: extend the number of interrupts Conor Dooley
2022-06-30 21:55   ` Serge Semin
2022-06-30 23:12     ` Conor.Dooley
2022-07-01 19:41       ` Rob Herring
2022-06-29 18:43 ` [PATCH v3 06/15] dt-bindings: memory-controllers: add canaan k210 sram controller Conor Dooley
2022-06-29 18:43 ` [PATCH v3 07/15] riscv: dts: canaan: fix the k210's memory node Conor Dooley
2022-06-29 18:43 ` [PATCH v3 08/15] riscv: dts: canaan: fix the k210's timer nodes Conor Dooley
2022-06-30 21:51   ` Serge Semin
2022-06-29 18:43 ` [PATCH v3 09/15] riscv: dts: canaan: fix mmc node names Conor Dooley
2022-06-29 18:43 ` [PATCH v3 10/15] riscv: dts: canaan: fix kd233 display spi frequency Conor Dooley
2022-06-29 18:43 ` [PATCH v3 11/15] riscv: dts: canaan: use custom compatible for k210 i2s Conor Dooley
2022-06-29 18:43 ` [PATCH v3 12/15] riscv: dts: canaan: remove spi-max-frequency from controllers Conor Dooley
2022-06-29 18:43 ` [PATCH v3 13/15] riscv: dts: canaan: fix bus {ranges,reg} warnings Conor Dooley
2022-06-30 16:49   ` Niklas Cassel
2022-06-30 17:02     ` Conor.Dooley [this message]
2022-06-30 19:31       ` Conor.Dooley
2022-06-29 18:43 ` [PATCH v3 14/15] riscv: dts: canaan: add specific compatible for kd233's LCD Conor Dooley
2022-06-29 18:43 ` [PATCH v3 15/15] riscv: dts: canaan: build all devicetress if SOC_CANAAN Conor Dooley
2022-06-30 16:28 ` [PATCH v3 00/15] Canaan devicetree fixes Niklas Cassel
2022-06-30 16:38   ` Conor.Dooley
2022-06-30 17:53   ` Sudeep Holla
2022-06-30 18:01     ` Conor.Dooley
2022-06-30 18:21       ` Sudeep Holla
2022-06-30 18:30         ` Conor.Dooley
2022-06-30 21:16     ` Damien Le Moal
2022-07-01 11:14       ` Sudeep Holla
2022-07-01 10:31 ` (subset) " Mark Brown

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3fec7542-c5f9-8812-732a-d624b0506ca9@microchip.com \
    --to=conor.dooley@microchip.com \
    --cc=Eugeniy.Paltsev@synopsys.com \
    --cc=Niklas.Cassel@wdc.com \
    --cc=airlied@linux.ie \
    --cc=alsa-devel@alsa-project.org \
    --cc=aou@eecs.berkeley.edu \
    --cc=broonie@kernel.org \
    --cc=damien.lemoal@opensource.wdc.com \
    --cc=daniel.lezcano@linaro.org \
    --cc=daniel@ffwll.ch \
    --cc=devicetree@vger.kernel.org \
    --cc=dillon.minfei@gmail.com \
    --cc=dmaengine@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=fancer.lancer@gmail.com \
    --cc=geert@linux-m68k.org \
    --cc=joabreu@synopsys.com \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-riscv@lists.infradead.org \
    --cc=linux-spi@vger.kernel.org \
    --cc=masahiroy@kernel.org \
    --cc=palmer@dabbelt.com \
    --cc=palmer@rivosinc.com \
    --cc=paul.walmsley@sifive.com \
    --cc=robh+dt@kernel.org \
    --cc=sam@ravnborg.org \
    --cc=tglx@linutronix.de \
    --cc=thierry.reding@gmail.com \
    --cc=vkoul@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).