diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2017-02-02 10:34:21 +0100 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2017-02-06 07:34:03 +0100 |
commit | 2225c194edc1e2f71c0d8dc1c0c3b936d241060a (patch) | |
tree | 1d258cbdb19d5d9894b2161430d02cca20c1fb3f /include/linux | |
parent | bce79428773b87e0fe84be07048992c98249581a (diff) | |
download | barebox-2225c194edc1e2f71c0d8dc1c0c3b936d241060a.tar.gz barebox-2225c194edc1e2f71c0d8dc1c0c3b936d241060a.tar.xz |
clk: Add support for shared gates
Sometimes a single software control knob controls multiple gates
in hardware. This patch adds support for shared gates which help
coping this situation. The first gate is registered with the hardware
gate as usual, the others are registered as shared gates which does
not have hardware control itself, but only switches the real hardware
gate.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/clk.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/clk.h b/include/linux/clk.h index 697ab4ff4a..7dd52388c5 100644 --- a/include/linux/clk.h +++ b/include/linux/clk.h @@ -296,6 +296,9 @@ struct clk *clk_gate(const char *name, const char *parent, void __iomem *reg, u8 shift, unsigned flags, u8 clk_gate_flags); struct clk *clk_gate_inverted(const char *name, const char *parent, void __iomem *reg, u8 shift, unsigned flags); +struct clk *clk_gate_shared(const char *name, const char *parent, const char *shared, + unsigned flags); + int clk_is_enabled(struct clk *clk); int clk_is_enabled_always(struct clk *clk); |