lkml.org 
[lkml]   [2018]   [Oct]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v3 2/2] [media] imx214: Add imx214 camera sensor driver
Hi Ricardo,

On Wed, Oct 03, 2018 at 09:17:56AM +0200, Ricardo Ribalda Delgado wrote:
> HI Sakari
>
> Thanks a lot for your review!
>
> On Tue, Oct 2, 2018 at 6:27 PM Sakari Ailus
> <sakari.ailus@linux.intel.com> wrote:
> > > +static int imx214_s_power(struct v4l2_subdev *sd, int on)
> > > +{
> > > + struct imx214 *imx214 = to_imx214(sd);
> > > + int ret = 0;
> > > +
> > > + on = !!on;
> > > +
> > > + if (imx214->power_on == on)
> > > + return 0;
> > > +
> > > + if (on)
> > > + ret = imx214_set_power_on(imx214);
> > > + else
> > > + imx214_set_power_off(imx214);
> > > +
> > > + imx214->power_on = on;
> > > +
> > > + return 0;
> >
> > Using runtime PM would relieve you of this function.
>
> Tried using runtime PM, but did not manage to get it working with the
> qcom i2c driver. Will try again when this is merged on a separated
> patch.

Interesting. With runtime PM, also the parent device will be powered on
automatically. Usually that's what's needed after all.

Could you post the changes you made?

--
Sakari Ailus
sakari.ailus@linux.intel.com

\
 
 \ /
  Last update: 2018-10-03 12:41    [W:0.107 / U:0.548 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site