diff mbox series

[v3,1/3] dt-bindings: can: nxp,sja1000: Document RZ/N1 power-domains support

Message ID 20220830164518.1381632-2-biju.das.jz@bp.renesas.com
State Changes Requested, archived
Headers show
Series Add RZ/N1 CAN support | expand

Checks

Context Check Description
robh/checkpatch success
robh/patch-applied success
robh/dtbs-check warning build log
robh/dt-meta-schema success

Commit Message

Biju Das Aug. 30, 2022, 4:45 p.m. UTC
Document RZ/N1 power-domains support. Also update the example with
power-domains property.

Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>
---
v3:
 * Documented power-domains support.
---
 Documentation/devicetree/bindings/net/can/nxp,sja1000.yaml | 5 +++++
 1 file changed, 5 insertions(+)

Comments

Krzysztof Kozlowski Aug. 30, 2022, 5:31 p.m. UTC | #1
On 30/08/2022 19:45, Biju Das wrote:
> Document RZ/N1 power-domains support. Also update the example with
> power-domains property.
> 
> Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>
> ---
> v3:
>  * Documented power-domains support.

You made them required, so it would be nice to see reason in such
change. The commit msg says only what you did, but not why you did it.

Best regards,
Krzysztof
Biju Das Aug. 30, 2022, 5:47 p.m. UTC | #2
Hi Krzysztof Kozlowski,

Thanks for the feedback.

> Subject: Re: [PATCH v3 1/3] dt-bindings: can: nxp,sja1000: Document
> RZ/N1 power-domains support
> 
> On 30/08/2022 19:45, Biju Das wrote:
> > Document RZ/N1 power-domains support. Also update the example with
> > power-domains property.
> >
> > Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>
> > ---
> > v3:
> >  * Documented power-domains support.
> 
> You made them required, so it would be nice to see reason in such
> change. The commit msg says only what you did, but not why you did it.

It is simple. As you see from [1] and [2] power-domains are enabled by default in RZ/N1 SoC.
So there is nothing prevent us to document this property for all IP's present in
RZ/N1 SoC.

[1]https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/drivers/clk/renesas/r9a06g032-clocks.c?h=v6.0-rc3&id=aad03a66f902e18bab612870261bde647fdbda2c

[2] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/drivers/soc/renesas?h=v6.0-rc3&id=14f11da778ff642142e9be18814815754c82d6c5

Cheers,
Biju
Krzysztof Kozlowski Aug. 30, 2022, 7:03 p.m. UTC | #3
On 30/08/2022 20:47, Biju Das wrote:
> Hi Krzysztof Kozlowski,
> 
> Thanks for the feedback.
> 
>> Subject: Re: [PATCH v3 1/3] dt-bindings: can: nxp,sja1000: Document
>> RZ/N1 power-domains support
>>
>> On 30/08/2022 19:45, Biju Das wrote:
>>> Document RZ/N1 power-domains support. Also update the example with
>>> power-domains property.
>>>
>>> Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>
>>> ---
>>> v3:
>>>  * Documented power-domains support.
>>
>> You made them required, so it would be nice to see reason in such
>> change. The commit msg says only what you did, but not why you did it.
> 
> It is simple. As you see from [1] and [2] power-domains are enabled by default in RZ/N1 SoC.
> So there is nothing prevent us to document this property for all IP's present in
> RZ/N1 SoC.

Any explanation I expect to see in commit msg.

Anyway you referred to Linux drivers, which is not actually a reason.
What if some device is not in a power domain?

Best regards,
Krzysztof
Geert Uytterhoeven Sept. 1, 2022, 10:22 a.m. UTC | #4
On Tue, Aug 30, 2022 at 6:45 PM Biju Das <biju.das.jz@bp.renesas.com> wrote:
> Document RZ/N1 power-domains support. Also update the example with
> power-domains property.
>
> Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>
> ---
> v3:
>  * Documented power-domains support.

Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds
Geert Uytterhoeven Sept. 1, 2022, 10:25 a.m. UTC | #5
Hi Krzysztof,

On Tue, Aug 30, 2022 at 9:03 PM Krzysztof Kozlowski
<krzysztof.kozlowski@linaro.org> wrote:
> On 30/08/2022 20:47, Biju Das wrote:
> >> Subject: Re: [PATCH v3 1/3] dt-bindings: can: nxp,sja1000: Document
> >> RZ/N1 power-domains support
> >>
> >> On 30/08/2022 19:45, Biju Das wrote:
> >>> Document RZ/N1 power-domains support. Also update the example with
> >>> power-domains property.
> >>>
> >>> Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>
> >>> ---
> >>> v3:
> >>>  * Documented power-domains support.
> >>
> >> You made them required, so it would be nice to see reason in such
> >> change. The commit msg says only what you did, but not why you did it.
> >
> > It is simple. As you see from [1] and [2] power-domains are enabled by default in RZ/N1 SoC.
> > So there is nothing prevent us to document this property for all IP's present in
> > RZ/N1 SoC.
>
> Any explanation I expect to see in commit msg.
>
> Anyway you referred to Linux drivers, which is not actually a reason.
> What if some device is not in a power domain?

DT describes hardware, not software policy.

"power domains" are a property of the hardware.
I.e. this device (like most other devices on the SoC) is power-managed
through the system-controller.

Whether software does that by explicitly managing the clocks, or by
having a PM Domains driver is a software detail.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/net/can/nxp,sja1000.yaml b/Documentation/devicetree/bindings/net/can/nxp,sja1000.yaml
index b1327c5b86cf..5b588726853f 100644
--- a/Documentation/devicetree/bindings/net/can/nxp,sja1000.yaml
+++ b/Documentation/devicetree/bindings/net/can/nxp,sja1000.yaml
@@ -30,6 +30,9 @@  properties:
   clocks:
     maxItems: 1
 
+  power-domains:
+    maxItems: 1
+
   reg-io-width:
     $ref: /schemas/types.yaml#/definitions/uint32
     description: I/O register width (in bytes) implemented by this device
@@ -105,6 +108,7 @@  allOf:
     then:
       required:
         - clocks
+        - power-domains
 
 unevaluatedProperties: false
 
@@ -129,4 +133,5 @@  examples:
         reg-io-width = <4>;
         interrupts = <GIC_SPI 95 IRQ_TYPE_LEVEL_HIGH>;
         clocks = <&sysctrl R9A06G032_HCLK_CAN0>;
+        power-domains = <&sysctrl>;
     };