diff options
author | Rajendra Nayak <rnayak@codeaurora.org> | 2015-08-06 12:37:45 +0200 |
---|---|---|
committer | Stephen Boyd <sboyd@codeaurora.org> | 2015-09-17 00:22:40 +0200 |
commit | 3c53f5e2179874441a1741ec7bcbaa92fcec9c79 (patch) | |
tree | aeae5905dbba90978553308f31a7f72cbc5ba129 /drivers/clk/qcom/gdsc.h | |
parent | clk: qcom: gdsc: Add support for Memory RET/OFF (diff) | |
download | linux-3c53f5e2179874441a1741ec7bcbaa92fcec9c79.tar.xz linux-3c53f5e2179874441a1741ec7bcbaa92fcec9c79.zip |
clk: qcom: gdsc: Add support for ON only state
Certain devices can have GDSCs' which support ON as the only state.
They can't be power collapsed to either hit RET or OFF.
The clients drivers for these GDSCs' however would expect the state
of the core to be reset following a GDSC disable and re-enable.
To do this assert/deassert reset lines every time the client
driver would request the GDSC to be powered on/off instead.
Signed-off-by: Rajendra Nayak <rnayak@codeaurora.org>
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
Diffstat (limited to '')
-rw-r--r-- | drivers/clk/qcom/gdsc.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/drivers/clk/qcom/gdsc.h b/drivers/clk/qcom/gdsc.h index 0ff251a5523f..5ded26884f08 100644 --- a/drivers/clk/qcom/gdsc.h +++ b/drivers/clk/qcom/gdsc.h @@ -18,6 +18,7 @@ #include <linux/pm_domain.h> struct regmap; +struct reset_controller_dev; /* Powerdomain allowable state bitfields */ #define PWRSTS_OFF BIT(0) @@ -34,6 +35,9 @@ struct regmap; * @cxcs: offsets of branch registers to toggle mem/periph bits in * @cxc_count: number of @cxcs * @pwrsts: Possible powerdomain power states + * @resets: ids of resets associated with this gdsc + * @reset_count: number of @resets + * @rcdev: reset controller */ struct gdsc { struct generic_pm_domain pd; @@ -42,13 +46,18 @@ struct gdsc { unsigned int *cxcs; unsigned int cxc_count; const u8 pwrsts; + struct reset_controller_dev *rcdev; + unsigned int *resets; + unsigned int reset_count; }; #ifdef CONFIG_QCOM_GDSC -int gdsc_register(struct device *, struct gdsc **, size_t n, struct regmap *); +int gdsc_register(struct device *, struct gdsc **, size_t n, + struct reset_controller_dev *, struct regmap *); void gdsc_unregister(struct device *); #else static inline int gdsc_register(struct device *d, struct gdsc **g, size_t n, + struct reset_controller_dev *rcdev, struct regmap *r) { return -ENOSYS; |