Re: [linux-sunxi] Re: [PATCH 0/7] mfd: AXP20x: Add support for AXP202 and AXP209

2014-03-06 Thread Carlo Caione
On Thu, Mar 6, 2014 at 12:05 PM, Hans de Goede  wrote:
>
> Ah, yes but that is before you added all the regulators, which are a fixed 
> part
> of the chip. Once you get long dts bits like that having a dtsi file makes a 
> lot
> of sense IMHO. Note that the part of the dts this was discussing is actually 
> the part
> I did not put in the dtis, since it can vary per board :)

Oook, now it makes sense. The idea was to integrate axp20x.dtsi at a
later time, but probably I was misunderstood. Thank you for clarifying
it.
I'll put axp20x.dtsi back in v2.

Thanks,

-- 
Carlo Caione

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [linux-sunxi] Re: [PATCH 0/7] mfd: AXP20x: Add support for AXP202 and AXP209

2014-03-06 Thread Hans de Goede
Hi,

On 03/06/2014 11:10 AM, Carlo Caione wrote:
> On Thu, Mar 6, 2014 at 11:07 AM, Hans de Goede  wrote:
>> Hi,
>>
>> On 03/05/2014 09:46 PM, Carlo Caione wrote:
>>> On Wed, Mar 5, 2014 at 9:02 PM, Hans de Goede  wrote:

 So I've added your patches to my sunxi-devel tree and they work as 
 advertised :)
>>>
>>> Thank you for keeping the tree updated :)
>>>
 I've also added dt support for the axp209 to the cubietruck dts file, to 
 avoid
 things becoming a copy and paste fest I've introduced a new axp209.dtsi 
 file,
 as well as did some fixes to the existing sun?i-a*.dtsi files, see my tree 
 here:
 https://github.com/jwrdegoede/linux-sunxi/commits/sunxi-devel
>>>
>>> That was also my idea (creating a new axp20x.dtsi) but it has been
>>> turned down by Maxime and Lee
>>
>> Hmm, do you have a pointer to the mailinglist discussion about this ?
> 
> Sure, http://www.spinics.net/lists/arm-kernel/msg306497.html

Ah, yes but that is before you added all the regulators, which are a fixed part
of the chip. Once you get long dts bits like that having a dtsi file makes a lot
of sense IMHO. Note that the part of the dts this was discussing is actually 
the part
I did not put in the dtis, since it can vary per board :)

Regards,

Hans

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [linux-sunxi] Re: [PATCH 0/7] mfd: AXP20x: Add support for AXP202 and AXP209

2014-03-06 Thread Carlo Caione
On Thu, Mar 6, 2014 at 11:07 AM, Hans de Goede  wrote:
> Hi,
>
> On 03/05/2014 09:46 PM, Carlo Caione wrote:
>> On Wed, Mar 5, 2014 at 9:02 PM, Hans de Goede  wrote:
>>>
>>> So I've added your patches to my sunxi-devel tree and they work as 
>>> advertised :)
>>
>> Thank you for keeping the tree updated :)
>>
>>> I've also added dt support for the axp209 to the cubietruck dts file, to 
>>> avoid
>>> things becoming a copy and paste fest I've introduced a new axp209.dtsi 
>>> file,
>>> as well as did some fixes to the existing sun?i-a*.dtsi files, see my tree 
>>> here:
>>> https://github.com/jwrdegoede/linux-sunxi/commits/sunxi-devel
>>
>> That was also my idea (creating a new axp20x.dtsi) but it has been
>> turned down by Maxime and Lee
>
> Hmm, do you have a pointer to the mailinglist discussion about this ?

Sure, http://www.spinics.net/lists/arm-kernel/msg306497.html

Best,

-- 
Carlo Caione

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [linux-sunxi] Re: [PATCH 0/7] mfd: AXP20x: Add support for AXP202 and AXP209

2014-03-06 Thread Hans de Goede
Hi,

On 03/05/2014 09:46 PM, Carlo Caione wrote:
> On Wed, Mar 5, 2014 at 9:02 PM, Hans de Goede  wrote:
>>
>> So I've added your patches to my sunxi-devel tree and they work as 
>> advertised :)
> 
> Thank you for keeping the tree updated :)
> 
>> I've also added dt support for the axp209 to the cubietruck dts file, to 
>> avoid
>> things becoming a copy and paste fest I've introduced a new axp209.dtsi file,
>> as well as did some fixes to the existing sun?i-a*.dtsi files, see my tree 
>> here:
>> https://github.com/jwrdegoede/linux-sunxi/commits/sunxi-devel
> 
> That was also my idea (creating a new axp20x.dtsi) but it has been
> turned down by Maxime and Lee

