Unexport __clk_of_table
Stephen Boyd
maintainerPATCH 1/2 clk: Remove ifdef for COMMON_CLK in clk-provider.h
In reply to Stephen BoydThis ifdef has been there since the beginning of this file, but it doesn't really seem to serve any purpose besides obfuscating the struct definitions and #defines here from compilation units that include it. Let's always expose these function prototypes and struct definitions so that code can inspect clk providers without needing to have CONFIG_COMMON_CLK enabled.
--- include/linux/clk-provider.h | 3 --- 1 file changed, 3 deletions(-)
include/linux/clk-provider.h +0 -3
@@ -9,8 +9,6 @@#include <linux/of.h> #include <linux/of_clk.h> -#ifdef CONFIG_COMMON_CLK -/* * flags used across common struct clk. these flags should only affect the * top-level framework. custom flags for dealing with hardware specifics
@@ -1019,5 +1017,4 @@ static inline int of_clk_detect_critical(struct device_node *np, int index,void clk_gate_restore_context (struct clk_hw *hw); -#endif /* CONFIG_COMMON_CLK */ #endif /* CLK_PROVIDER_H */
Signature · 1 line
Sent by a computer through tubes
Stephen Boyd
maintainerPATCH 2/2 clk: Unexport __clk_of_table
In reply to Stephen BoydThis symbol doesn't need to be exported to clk providers anymore. Originally, it was hidden inside clk.c, but then OMAP needed to get access to it in commit 819b4861c18d ("CLK: ti: add init support for clock IP blocks"), but eventually that code also changed in commit c08ee14cc663 ("clk: ti: change clock init to use generic of_clk_init") and we were left with this exported. Move this back into clk.c so that it isn't exposed anymore.
--- drivers/clk/clk.c | 1 + include/linux/clk-provider.h | 4 ---- 2 files changed, 1 insertion(+), 4 deletions(-)
drivers/clk/clk.c +1 -0
@@ -4038,6 +4038,7 @@ struct of_clk_provider {void *data; }; +extern struct of_device_id __clk_of_table; static const struct of_device_id __clk_of_table_sentinel__used __section (__clk_of_table_end);
include/linux/clk-provider.h +0 -4
@@ -865,8 +865,6 @@ static inline long divider_ro_round_rate(struct clk_hw *hw, unsigned long rate,*/ unsigned long clk_hw_round_rate (struct clk_hw *hw,unsigned long rate); -struct of_device_id ; -struct clk_onecell_data {struct clk **clks;unsigned int clk_num;
@@ -877,8 +875,6 @@ struct clk_hw_onecell_data {struct clk_hw *hws[]; }; -extern struct of_device_id __clk_of_table; -#define CLK_OF_DECLARE (name, compat, fn) OF_DECLARE_1(clk, name, compat, fn)/*
Signature · 1 line
Sent by a computer through tubes
Stephen Boyd
maintainercover Unexport __clk_of_table
I found this lying around, not sure if I sent it or not.
We don't need to export this symbol anymore. And having COMMON_CLK in clk-provider.h seems to be an artifact. Here's a couple patches to clean this stuff up.
Stephen Boyd (2):
clk: Remove ifdef for COMMON_CLK in clk-provider.h
clk: Unexport __clk_of_table
drivers/clk/clk.c | 1 + include/linux/clk-provider.h | 7 ------- 2 files changed, 1 insertion(+), 7 deletions(-)
Signature · 1 line
Sent by a computer through tubes