From: "Maciej W. Rozycki" <macro@linux-mips.org>
To: Grant Likely <grant.likely@secretlab.ca>
Cc: Joe Perches <joe@perches.com>, David Miller <davem@davemloft.net>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] declance: Fix 64-bit compilation warnings
Date: Mon, 7 Jul 2014 13:18:43 +0100 (BST) [thread overview]
Message-ID: <alpine.LFD.2.11.1407071306080.5433@eddie.linux-mips.org> (raw)
In-Reply-To: <20140707120152.CF82BC40921@trevor.secretlab.ca>
On Mon, 7 Jul 2014, Grant Likely wrote:
> > > > I don't think %#p is valid so it
> > > > shouldn't have been set by #.
> > >
> > > Huh? As recently as last Wednesday you pointed me at the specific commit
> > > from Grant that made it valid (GCC format complaints aside).
> >
> > Those gcc complaints are precisely the thing
> > that makes it invalid.
>
> That's the most inane reason ever for saying something is invalid. "The
> tool doesn't recognise it, there for it is invalid?" Seriously?
>
> Tools are just tools. They aren't the source of what is valid/invalid,
> they only report on what we as engineers have told them to do, because
> *we* define what should be valid/invalid.
>
> If you've got a real reason that explains *why* the tool rejects that
> construct, then I'd be happy to hear it, but otherwise that argument
> makes no sense.
GCC rejects it, because its `printf' format attribute expects format
specifiers according to ISO C and its formatted input/output functions.
The syntax of our `printk' is however different, not only for %#p, so I
agree it's GCC that acts incompatibly and not our design being wrong. I
have therefore offered a solution (though not an implementation right now,
sorry; I'm not even set up to start such development right away) to
introduce a `linux_printk' format attribute to GCC that would match our
requirements.
FAOD I'm in favour to retaining `#' with %p, but then making it
consistent across variants such as %pad vs %#pad. This does not preclude
or require adding `linux_printk' to GCC in the future.
Maciej
next prev parent reply other threads:[~2014-07-07 12:18 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-29 2:10 [PATCH v2] declance: Fix 64-bit compilation warnings Maciej W. Rozycki
2014-07-03 1:28 ` David Miller
2014-07-03 2:29 ` Maciej W. Rozycki
2014-07-03 2:34 ` Maciej W. Rozycki
2014-07-03 3:05 ` Joe Perches
2014-07-03 4:51 ` Maciej W. Rozycki
2014-07-03 5:16 ` Joe Perches
2014-07-03 6:01 ` Maciej W. Rozycki
2014-07-03 6:25 ` Joe Perches
2014-07-03 16:57 ` Grant Likely
2014-07-05 14:56 ` Maciej W. Rozycki
2014-07-05 16:07 ` Joe Perches
2014-07-05 17:39 ` Maciej W. Rozycki
2014-07-05 18:08 ` Joe Perches
2014-07-05 18:20 ` Maciej W. Rozycki
2014-07-05 18:31 ` Joe Perches
2014-07-05 20:25 ` Maciej W. Rozycki
2014-07-05 20:45 ` [PATCH] vsprintf: Remove SPECIAL from pointer types Joe Perches
2014-07-06 11:44 ` Maciej W. Rozycki
2014-07-06 14:32 ` Joe Perches
2014-07-07 8:26 ` David Laight
2014-07-07 13:26 ` Joe Perches
2014-07-07 12:01 ` [PATCH v2] declance: Fix 64-bit compilation warnings Grant Likely
2014-07-07 12:18 ` Maciej W. Rozycki [this message]
2014-07-07 13:40 ` Joe Perches
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=alpine.LFD.2.11.1407071306080.5433@eddie.linux-mips.org \
--to=macro@linux-mips.org \
--cc=davem@davemloft.net \
--cc=grant.likely@secretlab.ca \
--cc=joe@perches.com \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.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).