backlight: pwm_bl: wait 100us after setting duty cycle

MXS PWM peripheral needs a little time to apply the latest config before being disabled
This commit is contained in:
Takumi Sueda 2023-03-28 17:36:53 +09:00
parent bf2d035feb
commit fd4ac69b10
1 changed files with 5 additions and 1 deletions

View File

@ -80,10 +80,14 @@ static void pwm_backlight_power_off(struct pwm_bl_data *pb)
if (pb->pwm_off_delay)
msleep(pb->pwm_off_delay);
state.enabled = false;
state.duty_cycle = 0;
pwm_apply_state(pb->pwm, &state);
udelay(100);
state.enabled = false;
pwm_apply_state(pb->pwm, &state);
regulator_disable(pb->power_supply);
pb->enabled = false;
}