From: "Cédric Le Goater" <clg@kaod.org>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: qemu-devel@nongnu.org,
"Richard Henderson" <richard.henderson@linaro.org>,
"Andrew Jeffery" <andrew@aj.id.au>,
"Anton D . Kachalov" <mouse@yandex-team.ru>,
"Cédric Le Goater" <clg@kaod.org>
Subject: [Qemu-devel] [PATCH v2] watchdog/aspeed: fix variable type to store reload value
Date: Wed, 20 Sep 2017 08:49:15 +0200 [thread overview]
Message-ID: <20170920064915.30027-1-clg@kaod.org> (raw)
Initially from Anton D. Kachalov" <mouse@yandex-team.ru> but the SoB was
missing.
Signed-off-by: Cédric Le Goater <clg@kaod.org>
[clg: change commit log and subject
replace UL suffix by ULL ]
Signed-off-by: Cédric Le Goater <clg@kaod.org>
---
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..95f6ad186d72 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] * 1000ULL;
}
if (aspeed_wdt_is_enabled(s)) {
--
2.13.5
next reply other threads:[~2017-09-20 6:49 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-20 6:49 Cédric Le Goater [this message]
2017-10-08 23:45 ` [Qemu-devel] [PATCH v2] watchdog/aspeed: fix variable type to store reload value Andrew Jeffery
2017-10-09 18:34 ` Peter Maydell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170920064915.30027-1-clg@kaod.org \
--to=clg@kaod.org \
--cc=andrew@aj.id.au \
--cc=mouse@yandex-team.ru \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=richard.henderson@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).