Commit 6b44c854 authored by Sachin Kamat's avatar Sachin Kamat Committed by Mike Turquette

clk: Fix build warnings

‘all_lists’ and ‘orphan_list’ is accessed only when DEBUG_FS is defined.
Thus, make their compilation conditional to fix the below warnings introduced
by commit 27b8d5f7 ("clk: flatten clk tree in debugfs"):
drivers/clk/clk.c:40:27: warning: ‘all_lists’ defined but not used [-Wunused-variable]
drivers/clk/clk.c:46:27: warning: ‘orphan_list’ defined but not used [-Wunused-variable]
Signed-off-by: default avatarSachin Kamat <sachin.kamat@samsung.com>
Cc: Peter De Schrijver <pdeschrijver@nvidia.com>
Signed-off-by: default avatarMike Turquette <mturquette@linaro.org>
parent da788acb
...@@ -36,17 +36,6 @@ static HLIST_HEAD(clk_root_list); ...@@ -36,17 +36,6 @@ static HLIST_HEAD(clk_root_list);
static HLIST_HEAD(clk_orphan_list); static HLIST_HEAD(clk_orphan_list);
static LIST_HEAD(clk_notifier_list); static LIST_HEAD(clk_notifier_list);
static struct hlist_head *all_lists[] = {
&clk_root_list,
&clk_orphan_list,
NULL,
};
static struct hlist_head *orphan_list[] = {
&clk_orphan_list,
NULL,
};
/*** locking ***/ /*** locking ***/
static void clk_prepare_lock(void) static void clk_prepare_lock(void)
{ {
...@@ -111,6 +100,17 @@ static void clk_enable_unlock(unsigned long flags) ...@@ -111,6 +100,17 @@ static void clk_enable_unlock(unsigned long flags)
static struct dentry *rootdir; static struct dentry *rootdir;
static int inited = 0; static int inited = 0;
static struct hlist_head *all_lists[] = {
&clk_root_list,
&clk_orphan_list,
NULL,
};
static struct hlist_head *orphan_list[] = {
&clk_orphan_list,
NULL,
};
static void clk_summary_show_one(struct seq_file *s, struct clk *c, int level) static void clk_summary_show_one(struct seq_file *s, struct clk *c, int level)
{ {
if (!c) if (!c)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment