diff mbox series

[08/11] MIPS: mobileye: eyeq5: add OLB syscon node

Message ID 20240410-mbly-olb-v1-8-335e496d7be3@bootlin.com (mailing list archive)
State Superseded
Headers show
Series Add Mobileye EyeQ system controller support (clk, reset, pinctrl) | expand

Commit Message

Théo Lebrun April 10, 2024, 5:12 p.m. UTC
The OLB ("Other Logic Block") is a syscon region hosting clock, reset
and pin controllers. It contains registers such as I2C speed mode that
need to be accessible by other nodes.

Signed-off-by: Théo Lebrun <theo.lebrun@bootlin.com>
---
 arch/mips/boot/dts/mobileye/eyeq5.dtsi | 8 ++++++++
 1 file changed, 8 insertions(+)

Comments

Krzysztof Kozlowski April 11, 2024, 6:15 a.m. UTC | #1
On 10/04/2024 19:12, Théo Lebrun wrote:
> The OLB ("Other Logic Block") is a syscon region hosting clock, reset
> and pin controllers. It contains registers such as I2C speed mode that
> need to be accessible by other nodes.
> 
> Signed-off-by: Théo Lebrun <theo.lebrun@bootlin.com>
> ---
>  arch/mips/boot/dts/mobileye/eyeq5.dtsi | 8 ++++++++
>  1 file changed, 8 insertions(+)
> 
> diff --git a/arch/mips/boot/dts/mobileye/eyeq5.dtsi b/arch/mips/boot/dts/mobileye/eyeq5.dtsi
> index 6cc5980e2fa1..e82d2a57f6da 100644
> --- a/arch/mips/boot/dts/mobileye/eyeq5.dtsi
> +++ b/arch/mips/boot/dts/mobileye/eyeq5.dtsi
> @@ -100,6 +100,14 @@ uart2: serial@a00000 {
>  			clock-names = "uartclk", "apb_pclk";
>  		};
>  
> +		olb: system-controller@e00000 {
> +			compatible = "mobileye,eyeq5-olb", "syscon", "simple-mfd";
> +			reg = <0 0xe00000 0x0 0x400>;
> +			ranges = <0x0 0x0 0xe00000 0x400>;
> +			#address-cells = <1>;
> +			#size-cells = <1>;

Do not add incomplete node. ranges, address/size-cells are incorrect in
this context and you will have warnings.

Add complete node, so these properties make sense.

Best regards,
Krzysztof
Théo Lebrun April 11, 2024, 2:34 p.m. UTC | #2
Hello,

On Thu Apr 11, 2024 at 8:15 AM CEST, Krzysztof Kozlowski wrote:
> On 10/04/2024 19:12, Théo Lebrun wrote:
> > The OLB ("Other Logic Block") is a syscon region hosting clock, reset
> > and pin controllers. It contains registers such as I2C speed mode that
> > need to be accessible by other nodes.
> > 
> > Signed-off-by: Théo Lebrun <theo.lebrun@bootlin.com>
> > ---
> >  arch/mips/boot/dts/mobileye/eyeq5.dtsi | 8 ++++++++
> >  1 file changed, 8 insertions(+)
> > 
> > diff --git a/arch/mips/boot/dts/mobileye/eyeq5.dtsi b/arch/mips/boot/dts/mobileye/eyeq5.dtsi
> > index 6cc5980e2fa1..e82d2a57f6da 100644
> > --- a/arch/mips/boot/dts/mobileye/eyeq5.dtsi
> > +++ b/arch/mips/boot/dts/mobileye/eyeq5.dtsi
> > @@ -100,6 +100,14 @@ uart2: serial@a00000 {
> >  			clock-names = "uartclk", "apb_pclk";
> >  		};
> >  
> > +		olb: system-controller@e00000 {
> > +			compatible = "mobileye,eyeq5-olb", "syscon", "simple-mfd";
> > +			reg = <0 0xe00000 0x0 0x400>;
> > +			ranges = <0x0 0x0 0xe00000 0x400>;
> > +			#address-cells = <1>;
> > +			#size-cells = <1>;
>
> Do not add incomplete node. ranges, address/size-cells are incorrect in
> this context and you will have warnings.
>
> Add complete node, so these properties make sense.

I'll squash all four commits into one. For reference, commits are:

 - MIPS: mobileye: eyeq5: add OLB syscon node
 - MIPS: mobileye: eyeq5: use OLB clocks controller node
 - MIPS: mobileye: eyeq5: add OLB reset controller node
 - MIPS: mobileye: eyeq5: add pinctrl node & pinmux function nodes

This means two things: (1) it won't be partially applicable and (2) it
will make one big commit adding pins and editing clocks.

Thanks,

--
Théo Lebrun, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
Krzysztof Kozlowski April 11, 2024, 3:07 p.m. UTC | #3
On 11/04/2024 16:34, Théo Lebrun wrote:
> Hello,
> 
> On Thu Apr 11, 2024 at 8:15 AM CEST, Krzysztof Kozlowski wrote:
>> On 10/04/2024 19:12, Théo Lebrun wrote:
>>> The OLB ("Other Logic Block") is a syscon region hosting clock, reset
>>> and pin controllers. It contains registers such as I2C speed mode that
>>> need to be accessible by other nodes.
>>>
>>> Signed-off-by: Théo Lebrun <theo.lebrun@bootlin.com>
>>> ---
>>>  arch/mips/boot/dts/mobileye/eyeq5.dtsi | 8 ++++++++
>>>  1 file changed, 8 insertions(+)
>>>
>>> diff --git a/arch/mips/boot/dts/mobileye/eyeq5.dtsi b/arch/mips/boot/dts/mobileye/eyeq5.dtsi
>>> index 6cc5980e2fa1..e82d2a57f6da 100644
>>> --- a/arch/mips/boot/dts/mobileye/eyeq5.dtsi
>>> +++ b/arch/mips/boot/dts/mobileye/eyeq5.dtsi
>>> @@ -100,6 +100,14 @@ uart2: serial@a00000 {
>>>  			clock-names = "uartclk", "apb_pclk";
>>>  		};
>>>  
>>> +		olb: system-controller@e00000 {
>>> +			compatible = "mobileye,eyeq5-olb", "syscon", "simple-mfd";
>>> +			reg = <0 0xe00000 0x0 0x400>;
>>> +			ranges = <0x0 0x0 0xe00000 0x400>;
>>> +			#address-cells = <1>;
>>> +			#size-cells = <1>;
>>
>> Do not add incomplete node. ranges, address/size-cells are incorrect in
>> this context and you will have warnings.
>>
>> Add complete node, so these properties make sense.
> 
> I'll squash all four commits into one. For reference, commits are:
> 
>  - MIPS: mobileye: eyeq5: add OLB syscon node
>  - MIPS: mobileye: eyeq5: use OLB clocks controller node
>  - MIPS: mobileye: eyeq5: add OLB reset controller node
>  - MIPS: mobileye: eyeq5: add pinctrl node & pinmux function nodes
> 
> This means two things: (1) it won't be partially applicable and (2) it

Why?

> will make one big commit adding pins and editing clocks.

It never was partially applicable. Causing warnings does not make things
partially applicable. If node is too big, although I personally do not
agree, it's quite moderate size chunk, then sure, split pinctrl groups
or pinctrl node to additional patch.

Best regards,
Krzysztof
Théo Lebrun April 17, 2024, 7:53 a.m. UTC | #4
Hello,

On Thu Apr 11, 2024 at 5:07 PM CEST, Krzysztof Kozlowski wrote:
> On 11/04/2024 16:34, Théo Lebrun wrote:
> > Hello,
> > 
> > On Thu Apr 11, 2024 at 8:15 AM CEST, Krzysztof Kozlowski wrote:
> >> On 10/04/2024 19:12, Théo Lebrun wrote:
> >>> The OLB ("Other Logic Block") is a syscon region hosting clock, reset
> >>> and pin controllers. It contains registers such as I2C speed mode that
> >>> need to be accessible by other nodes.
> >>>
> >>> Signed-off-by: Théo Lebrun <theo.lebrun@bootlin.com>
> >>> ---
> >>>  arch/mips/boot/dts/mobileye/eyeq5.dtsi | 8 ++++++++
> >>>  1 file changed, 8 insertions(+)
> >>>
> >>> diff --git a/arch/mips/boot/dts/mobileye/eyeq5.dtsi b/arch/mips/boot/dts/mobileye/eyeq5.dtsi
> >>> index 6cc5980e2fa1..e82d2a57f6da 100644
> >>> --- a/arch/mips/boot/dts/mobileye/eyeq5.dtsi
> >>> +++ b/arch/mips/boot/dts/mobileye/eyeq5.dtsi
> >>> @@ -100,6 +100,14 @@ uart2: serial@a00000 {
> >>>  			clock-names = "uartclk", "apb_pclk";
> >>>  		};
> >>>  
> >>> +		olb: system-controller@e00000 {
> >>> +			compatible = "mobileye,eyeq5-olb", "syscon", "simple-mfd";
> >>> +			reg = <0 0xe00000 0x0 0x400>;
> >>> +			ranges = <0x0 0x0 0xe00000 0x400>;
> >>> +			#address-cells = <1>;
> >>> +			#size-cells = <1>;
> >>
> >> Do not add incomplete node. ranges, address/size-cells are incorrect in
> >> this context and you will have warnings.
> >>
> >> Add complete node, so these properties make sense.
> > 
> > I'll squash all four commits into one. For reference, commits are:
> > 
> >  - MIPS: mobileye: eyeq5: add OLB syscon node
> >  - MIPS: mobileye: eyeq5: use OLB clocks controller node
> >  - MIPS: mobileye: eyeq5: add OLB reset controller node
> >  - MIPS: mobileye: eyeq5: add pinctrl node & pinmux function nodes
> > 
> > This means two things: (1) it won't be partially applicable and (2) it
>
> Why?
>
> > will make one big commit adding pins and editing clocks.
>
> It never was partially applicable. Causing warnings does not make things
> partially applicable. If node is too big, although I personally do not
> agree, it's quite moderate size chunk, then sure, split pinctrl groups
> or pinctrl node to additional patch.

Thanks for feedback; it'll become a single patch as it is fine with you.

Regards,

--
Théo Lebrun, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
diff mbox series

Patch

diff --git a/arch/mips/boot/dts/mobileye/eyeq5.dtsi b/arch/mips/boot/dts/mobileye/eyeq5.dtsi
index 6cc5980e2fa1..e82d2a57f6da 100644
--- a/arch/mips/boot/dts/mobileye/eyeq5.dtsi
+++ b/arch/mips/boot/dts/mobileye/eyeq5.dtsi
@@ -100,6 +100,14 @@  uart2: serial@a00000 {
 			clock-names = "uartclk", "apb_pclk";
 		};
 
+		olb: system-controller@e00000 {
+			compatible = "mobileye,eyeq5-olb", "syscon", "simple-mfd";
+			reg = <0 0xe00000 0x0 0x400>;
+			ranges = <0x0 0x0 0xe00000 0x400>;
+			#address-cells = <1>;
+			#size-cells = <1>;
+		};
+
 		gic: interrupt-controller@140000 {
 			compatible = "mti,gic";
 			reg = <0x0 0x140000 0x0 0x20000>;