Re: [PATCH v3 00/17] pinctrl: exynos/samsung: Add header with values used for configuration

2016-10-21 Thread Linus Walleij
On Sun, Sep 4, 2016 at 1:04 PM, Krzysztof Kozlowski  wrote:

>   pinctrl: dt-bindings: samsung: Add header with values used for
> configuration
>   pinctrl: dt-bindings: samsung: Update documentation with new macros

These two:
Acked-by: Linus Walleij 

Please merge all of it through the Exynos tree and ARM SoC once
you're done with the rewrite.

Yours,
Linus Walleij


Re: [PATCH v3 00/17] pinctrl: exynos/samsung: Add header with values used for configuration

2016-10-21 Thread Linus Walleij
On Sun, Sep 4, 2016 at 1:04 PM, Krzysztof Kozlowski  wrote:

>   pinctrl: dt-bindings: samsung: Add header with values used for
> configuration
>   pinctrl: dt-bindings: samsung: Update documentation with new macros

These two:
Acked-by: Linus Walleij 

Please merge all of it through the Exynos tree and ARM SoC once
you're done with the rewrite.

Yours,
Linus Walleij


Re: [PATCH v3 00/17] pinctrl: exynos/samsung: Add header with values used for configuration

2016-10-09 Thread Krzysztof Kozlowski
On Mon, Oct 10, 2016 at 02:49:01AM +0900, Tomasz Figa wrote:
> 2016-10-10 1:39 GMT+09:00 Krzysztof Kozlowski :
> > On Sun, Oct 09, 2016 at 04:04:11PM +0900, Tomasz Figa wrote:
> >> Hi Krzysztof,
> >>
> >> 2016-09-04 20:04 GMT+09:00 Krzysztof Kozlowski :
> >> >
> >> > Hi,
> >> >
> >> > Changes since v2
> >> > 
> >> > 1. Combine separate patchsets into one. Previously I sent separately the 
> >> > fixes
> >> >and changes for S3C platforms.
> >> > 2. Fix issues pointed during review.
> >> > 3. Add review tags.
> >> >
> >> > Changes since v1
> >> > 
> >> > 1. Follow Arnd's suggestion about moving the macros to common place.
> >> > 2. Subjects: replace "GPIO" with "pinctrl".
> >> > 3. There were some major changes here so I did not add Javier's
> >> >reviewed-by and tested-by tags.
> >> >
> >> > Merging
> >> > ===
> >> > Patches #1 and #2 should probably go through pinctrl tree. In that case 
> >> > I would
> >> > appreciate a stable branch/tag so DTS could base on top of it.
> >> >
> >> > Goal
> >> > 
> >> > Increase readability:
> >> > uart0_data: uart0-data {
> >> > samsung,pins = "gpa0-0", "gpa0-1";
> >> > -   samsung,pin-function = <2>;
> >> > -   samsung,pin-pud = <0>;
> >> > -   samsung,pin-drv = <0>;
> >> > +   samsung,pin-function = ;
> >> > +   samsung,pin-pud = ;
> >> > +   samsung,pin-drv = ;
> >>
> >> I like the idea, thanks for cleaning this up. However I'd like to
> >> bikeshed the prefix a bit. Since the properties are already prefixed
> >> by "samsung,", I think it would make much more sense to also prefix
> >> the generic values with "SAMSUNG_". Of course for soc/family-specific
> >> values, the soc/family name prefix sounds right.
> >
> > I am lost. Sorry, I don't get what kind of final prefixes you would like
> > to have.
> >
> > SAMSUNG_EXYNOS4_PIN_DRV_LV1
> > SAMSUNG_EXYNOS5260_PIN_DRV_LV1
> > ?
> 
> For SoC-specific definitions:
> 
> EXYNOS4_PIN_DRV_LV1
> EXYNOS5260_PIN_DRV_LV1

ok... so no change needed in my patch.

> 
> >
> >> Similarly for rest of the value names, such as SAMSUNG_PIN_PUD instead
> >> of SAMSUNG_PIN_PULL, which obviously sounds more like correct English,
> >> however hurts the consistency and could confuse the people writing new
> >> dts files.
> >
> > SAMSUNG_S3C64XX_PIN_PUD_NONE
> > SAMSUNG_EXYNOS_PIN_PUD_NONE
> 
> For definitions common for the whole Samsung pinctrl driver:
> 
> SAMSUNG_PIN_PUD_NONE

These are not the same. The "none" is the same but rest is not.

> But actually I think I missed the fact that there is almost no common
> definitions. Is that correct? Was that the missing part of my
> understanding?

Yes. The only common definition for all Samsung SoCs would be the
function of a pin. On the other hand this will bring inconsistency:
everything prefixed with SoC except the function.

Best regards,
Krzysztof


Re: [PATCH v3 00/17] pinctrl: exynos/samsung: Add header with values used for configuration

2016-10-09 Thread Krzysztof Kozlowski
On Mon, Oct 10, 2016 at 02:49:01AM +0900, Tomasz Figa wrote:
> 2016-10-10 1:39 GMT+09:00 Krzysztof Kozlowski :
> > On Sun, Oct 09, 2016 at 04:04:11PM +0900, Tomasz Figa wrote:
> >> Hi Krzysztof,
> >>
> >> 2016-09-04 20:04 GMT+09:00 Krzysztof Kozlowski :
> >> >
> >> > Hi,
> >> >
> >> > Changes since v2
> >> > 
> >> > 1. Combine separate patchsets into one. Previously I sent separately the 
> >> > fixes
> >> >and changes for S3C platforms.
> >> > 2. Fix issues pointed during review.
> >> > 3. Add review tags.
> >> >
> >> > Changes since v1
> >> > 
> >> > 1. Follow Arnd's suggestion about moving the macros to common place.
> >> > 2. Subjects: replace "GPIO" with "pinctrl".
> >> > 3. There were some major changes here so I did not add Javier's
> >> >reviewed-by and tested-by tags.
> >> >
> >> > Merging
> >> > ===
> >> > Patches #1 and #2 should probably go through pinctrl tree. In that case 
> >> > I would
> >> > appreciate a stable branch/tag so DTS could base on top of it.
> >> >
> >> > Goal
> >> > 
> >> > Increase readability:
> >> > uart0_data: uart0-data {
> >> > samsung,pins = "gpa0-0", "gpa0-1";
> >> > -   samsung,pin-function = <2>;
> >> > -   samsung,pin-pud = <0>;
> >> > -   samsung,pin-drv = <0>;
> >> > +   samsung,pin-function = ;
> >> > +   samsung,pin-pud = ;
> >> > +   samsung,pin-drv = ;
> >>
> >> I like the idea, thanks for cleaning this up. However I'd like to
> >> bikeshed the prefix a bit. Since the properties are already prefixed
> >> by "samsung,", I think it would make much more sense to also prefix
> >> the generic values with "SAMSUNG_". Of course for soc/family-specific
> >> values, the soc/family name prefix sounds right.
> >
> > I am lost. Sorry, I don't get what kind of final prefixes you would like
> > to have.
> >
> > SAMSUNG_EXYNOS4_PIN_DRV_LV1
> > SAMSUNG_EXYNOS5260_PIN_DRV_LV1
> > ?
> 
> For SoC-specific definitions:
> 
> EXYNOS4_PIN_DRV_LV1
> EXYNOS5260_PIN_DRV_LV1

ok... so no change needed in my patch.

> 
> >
> >> Similarly for rest of the value names, such as SAMSUNG_PIN_PUD instead
> >> of SAMSUNG_PIN_PULL, which obviously sounds more like correct English,
> >> however hurts the consistency and could confuse the people writing new
> >> dts files.
> >
> > SAMSUNG_S3C64XX_PIN_PUD_NONE
> > SAMSUNG_EXYNOS_PIN_PUD_NONE
> 
> For definitions common for the whole Samsung pinctrl driver:
> 
> SAMSUNG_PIN_PUD_NONE

These are not the same. The "none" is the same but rest is not.

> But actually I think I missed the fact that there is almost no common
> definitions. Is that correct? Was that the missing part of my
> understanding?

Yes. The only common definition for all Samsung SoCs would be the
function of a pin. On the other hand this will bring inconsistency:
everything prefixed with SoC except the function.

Best regards,
Krzysztof


Re: [PATCH v3 00/17] pinctrl: exynos/samsung: Add header with values used for configuration

2016-10-09 Thread Tomasz Figa
2016-10-10 1:39 GMT+09:00 Krzysztof Kozlowski :
> On Sun, Oct 09, 2016 at 04:04:11PM +0900, Tomasz Figa wrote:
>> Hi Krzysztof,
>>
>> 2016-09-04 20:04 GMT+09:00 Krzysztof Kozlowski :
>> >
>> > Hi,
>> >
>> > Changes since v2
>> > 
>> > 1. Combine separate patchsets into one. Previously I sent separately the 
>> > fixes
>> >and changes for S3C platforms.
>> > 2. Fix issues pointed during review.
>> > 3. Add review tags.
>> >
>> > Changes since v1
>> > 
>> > 1. Follow Arnd's suggestion about moving the macros to common place.
>> > 2. Subjects: replace "GPIO" with "pinctrl".
>> > 3. There were some major changes here so I did not add Javier's
>> >reviewed-by and tested-by tags.
>> >
>> > Merging
>> > ===
>> > Patches #1 and #2 should probably go through pinctrl tree. In that case I 
>> > would
>> > appreciate a stable branch/tag so DTS could base on top of it.
>> >
>> > Goal
>> > 
>> > Increase readability:
>> > uart0_data: uart0-data {
>> > samsung,pins = "gpa0-0", "gpa0-1";
>> > -   samsung,pin-function = <2>;
>> > -   samsung,pin-pud = <0>;
>> > -   samsung,pin-drv = <0>;
>> > +   samsung,pin-function = ;
>> > +   samsung,pin-pud = ;
>> > +   samsung,pin-drv = ;
>>
>> I like the idea, thanks for cleaning this up. However I'd like to
>> bikeshed the prefix a bit. Since the properties are already prefixed
>> by "samsung,", I think it would make much more sense to also prefix
>> the generic values with "SAMSUNG_". Of course for soc/family-specific
>> values, the soc/family name prefix sounds right.
>
> I am lost. Sorry, I don't get what kind of final prefixes you would like
> to have.
>
> SAMSUNG_EXYNOS4_PIN_DRV_LV1
> SAMSUNG_EXYNOS5260_PIN_DRV_LV1
> ?

For SoC-specific definitions:

EXYNOS4_PIN_DRV_LV1
EXYNOS5260_PIN_DRV_LV1

>
>> Similarly for rest of the value names, such as SAMSUNG_PIN_PUD instead
>> of SAMSUNG_PIN_PULL, which obviously sounds more like correct English,
>> however hurts the consistency and could confuse the people writing new
>> dts files.
>
> SAMSUNG_S3C64XX_PIN_PUD_NONE
> SAMSUNG_EXYNOS_PIN_PUD_NONE

For definitions common for the whole Samsung pinctrl driver:

SAMSUNG_PIN_PUD_NONE

...

But actually I think I missed the fact that there is almost no common
definitions. Is that correct? Was that the missing part of my
understanding?

Best regards,
Tomasz


Re: [PATCH v3 00/17] pinctrl: exynos/samsung: Add header with values used for configuration

2016-10-09 Thread Tomasz Figa
2016-10-10 1:39 GMT+09:00 Krzysztof Kozlowski :
> On Sun, Oct 09, 2016 at 04:04:11PM +0900, Tomasz Figa wrote:
>> Hi Krzysztof,
>>
>> 2016-09-04 20:04 GMT+09:00 Krzysztof Kozlowski :
>> >
>> > Hi,
>> >
>> > Changes since v2
>> > 
>> > 1. Combine separate patchsets into one. Previously I sent separately the 
>> > fixes
>> >and changes for S3C platforms.
>> > 2. Fix issues pointed during review.
>> > 3. Add review tags.
>> >
>> > Changes since v1
>> > 
>> > 1. Follow Arnd's suggestion about moving the macros to common place.
>> > 2. Subjects: replace "GPIO" with "pinctrl".
>> > 3. There were some major changes here so I did not add Javier's
>> >reviewed-by and tested-by tags.
>> >
>> > Merging
>> > ===
>> > Patches #1 and #2 should probably go through pinctrl tree. In that case I 
>> > would
>> > appreciate a stable branch/tag so DTS could base on top of it.
>> >
>> > Goal
>> > 
>> > Increase readability:
>> > uart0_data: uart0-data {
>> > samsung,pins = "gpa0-0", "gpa0-1";
>> > -   samsung,pin-function = <2>;
>> > -   samsung,pin-pud = <0>;
>> > -   samsung,pin-drv = <0>;
>> > +   samsung,pin-function = ;
>> > +   samsung,pin-pud = ;
>> > +   samsung,pin-drv = ;
>>
>> I like the idea, thanks for cleaning this up. However I'd like to
>> bikeshed the prefix a bit. Since the properties are already prefixed
>> by "samsung,", I think it would make much more sense to also prefix
>> the generic values with "SAMSUNG_". Of course for soc/family-specific
>> values, the soc/family name prefix sounds right.
>
> I am lost. Sorry, I don't get what kind of final prefixes you would like
> to have.
>
> SAMSUNG_EXYNOS4_PIN_DRV_LV1
> SAMSUNG_EXYNOS5260_PIN_DRV_LV1
> ?

For SoC-specific definitions:

EXYNOS4_PIN_DRV_LV1
EXYNOS5260_PIN_DRV_LV1

>
>> Similarly for rest of the value names, such as SAMSUNG_PIN_PUD instead
>> of SAMSUNG_PIN_PULL, which obviously sounds more like correct English,
>> however hurts the consistency and could confuse the people writing new
>> dts files.
>
> SAMSUNG_S3C64XX_PIN_PUD_NONE
> SAMSUNG_EXYNOS_PIN_PUD_NONE

For definitions common for the whole Samsung pinctrl driver:

SAMSUNG_PIN_PUD_NONE

...

But actually I think I missed the fact that there is almost no common
definitions. Is that correct? Was that the missing part of my
understanding?

Best regards,
Tomasz


Re: [PATCH v3 00/17] pinctrl: exynos/samsung: Add header with values used for configuration

2016-10-09 Thread Krzysztof Kozlowski
On Sun, Oct 09, 2016 at 04:04:11PM +0900, Tomasz Figa wrote:
> Hi Krzysztof,
> 
> 2016-09-04 20:04 GMT+09:00 Krzysztof Kozlowski :
> >
> > Hi,
> >
> > Changes since v2
> > 
> > 1. Combine separate patchsets into one. Previously I sent separately the 
> > fixes
> >and changes for S3C platforms.
> > 2. Fix issues pointed during review.
> > 3. Add review tags.
> >
> > Changes since v1
> > 
> > 1. Follow Arnd's suggestion about moving the macros to common place.
> > 2. Subjects: replace "GPIO" with "pinctrl".
> > 3. There were some major changes here so I did not add Javier's
> >reviewed-by and tested-by tags.
> >
> > Merging
> > ===
> > Patches #1 and #2 should probably go through pinctrl tree. In that case I 
> > would
> > appreciate a stable branch/tag so DTS could base on top of it.
> >
> > Goal
> > 
> > Increase readability:
> > uart0_data: uart0-data {
> > samsung,pins = "gpa0-0", "gpa0-1";
> > -   samsung,pin-function = <2>;
> > -   samsung,pin-pud = <0>;
> > -   samsung,pin-drv = <0>;
> > +   samsung,pin-function = ;
> > +   samsung,pin-pud = ;
> > +   samsung,pin-drv = ;
> 
> I like the idea, thanks for cleaning this up. However I'd like to
> bikeshed the prefix a bit. Since the properties are already prefixed
> by "samsung,", I think it would make much more sense to also prefix
> the generic values with "SAMSUNG_". Of course for soc/family-specific
> values, the soc/family name prefix sounds right.

I am lost. Sorry, I don't get what kind of final prefixes you would like
to have.

SAMSUNG_EXYNOS4_PIN_DRV_LV1
SAMSUNG_EXYNOS5260_PIN_DRV_LV1
?

> Similarly for rest of the value names, such as SAMSUNG_PIN_PUD instead
> of SAMSUNG_PIN_PULL, which obviously sounds more like correct English,
> however hurts the consistency and could confuse the people writing new
> dts files.

SAMSUNG_S3C64XX_PIN_PUD_NONE
SAMSUNG_EXYNOS_PIN_PUD_NONE

?

Best regards,
Krzysztof


Re: [PATCH v3 00/17] pinctrl: exynos/samsung: Add header with values used for configuration

2016-10-09 Thread Krzysztof Kozlowski
On Sun, Oct 09, 2016 at 04:04:11PM +0900, Tomasz Figa wrote:
> Hi Krzysztof,
> 
> 2016-09-04 20:04 GMT+09:00 Krzysztof Kozlowski :
> >
> > Hi,
> >
> > Changes since v2
> > 
> > 1. Combine separate patchsets into one. Previously I sent separately the 
> > fixes
> >and changes for S3C platforms.
> > 2. Fix issues pointed during review.
> > 3. Add review tags.
> >
> > Changes since v1
> > 
> > 1. Follow Arnd's suggestion about moving the macros to common place.
> > 2. Subjects: replace "GPIO" with "pinctrl".
> > 3. There were some major changes here so I did not add Javier's
> >reviewed-by and tested-by tags.
> >
> > Merging
> > ===
> > Patches #1 and #2 should probably go through pinctrl tree. In that case I 
> > would
> > appreciate a stable branch/tag so DTS could base on top of it.
> >
> > Goal
> > 
> > Increase readability:
> > uart0_data: uart0-data {
> > samsung,pins = "gpa0-0", "gpa0-1";
> > -   samsung,pin-function = <2>;
> > -   samsung,pin-pud = <0>;
> > -   samsung,pin-drv = <0>;
> > +   samsung,pin-function = ;
> > +   samsung,pin-pud = ;
> > +   samsung,pin-drv = ;
> 
> I like the idea, thanks for cleaning this up. However I'd like to
> bikeshed the prefix a bit. Since the properties are already prefixed
> by "samsung,", I think it would make much more sense to also prefix
> the generic values with "SAMSUNG_". Of course for soc/family-specific
> values, the soc/family name prefix sounds right.

I am lost. Sorry, I don't get what kind of final prefixes you would like
to have.

SAMSUNG_EXYNOS4_PIN_DRV_LV1
SAMSUNG_EXYNOS5260_PIN_DRV_LV1
?

> Similarly for rest of the value names, such as SAMSUNG_PIN_PUD instead
> of SAMSUNG_PIN_PULL, which obviously sounds more like correct English,
> however hurts the consistency and could confuse the people writing new
> dts files.

SAMSUNG_S3C64XX_PIN_PUD_NONE
SAMSUNG_EXYNOS_PIN_PUD_NONE

?

Best regards,
Krzysztof


Re: [PATCH v3 00/17] pinctrl: exynos/samsung: Add header with values used for configuration

2016-10-09 Thread Tomasz Figa
Hi Krzysztof,

2016-09-04 20:04 GMT+09:00 Krzysztof Kozlowski :
>
> Hi,
>
> Changes since v2
> 
> 1. Combine separate patchsets into one. Previously I sent separately the fixes
>and changes for S3C platforms.
> 2. Fix issues pointed during review.
> 3. Add review tags.
>
> Changes since v1
> 
> 1. Follow Arnd's suggestion about moving the macros to common place.
> 2. Subjects: replace "GPIO" with "pinctrl".
> 3. There were some major changes here so I did not add Javier's
>reviewed-by and tested-by tags.
>
> Merging
> ===
> Patches #1 and #2 should probably go through pinctrl tree. In that case I 
> would
> appreciate a stable branch/tag so DTS could base on top of it.
>
> Goal
> 
> Increase readability:
> uart0_data: uart0-data {
> samsung,pins = "gpa0-0", "gpa0-1";
> -   samsung,pin-function = <2>;
> -   samsung,pin-pud = <0>;
> -   samsung,pin-drv = <0>;
> +   samsung,pin-function = ;
> +   samsung,pin-pud = ;
> +   samsung,pin-drv = ;

I like the idea, thanks for cleaning this up. However I'd like to
bikeshed the prefix a bit. Since the properties are already prefixed
by "samsung,", I think it would make much more sense to also prefix
the generic values with "SAMSUNG_". Of course for soc/family-specific
values, the soc/family name prefix sounds right.

Similarly for rest of the value names, such as SAMSUNG_PIN_PUD instead
of SAMSUNG_PIN_PULL, which obviously sounds more like correct English,
however hurts the consistency and could confuse the people writing new
dts files.

Best regards,
Tomasz


Re: [PATCH v3 00/17] pinctrl: exynos/samsung: Add header with values used for configuration

2016-10-09 Thread Tomasz Figa
Hi Krzysztof,

2016-09-04 20:04 GMT+09:00 Krzysztof Kozlowski :
>
> Hi,
>
> Changes since v2
> 
> 1. Combine separate patchsets into one. Previously I sent separately the fixes
>and changes for S3C platforms.
> 2. Fix issues pointed during review.
> 3. Add review tags.
>
> Changes since v1
> 
> 1. Follow Arnd's suggestion about moving the macros to common place.
> 2. Subjects: replace "GPIO" with "pinctrl".
> 3. There were some major changes here so I did not add Javier's
>reviewed-by and tested-by tags.
>
> Merging
> ===
> Patches #1 and #2 should probably go through pinctrl tree. In that case I 
> would
> appreciate a stable branch/tag so DTS could base on top of it.
>
> Goal
> 
> Increase readability:
> uart0_data: uart0-data {
> samsung,pins = "gpa0-0", "gpa0-1";
> -   samsung,pin-function = <2>;
> -   samsung,pin-pud = <0>;
> -   samsung,pin-drv = <0>;
> +   samsung,pin-function = ;
> +   samsung,pin-pud = ;
> +   samsung,pin-drv = ;

I like the idea, thanks for cleaning this up. However I'd like to
bikeshed the prefix a bit. Since the properties are already prefixed
by "samsung,", I think it would make much more sense to also prefix
the generic values with "SAMSUNG_". Of course for soc/family-specific
values, the soc/family name prefix sounds right.

Similarly for rest of the value names, such as SAMSUNG_PIN_PUD instead
of SAMSUNG_PIN_PULL, which obviously sounds more like correct English,
however hurts the consistency and could confuse the people writing new
dts files.

Best regards,
Tomasz


[PATCH v3 00/17] pinctrl: exynos/samsung: Add header with values used for configuration

2016-09-04 Thread Krzysztof Kozlowski

Hi,

Changes since v2

1. Combine separate patchsets into one. Previously I sent separately the fixes
   and changes for S3C platforms.
2. Fix issues pointed during review.
3. Add review tags.

Changes since v1

1. Follow Arnd's suggestion about moving the macros to common place.
2. Subjects: replace "GPIO" with "pinctrl".
3. There were some major changes here so I did not add Javier's
   reviewed-by and tested-by tags.

Merging
===
Patches #1 and #2 should probably go through pinctrl tree. In that case I would
appreciate a stable branch/tag so DTS could base on top of it.

Goal

Increase readability:
uart0_data: uart0-data {
samsung,pins = "gpa0-0", "gpa0-1";
-   samsung,pin-function = <2>;
-   samsung,pin-pud = <0>;
-   samsung,pin-drv = <0>;
+   samsung,pin-function = ;
+   samsung,pin-pud = ;
+   samsung,pin-drv = ;
};

Everything generated with sed:
sed -i -e 's/samsung,pin-pud = <0>;$/samsung,pin-pud = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-pud = <1>;$/samsung,pin-pud = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-pud = <3>;$/samsung,pin-pud = ;/' 
arch/arm/boot/dts/exynos*

sed -i -e 's/samsung,pin-drv = <0>;$/samsung,pin-drv = ;/' 
arch/arm/boot/dts/exynos[34]* arch/arm/boot/dts/exynos5250*
sed -i -e 's/samsung,pin-drv = <2>;$/samsung,pin-drv = ;/' 
arch/arm/boot/dts/exynos[34]* arch/arm/boot/dts/exynos5250*
sed -i -e 's/samsung,pin-drv = <1>;$/samsung,pin-drv = ;/' 
arch/arm/boot/dts/exynos[34]* arch/arm/boot/dts/exynos5250*
sed -i -e 's/samsung,pin-drv = <3>;$/samsung,pin-drv = ;/' 
arch/arm/boot/dts/exynos[34]* arch/arm/boot/dts/exynos5250*

sed -i -e 's/samsung,pin-drv = <0>;$/samsung,pin-drv = 
;/' arch/arm/boot/dts/exynos5260*
sed -i -e 's/samsung,pin-drv = <1>;$/samsung,pin-drv = 
;/' arch/arm/boot/dts/exynos5260*
sed -i -e 's/samsung,pin-drv = <2>;$/samsung,pin-drv = 
;/' arch/arm/boot/dts/exynos5260*
sed -i -e 's/samsung,pin-drv = <3>;$/samsung,pin-drv = 
;/' arch/arm/boot/dts/exynos5260*

sed -i -e 's/samsung,pin-drv = <0>;$/samsung,pin-drv = 
;/' arch/arm/boot/dts/exynos5[48]*
sed -i -e 's/samsung,pin-drv = <1>;$/samsung,pin-drv = 
;/' arch/arm/boot/dts/exynos5[48]*
sed -i -e 's/samsung,pin-drv = <2>;$/samsung,pin-drv = 
;/' arch/arm/boot/dts/exynos5[48]*
sed -i -e 's/samsung,pin-drv = <3>;$/samsung,pin-drv = 
;/' arch/arm/boot/dts/exynos5[48]*

sed -i -e 's/samsung,pin-function = <0>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-function = <1>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*

sed -i -e 's/samsung,pin-function = <2>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-function = <\(0x\)\?2>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-function = <\(0x\)\?3>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-function = <3>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-function = <4>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-function = <5>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-function = <6>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-function = <0xf>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*

sed -i -e 's/samsung,pin-drv = <0>;$/samsung,pin-drv = ;/' 
arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-drv = <2>;$/samsung,pin-drv = ;/' 
arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-drv = <1>;$/samsung,pin-drv = ;/' 
arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-drv = <3>;$/samsung,pin-drv = ;/' 
arch/arm/boot/dts/s5p*

sed -i -e 's/samsung,pin-pud = <0>;$/samsung,pin-pud = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-pud = <1>;$/samsung,pin-pud = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-pud = <2>;$/samsung,pin-pud = ;/' 
arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*

sed -i -e 's/samsung,pin-function = <0>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-function = <2>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-function = <\(0x\)\?2>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-function = <\(0x\)\?3>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-function = <3>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-function = <4>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-function = <5>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-function = 

[PATCH v3 00/17] pinctrl: exynos/samsung: Add header with values used for configuration

2016-09-04 Thread Krzysztof Kozlowski

Hi,

Changes since v2

1. Combine separate patchsets into one. Previously I sent separately the fixes
   and changes for S3C platforms.
2. Fix issues pointed during review.
3. Add review tags.

Changes since v1

1. Follow Arnd's suggestion about moving the macros to common place.
2. Subjects: replace "GPIO" with "pinctrl".
3. There were some major changes here so I did not add Javier's
   reviewed-by and tested-by tags.

Merging
===
Patches #1 and #2 should probably go through pinctrl tree. In that case I would
appreciate a stable branch/tag so DTS could base on top of it.

Goal

Increase readability:
uart0_data: uart0-data {
samsung,pins = "gpa0-0", "gpa0-1";
-   samsung,pin-function = <2>;
-   samsung,pin-pud = <0>;
-   samsung,pin-drv = <0>;
+   samsung,pin-function = ;
+   samsung,pin-pud = ;
+   samsung,pin-drv = ;
};

Everything generated with sed:
sed -i -e 's/samsung,pin-pud = <0>;$/samsung,pin-pud = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-pud = <1>;$/samsung,pin-pud = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-pud = <3>;$/samsung,pin-pud = ;/' 
arch/arm/boot/dts/exynos*

sed -i -e 's/samsung,pin-drv = <0>;$/samsung,pin-drv = ;/' 
arch/arm/boot/dts/exynos[34]* arch/arm/boot/dts/exynos5250*
sed -i -e 's/samsung,pin-drv = <2>;$/samsung,pin-drv = ;/' 
arch/arm/boot/dts/exynos[34]* arch/arm/boot/dts/exynos5250*
sed -i -e 's/samsung,pin-drv = <1>;$/samsung,pin-drv = ;/' 
arch/arm/boot/dts/exynos[34]* arch/arm/boot/dts/exynos5250*
sed -i -e 's/samsung,pin-drv = <3>;$/samsung,pin-drv = ;/' 
arch/arm/boot/dts/exynos[34]* arch/arm/boot/dts/exynos5250*

sed -i -e 's/samsung,pin-drv = <0>;$/samsung,pin-drv = 
;/' arch/arm/boot/dts/exynos5260*
sed -i -e 's/samsung,pin-drv = <1>;$/samsung,pin-drv = 
;/' arch/arm/boot/dts/exynos5260*
sed -i -e 's/samsung,pin-drv = <2>;$/samsung,pin-drv = 
;/' arch/arm/boot/dts/exynos5260*
sed -i -e 's/samsung,pin-drv = <3>;$/samsung,pin-drv = 
;/' arch/arm/boot/dts/exynos5260*

sed -i -e 's/samsung,pin-drv = <0>;$/samsung,pin-drv = 
;/' arch/arm/boot/dts/exynos5[48]*
sed -i -e 's/samsung,pin-drv = <1>;$/samsung,pin-drv = 
;/' arch/arm/boot/dts/exynos5[48]*
sed -i -e 's/samsung,pin-drv = <2>;$/samsung,pin-drv = 
;/' arch/arm/boot/dts/exynos5[48]*
sed -i -e 's/samsung,pin-drv = <3>;$/samsung,pin-drv = 
;/' arch/arm/boot/dts/exynos5[48]*

sed -i -e 's/samsung,pin-function = <0>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-function = <1>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*

sed -i -e 's/samsung,pin-function = <2>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-function = <\(0x\)\?2>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-function = <\(0x\)\?3>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-function = <3>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-function = <4>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-function = <5>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-function = <6>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*
sed -i -e 's/samsung,pin-function = <0xf>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/exynos*

sed -i -e 's/samsung,pin-drv = <0>;$/samsung,pin-drv = ;/' 
arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-drv = <2>;$/samsung,pin-drv = ;/' 
arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-drv = <1>;$/samsung,pin-drv = ;/' 
arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-drv = <3>;$/samsung,pin-drv = ;/' 
arch/arm/boot/dts/s5p*

sed -i -e 's/samsung,pin-pud = <0>;$/samsung,pin-pud = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-pud = <1>;$/samsung,pin-pud = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-pud = <2>;$/samsung,pin-pud = ;/' 
arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*

sed -i -e 's/samsung,pin-function = <0>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-function = <2>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-function = <\(0x\)\?2>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-function = <\(0x\)\?3>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-function = <3>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-function = <4>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-function = <5>;$/samsung,pin-function = 
;/' arch/arm/boot/dts/s3c* arch/arm/boot/dts/s5p*
sed -i -e 's/samsung,pin-function =