Thread (10 messages) 10 messages, 3 authors, 2019-02-06

RE: [PATCH v9 1/2] clk: Add comment about __of_clk_get_by_name() error values

From: Phil Edworthy <hidden>
Date: 2019-01-16 15:18:51
Also in: linux-clk, lkml

Hi,

Any other comments on this patch and patch 2/2 (https://lkml.org/lkml/2018/12/3/326)?

Thanks
Phil
-----Original Message-----
From: Phil Edworthy
Sent: 06 December 2018 12:31
To: 'Andy Shevchenko' <andriy.shevchenko@linux.intel.com>
Cc: Michael Turquette <mturquette@baylibre.com>; Stephen Boyd
[off-list ref]; Russell King [off-list ref]; Geert
Uytterhoeven [off-list ref]; Uwe Kleine-König <u.kleine-
koenig@pengutronix.de>; linux-clk@vger.kernel.org; linux-
kernel@vger.kernel.org; linux-arm-kernel@lists.infradead.org
Subject: RE: [PATCH v9 1/2] clk: Add comment about
__of_clk_get_by_name() error values

Hi Andy,

On 03 December 2018 13:31 Andy Shevchenko wrote:
quoted
On Mon, Dec 03, 2018 at 11:13:08AM +0000, Phil Edworthy wrote:
quoted
It's not immediately obvious from the code that failure to get a
clock provider can return either -ENOENT or -EINVAL. Therefore, add
a comment to highlight this.
quoted
+/*
+ * Beware the return values when np is valid, but no clock provider
+is
found.
quoted
+ * If name = NULL, the function returns -ENOENT.
+ * If name != NULL, the function returns -EINVAL. This is because
+__of_clk_get()
I would start new sentence from new line (this will emphasize the
possible
variants)

 * This is ...
I disagree, the explanation is specifically related to the case where the
function returns -EINVAL. Though this is a nit, so I'm not really bothered
either way.

Thanks for the review!
Phil
quoted
 Otherwise looks good to me:

Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
quoted
+ * is called even if of_property_match_string() returns an error.
+ */
 static struct clk *__of_clk_get_by_name(struct device_node *np,
 					const char *dev_id,
 					const char *name)
--
2.17.1
--
With Best Regards,
Andy Shevchenko

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help