Hmm, do you have a pointer to the mailinglist discussion about this ?

Regards,

Hans

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [linux-sunxi] Re: [PATCH 0/7] mfd: AXP20x: Add support for AXP202 and AXP209

2014-03-05 Thread Carlo Caione
On Wed, Mar 5, 2014 at 9:02 PM, Hans de Goede  wrote:
>
> So I've added your patches to my sunxi-devel tree and they work as advertised 
> :)

Thank you for keeping the tree updated :)

> I've also added dt support for the axp209 to the cubietruck dts file, to avoid
> things becoming a copy and paste fest I've introduced a new axp209.dtsi file,
> as well as did some fixes to the existing sun?i-a*.dtsi files, see my tree 
> here:
> https://github.com/jwrdegoede/linux-sunxi/commits/sunxi-devel

That was also my idea (creating a new axp20x.dtsi) but it has been
turned down by Maxime and Lee

> If you agree this is a good idea feel free to steal it all for the next
> revision of your patch-set :)

I will do for sure, thanks

> Note that I've still left some copy-paste parts inside the per board dts 
> files,
> specifically things which may differ per board, ie we know already that A10
> boards will have a different interrupt parent for the interrupt.

Yep, no prob.

> Thanks for your work on this!

Thank you!

-- 
Carlo Caione

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [linux-sunxi] Re: [PATCH 0/7] mfd: AXP20x: Add support for AXP202 and AXP209

2014-03-05 Thread Hans de Goede
Hi,

On 03/01/2014 08:29 PM, Hans de Goede wrote:
> Hi,
> 
> On 03/01/2014 06:17 PM, Carlo Caione wrote:
>> On Sat, Mar 1, 2014 at 5:56 PM, Hans de Goede  wrote:
>>> Hi Carlo,
>>>
>>> Great work, thanks for all the time you're putting into this!
>>
>> Hi Hans :)
>>
>>> I've 2 questions:
>>>
>>> 1) What dependencies does this patch-set have? Obviously it needs the NMI 
>>> irq
>>> patches for A20, anything else ?  I no longer see any use of a special flag
>>> for ack on unmask, is that no longer needed ?
>>
>> Yes, the only dependency is on the NMI controller patch.
>> After a discussion with Maxime and Thomas I decided to not push for
>> including the special flag for ack on unmask in the irqchip core but
>> to use the unmask callback as in the v3 version of the NMI controller
>> driver (so no flag needed)
>>
>>> 2) No poweroff functionality ? That would be really great to have.
>>
>> Actually in [PATCH 1/7] I support the poweroff using the pm_power_off hook.
> 
> Ah I missed that, cool.
> 
> I'm doing with sunxi hacking for today, but I'll add these to sunxi-devel
> and them give them a test run tomorrow.

So I've added your patches to my sunxi-devel tree and they work as advertised :)

I've also added dt support for the axp209 to the cubietruck dts file, to avoid
things becoming a copy and paste fest I've introduced a new axp209.dtsi file,
as well as did some fixes to the existing sun?i-a*.dtsi files, see my tree here:
https://github.com/jwrdegoede/linux-sunxi/commits/sunxi-devel

If you agree this is a good idea feel free to steal it all for the next
revision of your patch-set :)

Note that I've still left some copy-paste parts inside the per board dts files,
specifically things which may differ per board, ie we know already that A10
boards will have a different interrupt parent for the interrupt.

Thanks for your work on this!

Regards,

Hans

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [linux-sunxi] Re: [PATCH 0/7] mfd: AXP20x: Add support for AXP202 and AXP209

2014-03-01 Thread Hans de Goede
Hi,

On 03/01/2014 06:17 PM, Carlo Caione wrote:
> On Sat, Mar 1, 2014 at 5:56 PM, Hans de Goede  wrote:
>> Hi Carlo,
>>
>> Great work, thanks for all the time you're putting into this!
> 
> Hi Hans :)
> 
>> I've 2 questions:
>>
>> 1) What dependencies does this patch-set have? Obviously it needs the NMI irq
>> patches for A20, anything else ?  I no longer see any use of a special flag
>> for ack on unmask, is that no longer needed ?
> 
> Yes, the only dependency is on the NMI controller patch.
> After a discussion with Maxime and Thomas I decided to not push for
> including the special flag for ack on unmask in the irqchip core but
> to use the unmask callback as in the v3 version of the NMI controller
> driver (so no flag needed)
> 
>> 2) No poweroff functionality ? That would be really great to have.
> 
> Actually in [PATCH 1/7] I support the poweroff using the pm_power_off hook.

