* [PATCH v1 1/1] media: i2c: imx290: Use device_property_read_u32() directly
@ 2023-02-08 11:33 Andy Shevchenko
2023-02-08 15:27 ` Laurent Pinchart
0 siblings, 1 reply; 2+ messages in thread
From: Andy Shevchenko @ 2023-02-08 11:33 UTC (permalink / raw)
To: Sakari Ailus, Laurent Pinchart, Alexander Stein, linux-media,
linux-kernel
Cc: Manivannan Sadhasivam, Mauro Carvalho Chehab, Andy Shevchenko
No need to call fwnode_property_read_u32(dev_fwnode()), when
we have already existing helper. So use it.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
drivers/media/i2c/imx290.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/media/i2c/imx290.c b/drivers/media/i2c/imx290.c
index 330098a0772d..e7aa2ecdcc88 100644
--- a/drivers/media/i2c/imx290.c
+++ b/drivers/media/i2c/imx290.c
@@ -1137,8 +1137,7 @@ static int imx290_init_clk(struct imx290 *imx290)
u32 xclk_freq;
int ret;
- ret = fwnode_property_read_u32(dev_fwnode(imx290->dev),
- "clock-frequency", &xclk_freq);
+ ret = device_property_read_u32(imx290->dev, "clock-frequency", &xclk_freq);
if (ret) {
dev_err(imx290->dev, "Could not get xclk frequency\n");
return ret;
--
2.39.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH v1 1/1] media: i2c: imx290: Use device_property_read_u32() directly
2023-02-08 11:33 [PATCH v1 1/1] media: i2c: imx290: Use device_property_read_u32() directly Andy Shevchenko
@ 2023-02-08 15:27 ` Laurent Pinchart
0 siblings, 0 replies; 2+ messages in thread
From: Laurent Pinchart @ 2023-02-08 15:27 UTC (permalink / raw)
To: Andy Shevchenko
Cc: Sakari Ailus, Alexander Stein, linux-media, linux-kernel,
Manivannan Sadhasivam, Mauro Carvalho Chehab
Hi Andy,
Thank you for the patch.
On Wed, Feb 08, 2023 at 01:33:48PM +0200, Andy Shevchenko wrote:
> No need to call fwnode_property_read_u32(dev_fwnode()), when
> we have already existing helper. So use it.
>
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> ---
> drivers/media/i2c/imx290.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/drivers/media/i2c/imx290.c b/drivers/media/i2c/imx290.c
> index 330098a0772d..e7aa2ecdcc88 100644
> --- a/drivers/media/i2c/imx290.c
> +++ b/drivers/media/i2c/imx290.c
> @@ -1137,8 +1137,7 @@ static int imx290_init_clk(struct imx290 *imx290)
> u32 xclk_freq;
> int ret;
>
> - ret = fwnode_property_read_u32(dev_fwnode(imx290->dev),
> - "clock-frequency", &xclk_freq);
> + ret = device_property_read_u32(imx290->dev, "clock-frequency", &xclk_freq);
I'd break the line here.
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> if (ret) {
> dev_err(imx290->dev, "Could not get xclk frequency\n");
> return ret;
--
Regards,
Laurent Pinchart
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-02-08 15:27 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-02-08 11:33 [PATCH v1 1/1] media: i2c: imx290: Use device_property_read_u32() directly Andy Shevchenko
2023-02-08 15:27 ` Laurent Pinchart
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox