devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dongchun Zhu <dongchun.zhu@mediatek.com>
To: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: <mchehab@kernel.org>, <robh+dt@kernel.org>,
	<mark.rutland@arm.com>, <sakari.ailus@linux.intel.com>,
	<drinkcat@chromium.org>, <tfiga@chromium.org>,
	<matthias.bgg@gmail.com>, <bingbu.cao@intel.com>,
	<srv_heupstream@mediatek.com>,
	<linux-mediatek@lists.infradead.org>,
	<linux-arm-kernel@lists.infradead.org>, <sj.huang@mediatek.com>,
	<linux-media@vger.kernel.org>, <devicetree@vger.kernel.org>,
	<louis.kuo@mediatek.com>, <shengnan.wang@mediatek.com>
Subject: Re: [V4, 2/2] media: i2c: Add DW9768 VCM driver
Date: Tue, 31 Mar 2020 10:16:20 +0800	[thread overview]
Message-ID: <1585620980.5781.80.camel@mhfsdcap03> (raw)
In-Reply-To: <20200330135751.GQ1922688@smile.fi.intel.com>

Hi Andy,

Thanks for the review.

On Mon, 2020-03-30 at 16:57 +0300, Andy Shevchenko wrote:
> On Mon, Mar 30, 2020 at 08:36:34PM +0800, Dongchun Zhu wrote:
> > This patch adds a V4L2 sub-device driver for DW9768 voice coil moter,
> > providing control to set the desired focus via I2C serial interface.
> 
> ...
> 
> > +static const struct dev_pm_ops dw9768_pm_ops = {
> > +	SET_SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend,
> > +				pm_runtime_force_resume)
> > +	SET_RUNTIME_PM_OPS(dw9768_runtime_suspend, dw9768_runtime_resume, NULL)
> > +};
> > +
> > +static struct i2c_driver dw9768_i2c_driver = {
> > +	.driver = {
> > +		.name = DW9768_NAME,
> 
> > +		.pm = IS_ENABLED(CONFIG_PM) ? &dw9768_pm_ops : NULL,
> 
> What is this conditional for?
> 

For the dw9768_pm_ops, here my idea is to use an IS_ENABLED() check to
avoid defining the structure when CONFIG_PM is not set.

> > +		.of_match_table = dw9768_of_table,
> > +	},
> > +	.probe_new  = dw9768_probe,
> > +	.remove = dw9768_remove,
> > +};
> 
> > +
> 
> Extra blank line.
> 

Weird, most V4L2 driver(I2C client) seems to keep this blank line.
Sakari, is it still the case or am I mistaken?

> > +module_i2c_driver(dw9768_i2c_driver);
> 


  reply	other threads:[~2020-03-31  2:16 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-30 12:36 [V4, 0/2] media: i2c: add support for DW9768 VCM driver Dongchun Zhu
2020-03-30 12:36 ` [V4, 1/2] media: i2c: dw9768: Add DT support and MAINTAINERS entry Dongchun Zhu
2020-04-10 17:25   ` Rob Herring
2020-04-30  8:42     ` Dongchun Zhu
2020-03-30 12:36 ` [V4, 2/2] media: i2c: Add DW9768 VCM driver Dongchun Zhu
2020-03-30 13:57   ` Andy Shevchenko
2020-03-31  2:16     ` Dongchun Zhu [this message]
2020-03-31 10:14       ` Andy Shevchenko
2020-04-30  8:47         ` Dongchun Zhu
2020-04-02 12:32   ` Sakari Ailus
2020-04-30 10:15     ` Dongchun Zhu

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=1585620980.5781.80.camel@mhfsdcap03 \
    --to=dongchun.zhu@mediatek.com \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=bingbu.cao@intel.com \
    --cc=devicetree@vger.kernel.org \
    --cc=drinkcat@chromium.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-media@vger.kernel.org \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=louis.kuo@mediatek.com \
    --cc=mark.rutland@arm.com \
    --cc=matthias.bgg@gmail.com \
    --cc=mchehab@kernel.org \
    --cc=robh+dt@kernel.org \
    --cc=sakari.ailus@linux.intel.com \
    --cc=shengnan.wang@mediatek.com \
    --cc=sj.huang@mediatek.com \
    --cc=srv_heupstream@mediatek.com \
    --cc=tfiga@chromium.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;
as well as URLs for NNTP newsgroup(s).