Received: from eggs.gnu.org ([2001:4830:134:3::10]:50896) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1afUsa-0007j7-K7 for qemu-devel@nongnu.org; Mon, 14 Mar 2016 11:58:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1afUsW-0005oL-Aa for qemu-devel@nongnu.org; Mon, 14 Mar 2016 11:58:00 -0400 Received: from mail-wm0-x242.google.com ([2a00:1450:400c:c09::242]:34205) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1afUsW-0005oH-3G for qemu-devel@nongnu.org; Mon, 14 Mar 2016 11:57:56 -0400 Received: by mail-wm0-x242.google.com with SMTP id p65so16090960wmp.1 for ; Mon, 14 Mar 2016 08:57:55 -0700 (PDT) From: Nikos Filippakis Date: Mon, 14 Mar 2016 17:57:52 +0200 Message-Id: <1457971072-26243-1-git-send-email-aesmade@gmail.com> Subject: [Qemu-devel] [PATCH 4/4] timer/m48t59.c: Change qemu_system_reset_request to watchdog_perform_action where appropriate List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Nikos Filippakis , peter.maydell@linaro.org Instead of using qemu_system_reset_request() to reset when a watchdog triggers, let watchdog_perform_action() decide what to do, as stated in the BiteSizedTasks wiki page. Signed-off-by: Nikos Filippakis --- hw/timer/m48t59.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/timer/m48t59.c b/hw/timer/m48t59.c index bbcfeb2..57811e7 100644 --- a/hw/timer/m48t59.c +++ b/hw/timer/m48t59.c @@ -30,6 +30,7 @@ #include "hw/sysbus.h" #include "hw/isa/isa.h" #include "exec/address-spaces.h" +#include "sysemu/watchdog.h" //#define DEBUG_NVRAM @@ -223,7 +224,7 @@ static void watchdog_cb (void *opaque) NVRAM->buffer[0x1FF7] = 0x00; NVRAM->buffer[0x1FFC] &= ~0x40; /* May it be a hw CPU Reset instead ? */ - qemu_system_reset_request(); + watchdog_perform_action(); } else { qemu_set_irq(NVRAM->IRQ, 1); qemu_set_irq(NVRAM->IRQ, 0); -- 1.9.1