lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <87pp7o2xqg.wl%kuninori.morimoto.gx@renesas.com>
Date:	Wed, 1 Apr 2015 06:02:13 +0000
From:	Kuninori Morimoto <kuninori.morimoto.gx@...esas.com>
To:	Stephen Boyd <sboyd@...eaurora.org>,
	Mike Turquette <mturquette@...aro.org>
CC:	Simon Horman <horms+renesas@...ge.net.au>,
	Linux-SH <linux-sh@...r.kernel.org>,
	Linux-Kernel <linux-kernel@...r.kernel.org>,
	Laurent <laurent.pinchart@...asonboard.com>
Subject: [PATCH] clk: shmobile: r8a7779: check return of of_property_read_string_index()

From: Kuninori Morimoto <kuninori.morimoto.gx@...esas.com>

This patch indicates error message if return value of
of_property_read_string_index() was not zero.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@...esas.com>
---
 drivers/clk/shmobile/clk-r8a7779.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/clk/shmobile/clk-r8a7779.c b/drivers/clk/shmobile/clk-r8a7779.c
index 652ecac..af439b2 100644
--- a/drivers/clk/shmobile/clk-r8a7779.c
+++ b/drivers/clk/shmobile/clk-r8a7779.c
@@ -155,8 +155,10 @@ static void __init r8a7779_cpg_clocks_init(struct device_node *np)
 		const char *name;
 		struct clk *clk;
 
-		of_property_read_string_index(np, "clock-output-names", i,
-					      &name);
+		if (of_property_read_string_index(np, "clock-output-names", i,
+						  &name))
+			pr_err("%s: can't get clock-output-names (%d)\n",
+			       __func__, i);
 
 		clk = r8a7779_cpg_register_clock(np, cpg, config,
 						 plla_mult, name);
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