From: Jonathan Cameron <jic23@kernel.org>
To: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Cc: Matt Ranostay <matt.ranostay@konsulko.com>,
"open list:IIO SUBSYSTEM AND DRIVERS" <linux-iio@vger.kernel.org>,
Jonathan Cameron <Jonathan.Cameron@huawei.com>
Subject: Re: [PATCH v2 5/6] iio: prox: pulsed-light-v2: Use pm_runtime_resume_and_get()
Date: Wed, 16 Jun 2021 13:55:23 +0100 [thread overview]
Message-ID: <20210616135523.0a5a509d@jic23-huawei> (raw)
In-Reply-To: <20210616091913.644e303f@coco.lan>
On Wed, 16 Jun 2021 09:19:13 +0200
Mauro Carvalho Chehab <mchehab+huawei@kernel.org> wrote:
> Em Sun, 16 May 2021 13:01:29 -0700
> Matt Ranostay <matt.ranostay@konsulko.com> escreveu:
>
> > On Sun, May 16, 2021 at 9:22 AM Jonathan Cameron <jic23@kernel.org> wrote:
> > >
> > > From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > >
> > > Using this new call makes it easy to handle any errors as a result
> > > of runtime resume as it exits without leaving the reference count
> > > elevated.
> > >
> >
> > Acked-by: Matt Ranostay <matt.ranostay@konsulko.com>
>
> LGTM.
>
> Reviewed-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Applied.
>
> >
> > > Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > > Cc: Matt Ranostay <matt.ranostay@konsulko.com>
> > > ---
> > > drivers/iio/proximity/pulsedlight-lidar-lite-v2.c | 4 +++-
> > > 1 file changed, 3 insertions(+), 1 deletion(-)
> > >
> > > diff --git a/drivers/iio/proximity/pulsedlight-lidar-lite-v2.c b/drivers/iio/proximity/pulsedlight-lidar-lite-v2.c
> > > index ecaeb1e11007..e94f63932edb 100644
> > > --- a/drivers/iio/proximity/pulsedlight-lidar-lite-v2.c
> > > +++ b/drivers/iio/proximity/pulsedlight-lidar-lite-v2.c
> > > @@ -158,7 +158,9 @@ static int lidar_get_measurement(struct lidar_data *data, u16 *reg)
> > > int tries = 10;
> > > int ret;
> > >
> > > - pm_runtime_get_sync(&client->dev);
> > > + ret = pm_runtime_resume_and_get(&client->dev);
> > > + if (ret < 0)
> > > + return ret;
> > >
> > > /* start sample */
> > > ret = lidar_write_control(data, LIDAR_REG_CONTROL_ACQUIRE);
> > > --
> > > 2.31.1
> > >
>
>
>
> Thanks,
> Mauro
next prev parent reply other threads:[~2021-06-16 12:53 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-16 16:20 [PATCH v2 0/6] IIO: Runtime PM related cleanups Jonathan Cameron
2021-05-16 16:20 ` [PATCH v2 1/6] iio: imu: mpu6050: Balance runtime pm + use pm_runtime_resume_and_get() Jonathan Cameron
2021-06-16 7:15 ` Mauro Carvalho Chehab
2021-06-16 12:45 ` Jonathan Cameron
2021-05-16 16:20 ` [PATCH v2 2/6] iio: adc: ads1015: Balance runtime pm + pm_runtime_resume_and_get() Jonathan Cameron
2021-06-16 7:15 ` Mauro Carvalho Chehab
2021-06-16 12:46 ` Jonathan Cameron
2021-05-16 16:21 ` [PATCH v2 3/6] iio: chemical: atlas-sensor: " Jonathan Cameron
2021-05-16 19:59 ` Matt Ranostay
2021-06-16 7:16 ` Mauro Carvalho Chehab
2021-06-16 12:47 ` Jonathan Cameron
2021-05-16 16:21 ` [PATCH v2 4/6] iio: prox: pulsed-light-v2: Fix misbalance runtime pm in error path Jonathan Cameron
2021-05-16 19:59 ` Matt Ranostay
2021-06-16 7:18 ` Mauro Carvalho Chehab
2021-06-16 12:54 ` Jonathan Cameron
2021-05-16 16:21 ` [PATCH v2 5/6] iio: prox: pulsed-light-v2: Use pm_runtime_resume_and_get() Jonathan Cameron
2021-05-16 20:01 ` Matt Ranostay
2021-06-16 7:19 ` Mauro Carvalho Chehab
2021-06-16 12:55 ` Jonathan Cameron [this message]
2021-05-16 16:21 ` [PATCH v2 6/6] iio: pressure: icp10100: Balance runtime pm + use pm_runtime_resume_and_get() Jonathan Cameron
2021-06-16 7:16 ` Mauro Carvalho Chehab
2021-06-16 12:56 ` Jonathan Cameron
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210616135523.0a5a509d@jic23-huawei \
--to=jic23@kernel.org \
--cc=Jonathan.Cameron@huawei.com \
--cc=linux-iio@vger.kernel.org \
--cc=matt.ranostay@konsulko.com \
--cc=mchehab+huawei@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox