Lines Matching defs:state
46 const struct pwm_state *state)
50 if (state->polarity == PWM_POLARITY_INVERSED)
54 if (state->enabled) {
58 state->duty_cycle, NSEC_PER_SEC);
63 state->period, NSEC_PER_SEC) - on_cycles;
78 struct pwm_state *state)
89 state->enabled = (ctrl & APPLE_PWM_CTRL_ENABLE) && (ctrl & APPLE_PWM_CTRL_OUTPUT_ENABLE);
90 state->polarity = PWM_POLARITY_NORMAL;
92 state->duty_cycle = DIV64_U64_ROUND_UP((u64)on_cycles * NSEC_PER_SEC, fpwm->clkrate);
93 state->period = DIV64_U64_ROUND_UP(((u64)off_cycles + (u64)on_cycles) *