Re: [PATCH 4/8] regulator: da9055: Add DT support

2014-02-06 Thread Mark Brown
On Thu, Feb 06, 2014 at 12:22:13PM +, Opensource [Adam Thomson] wrote: > Is what I summised but I obviously chose the wrong direction for my fix. > Will use platform_get_irq_byname() solely, and will make sure all works on > both DT and non-DT setups. If not I'll dig further. Yeah. In genera

RE: [PATCH 4/8] regulator: da9055: Add DT support

2014-02-06 Thread Opensource [Adam Thomson]
On Thu, Feb 06, 2014 at 12:04:52PM +, Mark Brown wrote: > > Used another driver as an example for this, but if there's a better method > > then I'm happy to use it. Will have a look. > > That's probably an older driver - the code was factored out at some > point but lots of drivers don't get

Re: [PATCH 4/8] regulator: da9055: Add DT support

2014-02-06 Thread Mark Brown
On Thu, Feb 06, 2014 at 11:31:13AM +, Opensource [Adam Thomson] wrote: > On Wed, Feb 05, 2014 at 18:37:21PM +, Mark Brown wrote: > > > + for_each_child_of_node(nproot, np) { > > > + if (!of_node_cmp(np->name, > > > + regulator->info->reg_desc.name)) { > > >

RE: [PATCH 4/8] regulator: da9055: Add DT support

2014-02-06 Thread Opensource [Adam Thomson]
On Wed, Feb 05, 2014 at 18:37:21PM +, Mark Brown wrote: > On Wed, Feb 05, 2014 at 05:48:35PM +, Adam Thomson wrote: > > > +#ifdef CONFIG_OF > > +#include > > +#include > > +#endif /* CONFIG_OF */ > > Don't do ifdefs for includes like this, it's not worth it. Fine. Seen examples of bot

Re: [PATCH 4/8] regulator: da9055: Add DT support

2014-02-05 Thread Mark Brown
On Wed, Feb 05, 2014 at 05:48:35PM +, Adam Thomson wrote: > +#ifdef CONFIG_OF > +#include > +#include > +#endif /* CONFIG_OF */ Don't do ifdefs for includes like this, it's not worth it. > + for_each_child_of_node(nproot, np) { > + if (!of_node_cmp(np->name, > +

[PATCH 4/8] regulator: da9055: Add DT support

2014-02-05 Thread Adam Thomson
Signed-off-by: Adam Thomson --- drivers/regulator/da9055-regulator.c | 59 +++--- 1 files changed, 54 insertions(+), 5 deletions(-) diff --git a/drivers/regulator/da9055-regulator.c b/drivers/regulator/da9055-regulator.c index 7f34020..bc41137 100644 --- a/drivers