593dab94f8e87e6b8db8a06ea9e94f000d1a465e
[openwrt/staging/blocktrron.git] /
1 From 6555dd4a687f121572a91ad9333a81991be8b266 Mon Sep 17 00:00:00 2001
2 From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
3 Date: Fri, 10 Feb 2023 00:09:54 +0200
4 Subject: [PATCH] media: i2c: imx290: Use device_property_read_u32()
5 directly
6
7 Should be upstream commit 971458482809
8
9 No need to call fwnode_property_read_u32(dev_fwnode()), when
10 we have already existing helper. So use it.
11
12 Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
13 Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
14 Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
15 ---
16 drivers/media/i2c/imx290.c | 4 ++--
17 1 file changed, 2 insertions(+), 2 deletions(-)
18
19 --- a/drivers/media/i2c/imx290.c
20 +++ b/drivers/media/i2c/imx290.c
21 @@ -1137,8 +1137,8 @@ static int imx290_init_clk(struct imx290
22 u32 xclk_freq;
23 int ret;
24
25 - ret = fwnode_property_read_u32(dev_fwnode(imx290->dev),
26 - "clock-frequency", &xclk_freq);
27 + ret = device_property_read_u32(imx290->dev, "clock-frequency",
28 + &xclk_freq);
29 if (ret) {
30 dev_err(imx290->dev, "Could not get xclk frequency\n");
31 return ret;