hc
2023-11-07 f45e756958099c35d6afb746df1d40a1c6302cfc
kernel/drivers/input/remotectl/rockchip_pwm_remotectl.c
....@@ -335,9 +335,12 @@
335335 return IRQ_NONE;
336336 if ((val & PWM_CH_POL(id)) == 0) {
337337 temp_hpr = readl_relaxed(ddata->base + PWM_REG_HPR);
338
- DBG("hpr=%d\n", temp_hpr);
338
+ writel_relaxed(0, ddata->base + PWM_REG_HPR);
339339 temp_lpr = readl_relaxed(ddata->base + PWM_REG_LPR);
340
+ writel_relaxed(0, ddata->base + PWM_REG_LPR);
341
+ DBG("hpr=%d\n", temp_hpr);
340342 DBG("lpr=%d\n", temp_lpr);
343
+
341344 temp_period = ddata->pwm_freq_nstime * temp_lpr / 1000;
342345 if (temp_period > RK_PWM_TIME_BIT0_MIN) {
343346 ddata->period = ddata->temp_period