devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ARM: dts: sun6i-a31-app4-evb1.dts: Use sunxi-common-regulators.dtsi
@ 2014-05-09  8:43 Hans de Goede
       [not found] ` <1399624987-12381-1-git-send-email-hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
  0 siblings, 1 reply; 6+ messages in thread
From: Hans de Goede @ 2014-05-09  8:43 UTC (permalink / raw)
  To: Maxime Ripard
  Cc: Boris Brezillon,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, devicetree,
	linux-sunxi-/JYPxA39Uh5TLH3MbocFFw, Hans de Goede

Signed-off-by: Hans de Goede <hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
---
 arch/arm/boot/dts/sun6i-a31-app4-evb1.dts | 8 +-------
 1 file changed, 1 insertion(+), 7 deletions(-)

diff --git a/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts b/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
index 270ab97..2bbf886 100644
--- a/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
+++ b/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
@@ -13,6 +13,7 @@
 
 /dts-v1/;
 /include/ "sun6i-a31.dtsi"
+/include/ "sunxi-common-regulators.dtsi"
 
 / {
 	model = "Allwinner A31 APP4 EVB1 Evaluation Board";
@@ -49,15 +50,8 @@
 	};
 
 	reg_usb1_vbus: usb1-vbus {
-		compatible = "regulator-fixed";
-		pinctrl-names = "default";
 		pinctrl-0 = <&usb1_vbus_pin_a>;
-		regulator-name = "usb1-vbus";
-		regulator-min-microvolt = <5000000>;
-		regulator-max-microvolt = <5000000>;
-		enable-active-high;
 		gpio = <&pio 7 27 0>;
 		status = "okay";
 	};
-
 };
-- 
1.9.0

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH] ARM: dts: sun6i-a31-app4-evb1.dts: Use sunxi-common-regulators.dtsi
       [not found] ` <1399624987-12381-1-git-send-email-hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
@ 2014-05-09  8:55   ` Boris BREZILLON
       [not found]     ` <536C97FD.3070906-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
  0 siblings, 1 reply; 6+ messages in thread
From: Boris BREZILLON @ 2014-05-09  8:55 UTC (permalink / raw)
  To: Hans de Goede, Maxime Ripard
  Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, devicetree,
	linux-sunxi-/JYPxA39Uh5TLH3MbocFFw


On 09/05/2014 10:43, Hans de Goede wrote:
> Signed-off-by: Hans de Goede <hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
> ---
>  arch/arm/boot/dts/sun6i-a31-app4-evb1.dts | 8 +-------
>  1 file changed, 1 insertion(+), 7 deletions(-)
>
> diff --git a/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts b/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
> index 270ab97..2bbf886 100644
> --- a/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
> +++ b/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
> @@ -13,6 +13,7 @@
>  
>  /dts-v1/;
>  /include/ "sun6i-a31.dtsi"
> +/include/ "sunxi-common-regulators.dtsi"
>  
>  / {
>  	model = "Allwinner A31 APP4 EVB1 Evaluation Board";
> @@ -49,15 +50,8 @@
>  	};
>  
>  	reg_usb1_vbus: usb1-vbus {
> -		compatible = "regulator-fixed";
> -		pinctrl-names = "default";
>  		pinctrl-0 = <&usb1_vbus_pin_a>;
> -		regulator-name = "usb1-vbus";
> -		regulator-min-microvolt = <5000000>;
> -		regulator-max-microvolt = <5000000>;
> -		enable-active-high;
>  		gpio = <&pio 7 27 0>;
>  		status = "okay";
>  	};

I guess we could do the same for usb1_vbus_pin_a (keep the common
definition and change the allwinner,pins property).

Apart from that,

Acked-by: Boris Brezillon <boris.brezillon-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>

Best Regards,

Boris

> -
>  };

