Re: [PATCH] hw/core/ptimer: fix timer zero period condition

2024-08-08 Thread Peter Maydell
On Wed, 7 Aug 2024 at 10:13, Jianzhou Yue wrote: > > The real period is zero when both period and period_frac are zero. > Check the method ptimer_set_freq, if freq is larger than 1000 MHz, > the period is zero, but the period_frac is not, in this case, the > ptimer will work but the current code i

[PATCH] hw/core/ptimer: fix timer zero period condition

2024-08-07 Thread Jianzhou Yue via
The real period is zero when both period and period_frac are zero. Check the method ptimer_set_freq, if freq is larger than 1000 MHz, the period is zero, but the period_frac is not, in this case, the ptimer will work but the current code incorrectly recognizes that the ptimer is disabled. Resolves