Ah I missed that, cool.

I'm doing with sunxi hacking for today, but I'll add these to sunxi-devel
and them give them a test run tomorrow.

Regards,

Hans

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


[linux-sunxi] Re: [PATCH 0/7] mfd: AXP20x: Add support for AXP202 and AXP209

2014-03-01 Thread Carlo Caione
On Sat, Mar 1, 2014 at 5:56 PM, Hans de Goede  wrote:
> Hi Carlo,
>
> Great work, thanks for all the time you're putting into this!

Hi Hans :)

> I've 2 questions:
>
> 1) What dependencies does this patch-set have? Obviously it needs the NMI irq
> patches for A20, anything else ?  I no longer see any use of a special flag
> for ack on unmask, is that no longer needed ?

Yes, the only dependency is on the NMI controller patch.
After a discussion with Maxime and Thomas I decided to not push for
including the special flag for ack on unmask in the irqchip core but
to use the unmask callback as in the v3 version of the NMI controller
driver (so no flag needed)

> 2) No poweroff functionality ? That would be really great to have.

Actually in [PATCH 1/7] I support the poweroff using the pm_power_off hook.

Best,

-- 
Carlo Caione

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


[linux-sunxi] Re: [PATCH 0/7] mfd: AXP20x: Add support for AXP202 and AXP209

2014-03-01 Thread Hans de Goede
Hi Carlo,

Great work, thanks for all the time you're putting into this!

I've 2 questions:

1) What dependencies does this patch-set have? Obviously it needs the NMI irq
patches for A20, anything else ?  I no longer see any use of a special flag
for ack on unmask, is that no longer needed ?

2) No poweroff functionality ? That would be really great to have.

Regards,

Hans




On 03/01/2014 05:45 PM, Carlo Caione wrote:
> AXP209 and AXP202 are the PMUs (Power Management Unit) used by A10, A13
> and A20 SoCs and developed by X-Powers, a sister company of Allwinner.
> AXP20x comprises an adaptive USB-Compatible PWM charger, 2 BUCK DC-DC
> converters, 5 LDOs, multiple 12-bit ADCs of voltage, current and temperature
> as well as 4 configurable GPIOs. 
> 
> This set of patches introduces the core driver and support for two different
> subsystems:
>   - Regulators
>   - PEK (Power Enable Key)
> 
> Support for AXP209 in Cubieboard2 is also added.
> 
> Carlo Caione (7):
>   mfd: AXP20x: Add mfd driver for AXP20x PMIC
>   mfd: AXP20x: Add bindings documentation
>   ARM: dts: cubieboard2: Add AXP209 support
>   input: misc: Add driver for AXP20x Power Enable Key
>   input: misc: Add ABI docs for AXP20x PEK
>   regulator: AXP20x: Add support for regulators subsystem
>   ARM: dts: Cubieboard2: Add support for AXP209 regulators
> 
>  .../ABI/testing/sysfs-driver-input-axp-pek |  11 +
>  Documentation/devicetree/bindings/mfd/axp20x.txt   |  93 ++
>  arch/arm/boot/dts/sun7i-a20-cubieboard2.dts|  58 
>  arch/arm/configs/sunxi_defconfig   |   4 +
>  drivers/input/misc/Kconfig |  11 +
>  drivers/input/misc/Makefile|   1 +
>  drivers/input/misc/axp20x-pek.c| 265 
>  drivers/mfd/Kconfig|  12 +
>  drivers/mfd/Makefile   |   1 +
>  drivers/mfd/axp20x.c   | 250 +++
>  drivers/regulator/Kconfig  |   7 +
>  drivers/regulator/Makefile |   1 +
>  drivers/regulator/axp20x-regulator.c   | 349 
> +
>  include/linux/mfd/axp20x.h | 180 +++
>  14 files changed, 1243 insertions(+)
>  create mode 100644 Documentation/ABI/testing/sysfs-driver-input-axp-pek
>  create mode 100644 Documentation/devicetree/bindings/mfd/axp20x.txt
>  create mode 100644 drivers/input/misc/axp20x-pek.c
>  create mode 100644 drivers/mfd/axp20x.c
>  create mode 100644 drivers/regulator/axp20x-regulator.c
>  create mode 100644 include/linux/mfd/axp20x.h
> 

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.