-- 
Boris Brezillon, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Re: [PATCH] ARM: dts: sun6i-a31-app4-evb1.dts: Use sunxi-common-regulators.dtsi
       [not found]     ` <536C97FD.3070906-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
@ 2014-05-09  9:05       ` Hans de Goede
       [not found]         ` <536C9A53.2060302-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
  0 siblings, 1 reply; 6+ messages in thread
From: Hans de Goede @ 2014-05-09  9:05 UTC (permalink / raw)
  To: linux-sunxi-/JYPxA39Uh5TLH3MbocFFw, Maxime Ripard
  Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, devicetree

Hi,

On 05/09/2014 10:55 AM, Boris BREZILLON wrote:
> 
> On 09/05/2014 10:43, Hans de Goede wrote:
>> Signed-off-by: Hans de Goede <hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
>> ---
>>  arch/arm/boot/dts/sun6i-a31-app4-evb1.dts | 8 +-------
>>  1 file changed, 1 insertion(+), 7 deletions(-)
>>
>> diff --git a/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts b/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
>> index 270ab97..2bbf886 100644
>> --- a/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
>> +++ b/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
>> @@ -13,6 +13,7 @@
>>  
>>  /dts-v1/;
>>  /include/ "sun6i-a31.dtsi"
>> +/include/ "sunxi-common-regulators.dtsi"
>>  
>>  / {
>>  	model = "Allwinner A31 APP4 EVB1 Evaluation Board";
>> @@ -49,15 +50,8 @@
>>  	};
>>  
>>  	reg_usb1_vbus: usb1-vbus {
>> -		compatible = "regulator-fixed";
>> -		pinctrl-names = "default";
>>  		pinctrl-0 = <&usb1_vbus_pin_a>;
>> -		regulator-name = "usb1-vbus";
>> -		regulator-min-microvolt = <5000000>;
>> -		regulator-max-microvolt = <5000000>;
>> -		enable-active-high;
>>  		gpio = <&pio 7 27 0>;
>>  		status = "okay";
>>  	};
> 
> I guess we could do the same for usb1_vbus_pin_a (keep the common
> definition and change the allwinner,pins property).

Hmm, what we do with other boards when the pin does not match the
default is change the node name to something baord specific, ie
usb1_vbus_pin_app4_evb1

Which is why I did not remove the common bits from the pin,
I did not notice you did not use a board specific name here.

Regards,

Hans

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Re: [PATCH] ARM: dts: sun6i-a31-app4-evb1.dts: Use sunxi-common-regulators.dtsi
       [not found]         ` <536C9A53.2060302-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
@ 2014-05-09  9:32           ` Boris BREZILLON
       [not found]             ` <536CA092.50300-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
  0 siblings, 1 reply; 6+ messages in thread
From: Boris BREZILLON @ 2014-05-09  9:32 UTC (permalink / raw)
  To: Hans de Goede, linux-sunxi-/JYPxA39Uh5TLH3MbocFFw, Maxime Ripard
  Cc: devicetree, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r


On 09/05/2014 11:05, Hans de Goede wrote:
> Hi,
>
> On 05/09/2014 10:55 AM, Boris BREZILLON wrote:
>> On 09/05/2014 10:43, Hans de Goede wrote:
>>> Signed-off-by: Hans de Goede <hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
>>> ---
>>>  arch/arm/boot/dts/sun6i-a31-app4-evb1.dts | 8 +-------
>>>  1 file changed, 1 insertion(+), 7 deletions(-)
>>>
>>> diff --git a/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts b/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
>>> index 270ab97..2bbf886 100644
>>> --- a/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
>>> +++ b/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
>>> @@ -13,6 +13,7 @@
>>>  
>>>  /dts-v1/;
>>>  /include/ "sun6i-a31.dtsi"
>>> +/include/ "sunxi-common-regulators.dtsi"
>>>  
>>>  / {
>>>  	model = "Allwinner A31 APP4 EVB1 Evaluation Board";
>>> @@ -49,15 +50,8 @@
>>>  	};
>>>  
>>>  	reg_usb1_vbus: usb1-vbus {
>>> -		compatible = "regulator-fixed";
>>> -		pinctrl-names = "default";
>>>  		pinctrl-0 = <&usb1_vbus_pin_a>;
>>> -		regulator-name = "usb1-vbus";
>>> -		regulator-min-microvolt = <5000000>;
>>> -		regulator-max-microvolt = <5000000>;
>>> -		enable-active-high;
>>>  		gpio = <&pio 7 27 0>;
>>>  		status = "okay";
>>>  	};
>> I guess we could do the same for usb1_vbus_pin_a (keep the common
>> definition and change the allwinner,pins property).
> Hmm, what we do with other boards when the pin does not match the
> default is change the node name to something baord specific, ie
> usb1_vbus_pin_app4_evb1

Okay.
How did you decide which pins should be put in the default definitions
(the most used ones among available boards ?) ?
I'm not sure defining new pin states for each board is a good solution,
because you'll embed unneeded pin states in your DTB.
Anyway, this is your call :-).

