Re: [PATCH 1/1] smiapp: Implement power-on and power-off sequences without runtime PM

2016-11-28 Thread Alan Stern
On Mon, 28 Nov 2016, Laurent Pinchart wrote: > > Well, I admit it would be nicer if drivers didn't have to worry about > > whether or not CONFIG_PM was enabled. A slightly cleaner approach > > from the one outlined above would have the probe routine do this: > > > > my_power_up(dev); > >

Re: [PATCH 1/1] smiapp: Implement power-on and power-off sequences without runtime PM

2016-11-27 Thread Laurent Pinchart
Hi Alan, On Saturday 26 Nov 2016 15:10:28 Alan Stern wrote: > On Fri, 25 Nov 2016, Laurent Pinchart wrote: > > On Friday 25 Nov 2016 10:21:21 Alan Stern wrote: > >> On Fri, 25 Nov 2016, Sakari Ailus wrote: > >>> On Thu, Nov 24, 2016 at 09:15:39PM -0500, Alan Stern wrote: > On Fri, 25 Nov 2016

Re: [PATCH 1/1] smiapp: Implement power-on and power-off sequences without runtime PM

2016-11-26 Thread Alan Stern
On Fri, 25 Nov 2016, Laurent Pinchart wrote: > Hi Alan, Hello. > On Friday 25 Nov 2016 10:21:21 Alan Stern wrote: > > On Fri, 25 Nov 2016, Sakari Ailus wrote: > > > On Thu, Nov 24, 2016 at 09:15:39PM -0500, Alan Stern wrote: > > >> On Fri, 25 Nov 2016, Laurent Pinchart wrote: > > >>> Dear linux-

Re: [PATCH 1/1] smiapp: Implement power-on and power-off sequences without runtime PM

2016-11-25 Thread Laurent Pinchart
Hi Alan, On Friday 25 Nov 2016 10:21:21 Alan Stern wrote: > On Fri, 25 Nov 2016, Sakari Ailus wrote: > > On Thu, Nov 24, 2016 at 09:15:39PM -0500, Alan Stern wrote: > >> On Fri, 25 Nov 2016, Laurent Pinchart wrote: > >>> Dear linux-pm developers, what's the suggested way to ensure that a > >>> run

Re: [PATCH 1/1] smiapp: Implement power-on and power-off sequences without runtime PM

2016-11-25 Thread Alan Stern
On Fri, 25 Nov 2016, Sakari Ailus wrote: > Hi Alan and others, > > On Thu, Nov 24, 2016 at 09:15:39PM -0500, Alan Stern wrote: > > On Fri, 25 Nov 2016, Laurent Pinchart wrote: > > > > > Dear linux-pm developers, what's the suggested way to ensure that a > > > runtime- > > > pm-enabled driver ca

Re: [PATCH 1/1] smiapp: Implement power-on and power-off sequences without runtime PM

2016-11-24 Thread Sakari Ailus
Hi Alan and others, On Thu, Nov 24, 2016 at 09:15:39PM -0500, Alan Stern wrote: > On Fri, 25 Nov 2016, Laurent Pinchart wrote: > > > Dear linux-pm developers, what's the suggested way to ensure that a runtime- > > pm-enabled driver can run fine on a system with CONFIG_PM disabled ? > > The exact

Re: [PATCH 1/1] smiapp: Implement power-on and power-off sequences without runtime PM

2016-11-24 Thread Alan Stern
On Fri, 25 Nov 2016, Laurent Pinchart wrote: > Dear linux-pm developers, what's the suggested way to ensure that a runtime- > pm-enabled driver can run fine on a system with CONFIG_PM disabled ? The exact point of your question isn't entirely clear. In the most literal sense, the best ways to e

Re: [PATCH 1/1] smiapp: Implement power-on and power-off sequences without runtime PM

2016-11-24 Thread Laurent Pinchart
Hello, (CC'ing the linux-pm mailing list) On Tuesday 22 Nov 2016 21:58:32 Arnd Bergmann wrote: > On Tuesday, November 22, 2016 8:31:42 PM CET Laurent Pinchart wrote: > >>> @@ -2915,7 +2906,11 @@ static int smiapp_probe(struct i2c_client > >>> *client, > >>> > >>> pm_runtime_enable(&client->d

Re: [PATCH 1/1] smiapp: Implement power-on and power-off sequences without runtime PM

2016-11-22 Thread Arnd Bergmann
On Tuesday, November 22, 2016 8:31:42 PM CET Laurent Pinchart wrote: > > > @@ -2915,7 +2906,11 @@ static int smiapp_probe(struct i2c_client *client, > > > > > > pm_runtime_enable(&client->dev); > > > > > > +#ifdef CONFIG_PM > > > rval = pm_runtime_get_sync(&client->dev); > > > +#else > >

Re: [PATCH 1/1] smiapp: Implement power-on and power-off sequences without runtime PM

2016-11-22 Thread Laurent Pinchart
Hi Arnd, On Friday 18 Nov 2016 17:09:01 Arnd Bergmann wrote: > On Friday, November 18, 2016 3:50:16 PM CET Sakari Ailus wrote: > > Power on the sensor when the module is loaded and power it off when it is > > removed. > > > > Signed-off-by: Sakari Ailus > > --- > > Hi Arnd and others, > > > > T

Re: [PATCH 1/1] smiapp: Implement power-on and power-off sequences without runtime PM

2016-11-18 Thread Arnd Bergmann
On Friday, November 18, 2016 3:50:16 PM CET Sakari Ailus wrote: > Power on the sensor when the module is loaded and power it off when it is > removed. > > Signed-off-by: Sakari Ailus > --- > Hi Arnd and others, > > The patch is tested with CONFIG_PM set, as the system does I was testing > on did

[PATCH 1/1] smiapp: Implement power-on and power-off sequences without runtime PM

2016-11-18 Thread Sakari Ailus
Power on the sensor when the module is loaded and power it off when it is removed. Signed-off-by: Sakari Ailus --- Hi Arnd and others, The patch is tested with CONFIG_PM set, as the system does I was testing on did not boot with CONFIG_PM disabled. I'm not really too worried about this though, t