• Home
  • Raw
  • Download

Lines Matching refs:cmr

42 	u32 cmr;  member
81 unsigned cmr; in atmel_tcb_pwm_request() local
101 cmr = __raw_readl(regs + ATMEL_TC_REG(group, CMR)); in atmel_tcb_pwm_request()
106 if (cmr & ATMEL_TC_WAVE) { in atmel_tcb_pwm_request()
114 tcbpwm->div = cmr & ATMEL_TC_TCCLKS; in atmel_tcb_pwm_request()
116 cmr &= (ATMEL_TC_TCCLKS | ATMEL_TC_ACMR_MASK | in atmel_tcb_pwm_request()
119 cmr = 0; in atmel_tcb_pwm_request()
121 cmr |= ATMEL_TC_WAVE | ATMEL_TC_WAVESEL_UP_AUTO | ATMEL_TC_EEVT_XC0; in atmel_tcb_pwm_request()
122 __raw_writel(cmr, regs + ATMEL_TC_REG(group, CMR)); in atmel_tcb_pwm_request()
149 unsigned cmr; in atmel_tcb_pwm_disable() local
164 cmr = __raw_readl(regs + ATMEL_TC_REG(group, CMR)); in atmel_tcb_pwm_disable()
168 cmr &= ~ATMEL_TC_ACMR_MASK; in atmel_tcb_pwm_disable()
170 cmr |= ATMEL_TC_ASWTRG_CLEAR; in atmel_tcb_pwm_disable()
172 cmr |= ATMEL_TC_ASWTRG_SET; in atmel_tcb_pwm_disable()
174 cmr &= ~ATMEL_TC_BCMR_MASK; in atmel_tcb_pwm_disable()
176 cmr |= ATMEL_TC_BSWTRG_CLEAR; in atmel_tcb_pwm_disable()
178 cmr |= ATMEL_TC_BSWTRG_SET; in atmel_tcb_pwm_disable()
181 __raw_writel(cmr, regs + ATMEL_TC_REG(group, CMR)); in atmel_tcb_pwm_disable()
187 if (!(cmr & (ATMEL_TC_ACPC | ATMEL_TC_BCPC))) { in atmel_tcb_pwm_disable()
208 u32 cmr; in atmel_tcb_pwm_enable() local
223 cmr = __raw_readl(regs + ATMEL_TC_REG(group, CMR)); in atmel_tcb_pwm_enable()
226 cmr &= ~ATMEL_TC_TCCLKS; in atmel_tcb_pwm_enable()
229 cmr &= ~ATMEL_TC_ACMR_MASK; in atmel_tcb_pwm_enable()
233 cmr |= ATMEL_TC_ASWTRG_CLEAR; in atmel_tcb_pwm_enable()
235 cmr |= ATMEL_TC_ASWTRG_SET; in atmel_tcb_pwm_enable()
237 cmr &= ~ATMEL_TC_BCMR_MASK; in atmel_tcb_pwm_enable()
239 cmr |= ATMEL_TC_BSWTRG_CLEAR; in atmel_tcb_pwm_enable()
241 cmr |= ATMEL_TC_BSWTRG_SET; in atmel_tcb_pwm_enable()
253 cmr |= ATMEL_TC_ACPA_SET | ATMEL_TC_ACPC_CLEAR; in atmel_tcb_pwm_enable()
255 cmr |= ATMEL_TC_ACPA_CLEAR | ATMEL_TC_ACPC_SET; in atmel_tcb_pwm_enable()
258 cmr |= ATMEL_TC_BCPB_SET | ATMEL_TC_BCPC_CLEAR; in atmel_tcb_pwm_enable()
260 cmr |= ATMEL_TC_BCPB_CLEAR | ATMEL_TC_BCPC_SET; in atmel_tcb_pwm_enable()
264 cmr |= (tcbpwm->div & ATMEL_TC_TCCLKS); in atmel_tcb_pwm_enable()
266 __raw_writel(cmr, regs + ATMEL_TC_REG(group, CMR)); in atmel_tcb_pwm_enable()
470 chan->cmr = readl(base + ATMEL_TC_REG(i, CMR)); in atmel_tcb_pwm_suspend()
487 writel(chan->cmr, base + ATMEL_TC_REG(i, CMR)); in atmel_tcb_pwm_resume()