> Which is why I did not remove the common bits from the pin,
> I did not notice you did not use a board specific name here.

Then I guess it should be fixed in the same series.
BTW, AFAIK the original patch adding support for the APP4 EVB1 board has
not been applied yet, so I think we can fix it send a v2 of this patch.

> Regards,
>
> Hans
>
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

-- 
Boris Brezillon, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Re: [PATCH] ARM: dts: sun6i-a31-app4-evb1.dts: Use sunxi-common-regulators.dtsi
       [not found]             ` <536CA092.50300-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
@ 2014-05-09 12:39               ` Hans de Goede
       [not found]                 ` <536CCC75.7050407-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
  0 siblings, 1 reply; 6+ messages in thread
From: Hans de Goede @ 2014-05-09 12:39 UTC (permalink / raw)
  To: Boris BREZILLON, linux-sunxi-/JYPxA39Uh5TLH3MbocFFw,
	Maxime Ripard
  Cc: devicetree, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

Hi,

On 05/09/2014 11:32 AM, Boris BREZILLON wrote:
> 
> On 09/05/2014 11:05, Hans de Goede wrote:
>> Hi,
>>
>> On 05/09/2014 10:55 AM, Boris BREZILLON wrote:
>>> On 09/05/2014 10:43, Hans de Goede wrote:
>>>> Signed-off-by: Hans de Goede <hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
>>>> ---
>>>>  arch/arm/boot/dts/sun6i-a31-app4-evb1.dts | 8 +-------
>>>>  1 file changed, 1 insertion(+), 7 deletions(-)
>>>>
>>>> diff --git a/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts b/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
>>>> index 270ab97..2bbf886 100644
>>>> --- a/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
>>>> +++ b/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
>>>> @@ -13,6 +13,7 @@
>>>>  
>>>>  /dts-v1/;
>>>>  /include/ "sun6i-a31.dtsi"
>>>> +/include/ "sunxi-common-regulators.dtsi"
>>>>  
>>>>  / {
>>>>  	model = "Allwinner A31 APP4 EVB1 Evaluation Board";
>>>> @@ -49,15 +50,8 @@
>>>>  	};
>>>>  
>>>>  	reg_usb1_vbus: usb1-vbus {
>>>> -		compatible = "regulator-fixed";
>>>> -		pinctrl-names = "default";
>>>>  		pinctrl-0 = <&usb1_vbus_pin_a>;
>>>> -		regulator-name = "usb1-vbus";
>>>> -		regulator-min-microvolt = <5000000>;
>>>> -		regulator-max-microvolt = <5000000>;
>>>> -		enable-active-high;
>>>>  		gpio = <&pio 7 27 0>;
>>>>  		status = "okay";
>>>>  	};
>>> I guess we could do the same for usb1_vbus_pin_a (keep the common
>>> definition and change the allwinner,pins property).
>> Hmm, what we do with other boards when the pin does not match the
>> default is change the node name to something baord specific, ie
>> usb1_vbus_pin_app4_evb1
> 
> Okay.
> How did you decide which pins should be put in the default definitions
> (the most used ones among available boards ?) ?

The pins used there are used on all-most all A10 and A20 boards,
the sun5i (A10s / A13) boards seem to not really have any standard gpio
they use, and I have not seen enough A31 boards yet to say anything sensible.

We may need to rename the standard pins to include the platform name if
A31 also uses the same pin everywhere (but a different one from A10).

> I'm not sure defining new pin states for each board is a good solution,
> because you'll embed unneeded pin states in your DTB.
> Anyway, this is your call :-).
> 
>> Which is why I did not remove the common bits from the pin,
>> I did not notice you did not use a board specific name here.
> 
> Then I guess it should be fixed in the same series.
> BTW, AFAIK the original patch adding support for the APP4 EVB1 board has
> not been applied yet, so I think we can fix it send a v2 of this patch.

It is already in Maxime's dt-for-3.16 tree, so it is probably better to fix
this with a followup patch.

Regards,

Hans

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Re: [PATCH] ARM: dts: sun6i-a31-app4-evb1.dts: Use sunxi-common-regulators.dtsi
       [not found]                 ` <536CCC75.7050407-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
