From patchwork Tue Sep 19 11:17:21 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?C=C3=A9dric_Le_Goater?= X-Patchwork-Id: 815462 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=nongnu.org (client-ip=2001:4830:134:3::11; helo=lists.gnu.org; envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org; receiver=) Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3xxL2t0Q1Yz9s7B for ; Tue, 19 Sep 2017 21:18:14 +1000 (AEST) Received: from localhost ([::1]:41639 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1duGXc-0006xq-5V for incoming@patchwork.ozlabs.org; Tue, 19 Sep 2017 07:18:12 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:44375) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1duGXH-0006xh-Sc for qemu-devel@nongnu.org; Tue, 19 Sep 2017 07:17:52 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1duGXD-0007mE-TP for qemu-devel@nongnu.org; Tue, 19 Sep 2017 07:17:51 -0400 Received: from 6.mo179.mail-out.ovh.net ([46.105.56.76]:52705) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1duGXD-0007lh-N8 for qemu-devel@nongnu.org; Tue, 19 Sep 2017 07:17:47 -0400 Received: from player716.ha.ovh.net (b6.ovh.net [213.186.33.56]) by mo179.mail-out.ovh.net (Postfix) with ESMTP id 8A44263A60 for ; Tue, 19 Sep 2017 13:17:45 +0200 (CEST) Received: from zorba.kaod.org.com (deibp9eh1--blueice1n2.emea.ibm.com [195.212.29.164]) (Authenticated sender: clg@kaod.org) by player716.ha.ovh.net (Postfix) with ESMTPSA id F2CCF56008D; Tue, 19 Sep 2017 13:17:39 +0200 (CEST) From: =?utf-8?q?C=C3=A9dric_Le_Goater?= To: Peter Maydell Date: Tue, 19 Sep 2017 13:17:21 +0200 Message-Id: <20170919111721.7931-1-clg@kaod.org> X-Mailer: git-send-email 2.13.5 MIME-Version: 1.0 X-Ovh-Tracer-Id: 18219593767748471569 X-VR-SPAMSTATE: OK X-VR-SPAMSCORE: -100 X-VR-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrfeelledrheejgdeflecutefuodetggdotefrodftvfcurfhrohhfihhlvgemucfqggfjpdevjffgvefmvefgnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 46.105.56.76 Subject: [Qemu-devel] [PATCH] watchdog/aspeed: fix variable type to store reload value X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Andrew Jeffery , "Anton D . Kachalov" , qemu-devel@nongnu.org, =?utf-8?b?Q8OpZHJpYyBM?= =?utf-8?q?e_Goater?= Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" Initially from Anton D. Kachalov" but the SoB was missing. Signed-off-by: Cédric Le Goater [clg: change commit log and subject] --- hw/watchdog/wdt_aspeed.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/watchdog/wdt_aspeed.c b/hw/watchdog/wdt_aspeed.c index 22bce364d7b5..b8e0e9a75999 100644 --- a/hw/watchdog/wdt_aspeed.c +++ b/hw/watchdog/wdt_aspeed.c @@ -100,13 +100,13 @@ static uint64_t aspeed_wdt_read(void *opaque, hwaddr offset, unsigned size) static void aspeed_wdt_reload(AspeedWDTState *s, bool pclk) { - uint32_t reload; + uint64_t reload; if (pclk) { reload = muldiv64(s->regs[WDT_RELOAD_VALUE], NANOSECONDS_PER_SECOND, s->pclk_freq); } else { - reload = s->regs[WDT_RELOAD_VALUE] * 1000; + reload = s->regs[WDT_RELOAD_VALUE] * 1000UL; } if (aspeed_wdt_is_enabled(s)) {