From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Huth Subject: Re: [kvm-unit-tests PATCH 3/4] arm64: fix printf format warnings Date: Tue, 1 Mar 2016 06:01:33 +0100 Message-ID: <56D5222D.8010607@redhat.com> References: <1456777155-8599-1-git-send-email-drjones@redhat.com> <1456777155-8599-4-git-send-email-drjones@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Cc: pbonzini@redhat.com, rkrcmar@redhat.com To: Andrew Jones , kvm@vger.kernel.org Return-path: Received: from mx1.redhat.com ([209.132.183.28]:43543 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750863AbcCAFBh (ORCPT ); Tue, 1 Mar 2016 00:01:37 -0500 Received: from int-mx14.intmail.prod.int.phx2.redhat.com (int-mx14.intmail.prod.int.phx2.redhat.com [10.5.11.27]) by mx1.redhat.com (Postfix) with ESMTPS id 0BFFF8F4F0 for ; Tue, 1 Mar 2016 05:01:37 +0000 (UTC) In-Reply-To: <1456777155-8599-4-git-send-email-drjones@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On 29.02.2016 21:19, Andrew Jones wrote: > Signed-off-by: Andrew Jones > --- > lib/arm64/processor.c | 8 ++++---- > 1 file changed, 4 insertions(+), 4 deletions(-) > > diff --git a/lib/arm64/processor.c b/lib/arm64/processor.c > index c553390c969ea..deeab4ec9c8ac 100644 > --- a/lib/arm64/processor.c > +++ b/lib/arm64/processor.c > @@ -66,12 +66,12 @@ void show_regs(struct pt_regs *regs) > { > int i; > > - printf("pc : [<%016llx>] lr : [<%016llx>] pstate: %08llx\n", > + printf("pc : [<%016lx>] lr : [<%016lx>] pstate: %08lx\n", > regs->pc, regs->regs[30], regs->pstate); > - printf("sp : %016llx\n", regs->sp); > + printf("sp : %016lx\n", regs->sp); > > for (i = 29; i >= 0; --i) { > - printf("x%-2d: %016llx ", i, regs->regs[i]); > + printf("x%-2d: %016lx ", i, regs->regs[i]); > if (i % 2 == 0) > printf("\n"); > } Why don't you use PRIx64 here? The regs are defined as "u64", not as "long", so PRIx64 should fit better, shouldn't it? Thomas