On 8/6/23 16:46, Peter Maydell wrote:
On Wed, 31 May 2023 at 21:36, Philippe Mathieu-Daudé <phi...@linaro.org> wrote:

Extract arm_timer_reset() before converting this model to QOM/QDev
in few commits. This will become our DeviceReset handler.

Signed-off-by: Philippe Mathieu-Daudé <phi...@linaro.org>
---
  hw/timer/arm_timer.c | 7 ++++++-
  1 file changed, 6 insertions(+), 1 deletion(-)


+static void arm_timer_reset(ArmTimerState *s)
+{
+    s->control = TIMER_CTRL_IE;
+}

Reset also should zero s->limit and s->int_level.
(in arm_timer_init() this was implicit in the g_new0()).)

Oops I missed that, thanks!


Reply via email to