Re: [PATCH v1 2/2] iio: adc: Add StarFive SAR-ADC driver
From: Jonathan Cameron
Date: Thu May 21 2026 - 07:37:47 EST
>
> >
> > > +
> > > + starfive_saradc_ch_monitor_stop(priv, ch);
> >
> > Why stop it? Add a comment. We aren't interested in future events?
>
> If we do not stop it and the input voltage remains constant, the ADC could continuously monitor the voltage and continuously trigger interrupts for the bound.
> As a result, the CPU utilization rate will be high.
Can you use an edge interrupt instead of a level one?
If not, then a common solution is to disable for a period (maybe a second
or so) then reenable. There are various more refined ways of doing this.
Basically we don't want to be in a situation where a momentary blip
disables the event and we miss a later condition that must be handled.
Thanks,
Jonathan