diff options
Diffstat (limited to 'arch/arm/plat-omap')
-rw-r--r-- | arch/arm/plat-omap/include/mach/powerdomain.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/arch/arm/plat-omap/include/mach/powerdomain.h b/arch/arm/plat-omap/include/mach/powerdomain.h index c8f52c6f8b7e..5fa666fa9be8 100644 --- a/arch/arm/plat-omap/include/mach/powerdomain.h +++ b/arch/arm/plat-omap/include/mach/powerdomain.h | |||
@@ -44,9 +44,16 @@ | |||
44 | */ | 44 | */ |
45 | #define PWRDM_MAX_MEM_BANKS 4 | 45 | #define PWRDM_MAX_MEM_BANKS 4 |
46 | 46 | ||
47 | /* | ||
48 | * Maximum number of clockdomains that can be associated with a powerdomain. | ||
49 | * CORE powerdomain is probably the worst case. | ||
50 | */ | ||
51 | #define PWRDM_MAX_CLKDMS 3 | ||
52 | |||
47 | /* XXX A completely arbitrary number. What is reasonable here? */ | 53 | /* XXX A completely arbitrary number. What is reasonable here? */ |
48 | #define PWRDM_TRANSITION_BAILOUT 100000 | 54 | #define PWRDM_TRANSITION_BAILOUT 100000 |
49 | 55 | ||
56 | struct clockdomain; | ||
50 | struct powerdomain; | 57 | struct powerdomain; |
51 | 58 | ||
52 | /* Encodes dependencies between powerdomains - statically defined */ | 59 | /* Encodes dependencies between powerdomains - statically defined */ |
@@ -98,6 +105,9 @@ struct powerdomain { | |||
98 | /* Possible memory bank pwrstates when pwrdm is ON */ | 105 | /* Possible memory bank pwrstates when pwrdm is ON */ |
99 | const u8 pwrsts_mem_on[PWRDM_MAX_MEM_BANKS]; | 106 | const u8 pwrsts_mem_on[PWRDM_MAX_MEM_BANKS]; |
100 | 107 | ||
108 | /* Clockdomains in this powerdomain */ | ||
109 | struct clockdomain *pwrdm_clkdms[PWRDM_MAX_CLKDMS]; | ||
110 | |||
101 | struct list_head node; | 111 | struct list_head node; |
102 | 112 | ||
103 | }; | 113 | }; |
@@ -111,6 +121,12 @@ struct powerdomain *pwrdm_lookup(const char *name); | |||
111 | 121 | ||
112 | int pwrdm_for_each(int (*fn)(struct powerdomain *pwrdm)); | 122 | int pwrdm_for_each(int (*fn)(struct powerdomain *pwrdm)); |
113 | 123 | ||
124 | int pwrdm_add_clkdm(struct powerdomain *pwrdm, struct clockdomain *clkdm); | ||
125 | int pwrdm_del_clkdm(struct powerdomain *pwrdm, struct clockdomain *clkdm); | ||
126 | int pwrdm_for_each_clkdm(struct powerdomain *pwrdm, | ||
127 | int (*fn)(struct powerdomain *pwrdm, | ||
128 | struct clockdomain *clkdm)); | ||
129 | |||
114 | int pwrdm_add_wkdep(struct powerdomain *pwrdm1, struct powerdomain *pwrdm2); | 130 | int pwrdm_add_wkdep(struct powerdomain *pwrdm1, struct powerdomain *pwrdm2); |
115 | int pwrdm_del_wkdep(struct powerdomain *pwrdm1, struct powerdomain *pwrdm2); | 131 | int pwrdm_del_wkdep(struct powerdomain *pwrdm1, struct powerdomain *pwrdm2); |
116 | int pwrdm_read_wkdep(struct powerdomain *pwrdm1, struct powerdomain *pwrdm2); | 132 | int pwrdm_read_wkdep(struct powerdomain *pwrdm1, struct powerdomain *pwrdm2); |