Commit fc04f27d authored by Arnd Bergmann's avatar Arnd Bergmann Committed by Stephen Boyd

clk: ti: fix building without legacy omap3

When CONFIG_ATAGS or CONFIG_OMAP3 is disabled, we get a build error:

In file included from include/linux/clk-provider.h:15:0,
                 from drivers/clk/ti/clk.c:19:
drivers/clk/ti/clk.c: In function 'ti_clk_add_aliases':
drivers/clk/ti/clk.c:438:29: error: 'simple_clk_match_table' undeclared (first use in this function); did you mean 'simple_attr_write'?

Moving the match table down fixes it.

Fixes: c17435c5 ("clk: ti: add API for creating aliases automatically for simple clock types")
Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
Acked-by: default avatarTero Kristo <t-kristo@ti.com>
Signed-off-by: default avatarStephen Boyd <sboyd@codeaurora.org>
parent 2158a093
...@@ -371,12 +371,6 @@ struct clk __init *ti_clk_register_clk(struct ti_clk *setup) ...@@ -371,12 +371,6 @@ struct clk __init *ti_clk_register_clk(struct ti_clk *setup)
return clk; return clk;
} }
static const struct of_device_id simple_clk_match_table[] __initconst = {
{ .compatible = "fixed-clock" },
{ .compatible = "fixed-factor-clock" },
{ }
};
int __init ti_clk_register_legacy_clks(struct ti_clk_alias *clks) int __init ti_clk_register_legacy_clks(struct ti_clk_alias *clks)
{ {
struct clk *clk; struct clk *clk;
...@@ -425,6 +419,12 @@ int __init ti_clk_register_legacy_clks(struct ti_clk_alias *clks) ...@@ -425,6 +419,12 @@ int __init ti_clk_register_legacy_clks(struct ti_clk_alias *clks)
} }
#endif #endif
static const struct of_device_id simple_clk_match_table[] __initconst = {
{ .compatible = "fixed-clock" },
{ .compatible = "fixed-factor-clock" },
{ }
};
/** /**
* ti_clk_add_aliases - setup clock aliases * ti_clk_add_aliases - setup clock aliases
* *
......
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