linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ingo Molnar <mingo@kernel.org>
To: hpa@zytor.com
Cc: Nicolas Iooss <nicolas.iooss_linux@m4x.org>,
	Thomas Gleixner <tglx@linutronix.de>,
	Ingo Molnar <mingo@redhat.com>,
	x86@kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 1/1] x86, relocs: add printf attribute to die()
Date: Thu, 2 Feb 2017 20:30:17 +0100	[thread overview]
Message-ID: <20170202193017.GA31326@gmail.com> (raw)
In-Reply-To: <59A0972A-86C0-42E6-9303-0328F0027674@zytor.com>


* hpa@zytor.com <hpa@zytor.com> wrote:

> On February 1, 2017 11:16:00 PM PST, Ingo Molnar <mingo@kernel.org> wrote:
> >
> >* Nicolas Iooss <nicolas.iooss_linux@m4x.org> wrote:
> >
> >> With %Ld, my compiler (gcc 6.3.1 on x86_64) complains:
> >> 
> >> arch/x86/tools/relocs.c:400:7: error: format ‘%Ld’ expects argument
> >of
> >> type ‘long long int’, but argument 2 has type ‘Elf64_Off {aka long
> >> unsigned int}’ [-Werror=format=]
> >
> >How did it pick up that type as an 'unsigned long'? We have:
> >
> >  include/uapi/linux/elf.h:typedef __u64  Elf64_Off;
> >
> >Even user-space has it as a pure 64-bit type:
> >
> >  /usr/include/elf.h:typedef uint64_t Elf64_Off;
> >
> >Thanks,
> >
> >	Ingo
> 
> uint64_t is unsigned long on x86-64.

Sight, which is a big, lame mistake, because it forces such crap like "PRIu64" 
uglies...

Thanks,

	Ingo

      reply	other threads:[~2017-02-02 19:30 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-18 19:47 [PATCH v3 1/1] x86, relocs: add printf attribute to die() Nicolas Iooss
2017-01-31 18:52 ` Nicolas Iooss
2017-02-02  1:39   ` hpa
2017-02-02  8:15     ` Nicolas Iooss
2017-02-01  9:04 ` Ingo Molnar
2017-02-01 22:42   ` Nicolas Iooss
2017-02-02  7:16     ` Ingo Molnar
2017-02-02  7:43       ` hpa
2017-02-02 19:30         ` Ingo Molnar [this message]

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=20170202193017.GA31326@gmail.com \
    --to=mingo@kernel.org \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=nicolas.iooss_linux@m4x.org \
    --cc=tglx@linutronix.de \
    --cc=x86@kernel.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).