From: Tom Rix <trix@redhat.com>
To: Joe Perches <joe@perches.com>, Simon Horman <simon.horman@netronome.com>
Cc: kuba@kernel.org, davem@davemloft.net, ast@kernel.org,
daniel@iogearbox.net, andrii@kernel.org, kafai@fb.com,
songliubraving@fb.com, yhs@fb.com, john.fastabend@gmail.com,
kpsingh@kernel.org, gustavoars@kernel.org,
louis.peens@netronome.com, netdev@vger.kernel.org,
bpf@vger.kernel.org, oss-drivers@netronome.com,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] nfp: remove h from printk format specifier
Date: Fri, 25 Dec 2020 14:13:06 -0800 [thread overview]
Message-ID: <65755252-96c3-a808-3e01-e377dd395ee7@redhat.com> (raw)
In-Reply-To: <327d6cad23720c8fe984aa75a046ff69499568c8.camel@perches.com>
On 12/25/20 9:06 AM, Joe Perches wrote:
> On Fri, 2020-12-25 at 06:56 -0800, Tom Rix wrote:
>> On 12/24/20 2:39 PM, Joe Perches wrote:
> []
>>> Kernel code doesn't use a signed char or short with %hx or %hu very often
>>> but in case you didn't already know, any signed char/short emitted with
>>> anything like %hx or %hu needs to be left alone as sign extension occurs so:
>> Yes, this would also effect checkpatch.
> Of course but checkpatch is stupid and doesn't know types
> so it just assumes that the type argument is not signed.
>
> In general, that's a reasonable but imperfect assumption.
>
> coccinelle could probably do this properly as it's a much
> better parser. clang-tidy should be able to as well.
>
Ok.
But types not matching the format string is a larger problem.
Has there been an effort to clean these up ?
Tom
next prev parent reply other threads:[~2020-12-25 22:14 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-23 20:20 [PATCH] nfp: remove h from printk format specifier trix
2020-12-24 20:21 ` Simon Horman
2020-12-24 22:14 ` Tom Rix
2020-12-24 22:39 ` Joe Perches
2020-12-25 14:56 ` Tom Rix
2020-12-25 17:06 ` Joe Perches
2020-12-25 22:13 ` Tom Rix [this message]
2020-12-25 23:00 ` Joe Perches
2020-12-26 20:40 ` David Laight
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=65755252-96c3-a808-3e01-e377dd395ee7@redhat.com \
--to=trix@redhat.com \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=daniel@iogearbox.net \
--cc=davem@davemloft.net \
--cc=gustavoars@kernel.org \
--cc=joe@perches.com \
--cc=john.fastabend@gmail.com \
--cc=kafai@fb.com \
--cc=kpsingh@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=louis.peens@netronome.com \
--cc=netdev@vger.kernel.org \
--cc=oss-drivers@netronome.com \
--cc=simon.horman@netronome.com \
--cc=songliubraving@fb.com \
--cc=yhs@fb.com \
/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