16 #include <linux/errno.h>
29 static int omap2_pwrdm_set_next_pwrst(
struct powerdomain *pwrdm,
u8 pwrst)
37 static int omap2_pwrdm_read_next_pwrst(
struct powerdomain *pwrdm)
44 static int omap2_pwrdm_read_pwrst(
struct powerdomain *pwrdm)
51 static int omap2_pwrdm_set_mem_onst(
struct powerdomain *pwrdm,
u8 bank,
64 static int omap2_pwrdm_set_mem_retst(
struct powerdomain *pwrdm,
u8 bank,
77 static int omap2_pwrdm_read_mem_pwrst(
struct powerdomain *pwrdm,
u8 bank)
87 static int omap2_pwrdm_read_mem_retst(
struct powerdomain *pwrdm,
u8 bank)
97 static int omap2_pwrdm_set_logic_retst(
struct powerdomain *pwrdm,
u8 pwrst)
108 static int omap2_pwrdm_wait_transition(
struct powerdomain *pwrdm)
125 pr_err(
"powerdomain: %s: waited too long to complete transition\n",
130 pr_debug(
"powerdomain: completed transition in %d loops\n", c);
136 static int omap3_pwrdm_read_prev_pwrst(
struct powerdomain *pwrdm)
143 static int omap3_pwrdm_read_logic_pwrst(
struct powerdomain *pwrdm)
150 static int omap3_pwrdm_read_logic_retst(
struct powerdomain *pwrdm)
157 static int omap3_pwrdm_read_prev_logic_pwrst(
struct powerdomain *pwrdm)
164 static int omap3_get_mem_bank_lastmemst_mask(
u8 bank)
182 static int omap3_pwrdm_read_prev_mem_pwrst(
struct powerdomain *pwrdm,
u8 bank)
186 m = omap3_get_mem_bank_lastmemst_mask(bank);
192 static int omap3_pwrdm_clear_all_prev_pwrst(
struct powerdomain *pwrdm)
198 static int omap3_pwrdm_enable_hdwr_sar(
struct powerdomain *pwrdm)
205 static int omap3_pwrdm_disable_hdwr_sar(
struct powerdomain *pwrdm)
213 .pwrdm_set_next_pwrst = omap2_pwrdm_set_next_pwrst,
214 .pwrdm_read_next_pwrst = omap2_pwrdm_read_next_pwrst,
215 .pwrdm_read_pwrst = omap2_pwrdm_read_pwrst,
216 .pwrdm_set_logic_retst = omap2_pwrdm_set_logic_retst,
217 .pwrdm_set_mem_onst = omap2_pwrdm_set_mem_onst,
218 .pwrdm_set_mem_retst = omap2_pwrdm_set_mem_retst,
219 .pwrdm_read_mem_pwrst = omap2_pwrdm_read_mem_pwrst,
220 .pwrdm_read_mem_retst = omap2_pwrdm_read_mem_retst,
221 .pwrdm_wait_transition = omap2_pwrdm_wait_transition,
225 .pwrdm_set_next_pwrst = omap2_pwrdm_set_next_pwrst,
226 .pwrdm_read_next_pwrst = omap2_pwrdm_read_next_pwrst,
227 .pwrdm_read_pwrst = omap2_pwrdm_read_pwrst,
228 .pwrdm_read_prev_pwrst = omap3_pwrdm_read_prev_pwrst,
229 .pwrdm_set_logic_retst = omap2_pwrdm_set_logic_retst,
230 .pwrdm_read_logic_pwrst = omap3_pwrdm_read_logic_pwrst,
231 .pwrdm_read_logic_retst = omap3_pwrdm_read_logic_retst,
232 .pwrdm_read_prev_logic_pwrst = omap3_pwrdm_read_prev_logic_pwrst,
233 .pwrdm_set_mem_onst = omap2_pwrdm_set_mem_onst,
234 .pwrdm_set_mem_retst = omap2_pwrdm_set_mem_retst,
235 .pwrdm_read_mem_pwrst = omap2_pwrdm_read_mem_pwrst,
236 .pwrdm_read_mem_retst = omap2_pwrdm_read_mem_retst,
237 .pwrdm_read_prev_mem_pwrst = omap3_pwrdm_read_prev_mem_pwrst,
238 .pwrdm_clear_all_prev_pwrst = omap3_pwrdm_clear_all_prev_pwrst,
239 .pwrdm_enable_hdwr_sar = omap3_pwrdm_enable_hdwr_sar,
240 .pwrdm_disable_hdwr_sar = omap3_pwrdm_disable_hdwr_sar,
241 .pwrdm_wait_transition = omap2_pwrdm_wait_transition,