@ 2014-05-09 17:27                   ` Maxime Ripard
  0 siblings, 0 replies; 6+ messages in thread
From: Maxime Ripard @ 2014-05-09 17:27 UTC (permalink / raw)
  To: Hans de Goede
  Cc: Boris BREZILLON, linux-sunxi-/JYPxA39Uh5TLH3MbocFFw, devicetree,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

[-- Attachment #1: Type: text/plain, Size: 3128 bytes --]

On Fri, May 09, 2014 at 02:39:17PM +0200, Hans de Goede wrote:
> Hi,
> 
> On 05/09/2014 11:32 AM, Boris BREZILLON wrote:
> > 
> > On 09/05/2014 11:05, Hans de Goede wrote:
> >> Hi,
> >>
> >> On 05/09/2014 10:55 AM, Boris BREZILLON wrote:
> >>> On 09/05/2014 10:43, Hans de Goede wrote:
> >>>> Signed-off-by: Hans de Goede <hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
> >>>> ---
> >>>>  arch/arm/boot/dts/sun6i-a31-app4-evb1.dts | 8 +-------
> >>>>  1 file changed, 1 insertion(+), 7 deletions(-)
> >>>>
> >>>> diff --git a/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts b/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
> >>>> index 270ab97..2bbf886 100644
> >>>> --- a/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
> >>>> +++ b/arch/arm/boot/dts/sun6i-a31-app4-evb1.dts
> >>>> @@ -13,6 +13,7 @@
> >>>>  
> >>>>  /dts-v1/;
> >>>>  /include/ "sun6i-a31.dtsi"
> >>>> +/include/ "sunxi-common-regulators.dtsi"
> >>>>  
> >>>>  / {
> >>>>  	model = "Allwinner A31 APP4 EVB1 Evaluation Board";
> >>>> @@ -49,15 +50,8 @@
> >>>>  	};
> >>>>  
> >>>>  	reg_usb1_vbus: usb1-vbus {
> >>>> -		compatible = "regulator-fixed";
> >>>> -		pinctrl-names = "default";
> >>>>  		pinctrl-0 = <&usb1_vbus_pin_a>;
> >>>> -		regulator-name = "usb1-vbus";
> >>>> -		regulator-min-microvolt = <5000000>;
> >>>> -		regulator-max-microvolt = <5000000>;
> >>>> -		enable-active-high;
> >>>>  		gpio = <&pio 7 27 0>;
> >>>>  		status = "okay";
> >>>>  	};
> >>> I guess we could do the same for usb1_vbus_pin_a (keep the common
> >>> definition and change the allwinner,pins property).
> >> Hmm, what we do with other boards when the pin does not match the
> >> default is change the node name to something baord specific, ie
> >> usb1_vbus_pin_app4_evb1
> > 
> > Okay.
> > How did you decide which pins should be put in the default definitions
> > (the most used ones among available boards ?) ?
> 
> The pins used there are used on all-most all A10 and A20 boards,
> the sun5i (A10s / A13) boards seem to not really have any standard gpio
> they use, and I have not seen enough A31 boards yet to say anything sensible.
> 
> We may need to rename the standard pins to include the platform name if
> A31 also uses the same pin everywhere (but a different one from A10).
> 
> > I'm not sure defining new pin states for each board is a good solution,
> > because you'll embed unneeded pin states in your DTB.
> > Anyway, this is your call :-).
> > 
> >> Which is why I did not remove the common bits from the pin,
> >> I did not notice you did not use a board specific name here.
> > 
> > Then I guess it should be fixed in the same series.
> > BTW, AFAIK the original patch adding support for the APP4 EVB1 board has
> > not been applied yet, so I think we can fix it send a v2 of this patch.
> 
> It is already in Maxime's dt-for-3.16 tree, so it is probably better to fix
> this with a followup patch.

Actually, it's not (yet). I'll squash it into my serie.

Thanks!
Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2014-05-09 17:27 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-09  8:43 [PATCH] ARM: dts: sun6i-a31-app4-evb1.dts: Use sunxi-common-regulators.dtsi Hans de Goede
     [not found] ` <1399624987-12381-1-git-send-email-hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2014-05-09  8:55   ` Boris BREZILLON
     [not found]     ` <536C97FD.3070906-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
2014-05-09  9:05       ` Hans de Goede
     [not found]         ` <536C9A53.2060302-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2014-05-09  9:32           ` Boris BREZILLON
     [not found]             ` <536CA092.50300-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
2014-05-09 12:39               ` Hans de Goede
     [not found]                 ` <536CCC75.7050407-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2014-05-09 17:27                   ` Maxime Ripard

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).