Commit a3a2d78b authored by Lee Jones's avatar Lee Jones Committed by Stephen Boyd

clk: st: clkgen-fsyn: Detect critical clocks

Utilise the new Critical Clock infrastructure to mark clocks which
much not be disabled as CRITICAL.

Clocks are marked as CRITICAL using clk flags.  This patch also
ensures flags are peculated through the framework in the correct
manner.
Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
Signed-off-by: default avatarStephen Boyd <sboyd@codeaurora.org>
parent fa6415af
...@@ -1027,7 +1027,7 @@ static const struct clk_ops st_quadfs_ops = { ...@@ -1027,7 +1027,7 @@ static const struct clk_ops st_quadfs_ops = {
static struct clk * __init st_clk_register_quadfs_fsynth( static struct clk * __init st_clk_register_quadfs_fsynth(
const char *name, const char *parent_name, const char *name, const char *parent_name,
struct clkgen_quadfs_data *quadfs, void __iomem *reg, u32 chan, struct clkgen_quadfs_data *quadfs, void __iomem *reg, u32 chan,
spinlock_t *lock) unsigned long flags, spinlock_t *lock)
{ {
struct st_clk_quadfs_fsynth *fs; struct st_clk_quadfs_fsynth *fs;
struct clk *clk; struct clk *clk;
...@@ -1045,7 +1045,7 @@ static struct clk * __init st_clk_register_quadfs_fsynth( ...@@ -1045,7 +1045,7 @@ static struct clk * __init st_clk_register_quadfs_fsynth(
init.name = name; init.name = name;
init.ops = &st_quadfs_ops; init.ops = &st_quadfs_ops;
init.flags = CLK_GET_RATE_NOCACHE | CLK_IS_BASIC; init.flags = flags | CLK_GET_RATE_NOCACHE | CLK_IS_BASIC;
init.parent_names = &parent_name; init.parent_names = &parent_name;
init.num_parents = 1; init.num_parents = 1;
...@@ -1115,6 +1115,7 @@ static void __init st_of_create_quadfs_fsynths( ...@@ -1115,6 +1115,7 @@ static void __init st_of_create_quadfs_fsynths(
for (fschan = 0; fschan < QUADFS_MAX_CHAN; fschan++) { for (fschan = 0; fschan < QUADFS_MAX_CHAN; fschan++) {
struct clk *clk; struct clk *clk;
const char *clk_name; const char *clk_name;
unsigned long flags = 0;
if (of_property_read_string_index(np, "clock-output-names", if (of_property_read_string_index(np, "clock-output-names",
fschan, &clk_name)) { fschan, &clk_name)) {
...@@ -1127,8 +1128,11 @@ static void __init st_of_create_quadfs_fsynths( ...@@ -1127,8 +1128,11 @@ static void __init st_of_create_quadfs_fsynths(
if (*clk_name == '\0') if (*clk_name == '\0')
continue; continue;
of_clk_detect_critical(np, fschan, &flags);
clk = st_clk_register_quadfs_fsynth(clk_name, pll_name, clk = st_clk_register_quadfs_fsynth(clk_name, pll_name,
quadfs, reg, fschan, lock); quadfs, reg, fschan,
flags, lock);
/* /*
* If there was an error registering this clock output, clean * If there was an error registering this clock output, clean
......
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