Re: [RFC PATCH v2 1/4] regulator: Add helper function to get "poweroff-source" property

2014-10-13 Thread Mark Brown
On Tue, Oct 07, 2014 at 07:45:01PM +, Romain Perier wrote: > Several drivers create their own devicetree property when they register > poweroff capabilities. This is for example the case for mfd, regulator This seems fine from a code point of view but as discussed it's probably better placed

Re: [RFC PATCH v2 1/4] regulator: Add helper function to get poweroff-source property

2014-10-13 Thread Mark Brown
On Tue, Oct 07, 2014 at 07:45:01PM +, Romain Perier wrote: Several drivers create their own devicetree property when they register poweroff capabilities. This is for example the case for mfd, regulator This seems fine from a code point of view but as discussed it's probably better placed

Re: [RFC PATCH v2 1/4] regulator: Add helper function to get "poweroff-source" property

2014-10-11 Thread Grant Likely
On Fri, Oct 10, 2014 at 1:29 PM, PERIER Romain wrote: >> >> What I'm more concerned about is the semantics of the property. What >> do the generic code paths gain by standardizing this property? Is it >> expected that > > We really need to come up with a standard property for this and document >

Re: [RFC PATCH v2 1/4] regulator: Add helper function to get poweroff-source property

2014-10-11 Thread Grant Likely
On Fri, Oct 10, 2014 at 1:29 PM, PERIER Romain romain.per...@gmail.com wrote: What I'm more concerned about is the semantics of the property. What do the generic code paths gain by standardizing this property? Is it expected that We really need to come up with a standard property for this

Re: [RFC PATCH v2 1/4] regulator: Add helper function to get "poweroff-source" property

2014-10-10 Thread Heiko Stübner
Hi Grant, Am Freitag, 10. Oktober 2014, 12:47:08 schrieb Grant Likely: > What I'm more concerned about is the semantics of the property. What > do the generic code paths gain by standardizing this property? Is it > expected that [seems to be missing some text in the original mail] We currently

Re: [RFC PATCH v2 1/4] regulator: Add helper function to get "poweroff-source" property

2014-10-10 Thread PERIER Romain
> > What I'm more concerned about is the semantics of the property. What > do the generic code paths gain by standardizing this property? Is it > expected that We really need to come up with a standard property for this and document it rather than continuing to add individual device specific

Re: [RFC PATCH v2 1/4] regulator: Add helper function to get "poweroff-source" property

2014-10-10 Thread Mark Brown
On Fri, Oct 10, 2014 at 12:47:08PM +0100, Grant Likely wrote: > This is an extremely simple wrapper. It may be best to simply make it > a static inline. It is also generic enough that I don't have a problem > with it living in include/linux/of.h; but of_regulator.h would be fine > too. I think

Re: [RFC PATCH v2 1/4] regulator: Add helper function to get "poweroff-source" property

2014-10-10 Thread Grant Likely
On Tue, Oct 7, 2014 at 8:43 PM, PERIER Romain wrote: > This is not the final location, I have no idea exactly where I might > put this helper function. This is why I ask you your opinion (and > also, this is why that's a proposal) > > 2014-10-07 21:45 GMT+02:00 Romain Perier : >> Several drivers

Re: [RFC PATCH v2 1/4] regulator: Add helper function to get poweroff-source property

2014-10-10 Thread Grant Likely
On Tue, Oct 7, 2014 at 8:43 PM, PERIER Romain romain.per...@gmail.com wrote: This is not the final location, I have no idea exactly where I might put this helper function. This is why I ask you your opinion (and also, this is why that's a proposal) 2014-10-07 21:45 GMT+02:00 Romain Perier

Re: [RFC PATCH v2 1/4] regulator: Add helper function to get poweroff-source property

2014-10-10 Thread Mark Brown
On Fri, Oct 10, 2014 at 12:47:08PM +0100, Grant Likely wrote: This is an extremely simple wrapper. It may be best to simply make it a static inline. It is also generic enough that I don't have a problem with it living in include/linux/of.h; but of_regulator.h would be fine too. I think of.h

Re: [RFC PATCH v2 1/4] regulator: Add helper function to get poweroff-source property

2014-10-10 Thread PERIER Romain
What I'm more concerned about is the semantics of the property. What do the generic code paths gain by standardizing this property? Is it expected that We really need to come up with a standard property for this and document it rather than continuing to add individual device specific

Re: [RFC PATCH v2 1/4] regulator: Add helper function to get poweroff-source property

2014-10-10 Thread Heiko Stübner
Hi Grant, Am Freitag, 10. Oktober 2014, 12:47:08 schrieb Grant Likely: What I'm more concerned about is the semantics of the property. What do the generic code paths gain by standardizing this property? Is it expected that [seems to be missing some text in the original mail] We currently see

Re: [RFC PATCH v2 1/4] regulator: Add helper function to get "poweroff-source" property

2014-10-07 Thread PERIER Romain
This is not the final location, I have no idea exactly where I might put this helper function. This is why I ask you your opinion (and also, this is why that's a proposal) 2014-10-07 21:45 GMT+02:00 Romain Perier : > Several drivers create their own devicetree property when they register >

[RFC PATCH v2 1/4] regulator: Add helper function to get "poweroff-source" property

2014-10-07 Thread Romain Perier
Several drivers create their own devicetree property when they register poweroff capabilities. This is for example the case for mfd, regulator or power drivers which define "vendor,system-power-controller" property. This patch adds support for a standard property "poweroff-source" which marks the

[RFC PATCH v2 1/4] regulator: Add helper function to get poweroff-source property

2014-10-07 Thread Romain Perier
Several drivers create their own devicetree property when they register poweroff capabilities. This is for example the case for mfd, regulator or power drivers which define vendor,system-power-controller property. This patch adds support for a standard property poweroff-source which marks the

Re: [RFC PATCH v2 1/4] regulator: Add helper function to get poweroff-source property

2014-10-07 Thread PERIER Romain
This is not the final location, I have no idea exactly where I might put this helper function. This is why I ask you your opinion (and also, this is why that's a proposal) 2014-10-07 21:45 GMT+02:00 Romain Perier romain.per...@gmail.com: Several drivers create their own devicetree property when