devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Hans Verkuil <hverkuil@xs4all.nl>
To: Sakari Ailus <sakari.ailus@linux.intel.com>
Cc: Michael Tretter <m.tretter@pengutronix.de>,
	Rob Herring <robh+dt@kernel.org>,
	Mauro Carvalho Chehab <mchehab@kernel.org>,
	p.zabel@pengutronix.de, Ian Arkver <ian.arkver.dev@gmail.com>,
	kernel@pengutronix.de, linux-media@vger.kernel.org,
	devicetree@vger.kernel.org, Marek Vasut <marex@denx.de>
Subject: Re: [PATCH v10 2/2] media: i2c: isl7998x: Add driver for Intersil ISL7998x
Date: Wed, 23 Feb 2022 14:04:48 +0100	[thread overview]
Message-ID: <2c0b387c-d636-bc0c-74b1-f1eba3d89254@xs4all.nl> (raw)
In-Reply-To: <YhYuogHaHuyVPd2C@paasikivi.fi.intel.com>

On 2/23/22 13:54, Sakari Ailus wrote:
> Hi Hans, Michael,
> 
> On Wed, Feb 23, 2022 at 02:16:28PM +0200, Sakari Ailus wrote:
>>>> +static int isl7998x_pre_streamon(struct v4l2_subdev *sd, u32 flags)
>>>> +{
>>>> +	struct i2c_client *client = v4l2_get_subdevdata(sd);
>>>> +	struct device *dev = &client->dev;
>>>> +
>>>> +	if (flags & V4L2_SUBDEV_PRE_STREAMON_FL_MANUAL_LP)
>>>> +		return pm_runtime_resume_and_get(dev);
>>>> +
>>>> +	return 0;
>>>
>>> This feels a bit scary: if V4L2_SUBDEV_PRE_STREAMON_FL_MANUAL_LP is NOT
>>> set, then pm_runtime_resume_and_get() isn't called, but this function
>>> still returns success...
>>
>> Good find.
>>
>> pm_runtime_resume_and_get() need to be called unconditionally.
>>
>> Alternatively, store what was done here, and put the PM use count
>> accordingly below. But I see no reason to do that.
> 
> But I think the driver is otherwise good to go.
> 
> Unless there are objections, I'll drop the check in the pre_streamon()
> callback and apply it into my tree.
> 

OK, with that change you can add my:

Acked-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>

to this patch. I'll delegate the series to you in patchwork.

Regards,

	Hans

  reply	other threads:[~2022-02-23 13:04 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-17 15:44 [PATCH v10 0/2] media: i2c: isl7998x: Add driver for Intersil ISL7998x Michael Tretter
2022-02-17 15:44 ` [PATCH v10 1/2] media: dt-bindings: Add Intersil ISL79987 DT bindings Michael Tretter
2022-02-17 15:44 ` [PATCH v10 2/2] media: i2c: isl7998x: Add driver for Intersil ISL7998x Michael Tretter
2022-02-23 11:51   ` Hans Verkuil
2022-02-23 12:16     ` Sakari Ailus
2022-02-23 12:54       ` Sakari Ailus
2022-02-23 13:04         ` Hans Verkuil [this message]
2022-02-23 14:18           ` Sakari Ailus
2022-02-24 14:22   ` Sakari Ailus
2022-02-24 16:00     ` [PATCH] fixup! " Michael Tretter
2022-02-25 11:06       ` Sakari Ailus

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=2c0b387c-d636-bc0c-74b1-f1eba3d89254@xs4all.nl \
    --to=hverkuil@xs4all.nl \
    --cc=devicetree@vger.kernel.org \
    --cc=ian.arkver.dev@gmail.com \
    --cc=kernel@pengutronix.de \
    --cc=linux-media@vger.kernel.org \
    --cc=m.tretter@pengutronix.de \
    --cc=marex@denx.de \
    --cc=mchehab@kernel.org \
    --cc=p.zabel@pengutronix.de \
    --cc=robh+dt@kernel.org \
    --cc=sakari.ailus@linux.intel.com \
    /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;
as well as URLs for NNTP newsgroup(s).