All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sakari Ailus <sakari.ailus@iki.fi>
To: Robert Foss <robert.foss@linaro.org>
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
	Marco Felsch <m.felsch@pengutronix.de>,
	Maxime Ripard <maxime@cerno.tech>,
	linux-media@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	Dongchun Zhu <dongchun.zhu@mediatek.com>,
	Fabio Estevam <festevam@gmail.com>,
	Tomasz Figa <tfiga@chromium.org>, Ben Kao <ben.kao@intel.com>
Subject: Re: [PATCH v8 2/3] media: ov8856: Add devicetree support
Date: Tue, 12 May 2020 03:25:18 +0300	[thread overview]
Message-ID: <20200512002518.GX867@valkosipuli.retiisi.org.uk> (raw)
In-Reply-To: <20200511110350.11565-3-robert.foss@linaro.org>

Hi Robert,

On Mon, May 11, 2020 at 01:03:49PM +0200, Robert Foss wrote:
> Add match table, enable ov8856_probe() to support
> both ACPI and DT modes.
> 
> ACPI and DT modes are primarily distinguished from
> by checking for ACPI mode and by having resource like
> be NULL.
> 
> Signed-off-by: Robert Foss <robert.foss@linaro.org>

Applied with this small diff --- please check with checkpatch.pl on the
next time. Thanks!

diff --git a/drivers/media/i2c/ov8856.c b/drivers/media/i2c/ov8856.c
index 1657e03d9a9d..4ca27675cc5a 100644
--- a/drivers/media/i2c/ov8856.c
+++ b/drivers/media/i2c/ov8856.c
@@ -1226,8 +1226,7 @@ static int ov8856_get_hwcfg(struct ov8856 *ov8856, struct device *dev)
 	if (!fwnode)
 		return -ENXIO;
 
-	ret = fwnode_property_read_u32(fwnode, "clock-frequency",
-		&xvclk_rate);
+	ret = fwnode_property_read_u32(fwnode, "clock-frequency", &xvclk_rate);
 	if (ret)
 		return ret;
 
@@ -1244,10 +1243,11 @@ static int ov8856_get_hwcfg(struct ov8856 *ov8856, struct device *dev)
 	}
 
 	if (xvclk_rate != OV8856_XVCLK_19_2)
-		dev_warn(dev, "external clock rate %d is unsupported", xvclk_rate);
+		dev_warn(dev, "external clock rate %u is unsupported",
+			 xvclk_rate);
 
 	ov8856->reset_gpio = devm_gpiod_get_optional(dev, "reset",
-		GPIOD_OUT_LOW);
+						     GPIOD_OUT_LOW);
 	if (IS_ERR(ov8856->reset_gpio))
 		return PTR_ERR(ov8856->reset_gpio);
 
-- 
Kind regards,

Sakari Ailus

WARNING: multiple messages have this Message-ID (diff)
From: Sakari Ailus <sakari.ailus@iki.fi>
To: Robert Foss <robert.foss@linaro.org>
Cc: devicetree@vger.kernel.org, Tomasz Figa <tfiga@chromium.org>,
	Dongchun Zhu <dongchun.zhu@mediatek.com>,
	Marco Felsch <m.felsch@pengutronix.de>,
	linux-kernel@vger.kernel.org, Ben Kao <ben.kao@intel.com>,
	Maxime Ripard <maxime@cerno.tech>,
	Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
	Fabio Estevam <festevam@gmail.com>,
	linux-arm-kernel@lists.infradead.org,
	linux-media@vger.kernel.org
Subject: Re: [PATCH v8 2/3] media: ov8856: Add devicetree support
Date: Tue, 12 May 2020 03:25:18 +0300	[thread overview]
Message-ID: <20200512002518.GX867@valkosipuli.retiisi.org.uk> (raw)
In-Reply-To: <20200511110350.11565-3-robert.foss@linaro.org>

Hi Robert,

On Mon, May 11, 2020 at 01:03:49PM +0200, Robert Foss wrote:
> Add match table, enable ov8856_probe() to support
> both ACPI and DT modes.
> 
> ACPI and DT modes are primarily distinguished from
> by checking for ACPI mode and by having resource like
> be NULL.
> 
> Signed-off-by: Robert Foss <robert.foss@linaro.org>

Applied with this small diff --- please check with checkpatch.pl on the
next time. Thanks!

diff --git a/drivers/media/i2c/ov8856.c b/drivers/media/i2c/ov8856.c
index 1657e03d9a9d..4ca27675cc5a 100644
--- a/drivers/media/i2c/ov8856.c
+++ b/drivers/media/i2c/ov8856.c
@@ -1226,8 +1226,7 @@ static int ov8856_get_hwcfg(struct ov8856 *ov8856, struct device *dev)
 	if (!fwnode)
 		return -ENXIO;
 
-	ret = fwnode_property_read_u32(fwnode, "clock-frequency",
-		&xvclk_rate);
+	ret = fwnode_property_read_u32(fwnode, "clock-frequency", &xvclk_rate);
 	if (ret)
 		return ret;
 
@@ -1244,10 +1243,11 @@ static int ov8856_get_hwcfg(struct ov8856 *ov8856, struct device *dev)
 	}
 
 	if (xvclk_rate != OV8856_XVCLK_19_2)
-		dev_warn(dev, "external clock rate %d is unsupported", xvclk_rate);
+		dev_warn(dev, "external clock rate %u is unsupported",
+			 xvclk_rate);
 
 	ov8856->reset_gpio = devm_gpiod_get_optional(dev, "reset",
-		GPIOD_OUT_LOW);
+						     GPIOD_OUT_LOW);
 	if (IS_ERR(ov8856->reset_gpio))
 		return PTR_ERR(ov8856->reset_gpio);
 
-- 
Kind regards,

Sakari Ailus

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2020-05-12  0:26 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-11 11:03 [PATCH v8 0/3] media: ov8856: Add devicetree support Robert Foss
2020-05-11 11:03 ` Robert Foss
2020-05-11 11:03 ` [PATCH v11 1/3] media: dt-bindings: ov8856: Document YAML bindings Robert Foss
2020-05-11 11:03   ` Robert Foss
2020-05-11 11:03 ` [PATCH v8 2/3] media: ov8856: Add devicetree support Robert Foss
2020-05-11 11:03   ` Robert Foss
2020-05-12  0:25   ` Sakari Ailus [this message]
2020-05-12  0:25     ` Sakari Ailus
2020-05-12  8:13     ` Robert Foss
2020-05-12  8:13       ` Robert Foss
2020-05-11 11:03 ` [PATCH v8 3/3] media: ov8856: Implement sensor module revision identification Robert Foss
2020-05-11 11:03   ` Robert Foss

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=20200512002518.GX867@valkosipuli.retiisi.org.uk \
    --to=sakari.ailus@iki.fi \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=ben.kao@intel.com \
    --cc=devicetree@vger.kernel.org \
    --cc=dongchun.zhu@mediatek.com \
    --cc=festevam@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=m.felsch@pengutronix.de \
    --cc=maxime@cerno.tech \
    --cc=robert.foss@linaro.org \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.