From: Timur Tabi <timur@freescale.com>
To: Zach Brown <zach.brown@oracle.com>
Cc: apw@shadowen.org, linux-kernel@vger.kernel.org
Subject: Re: checkpatch bug: space between left parenthesis and asterisk
Date: Tue, 30 Oct 2007 15:02:00 -0500 [thread overview]
Message-ID: <47278DB8.7000401@freescale.com> (raw)
In-Reply-To: <47278BE8.6010901@oracle.com>
Zach Brown wrote:
> Timur Tabi wrote:
>> I'm running checkpatch.pl (dated 10/17), and it complains about this line:
>>
>> crc = __be32_to_cpu(* ((__be32 *) ((void *) firmware + calc_size)));
>
> Well, that is a bit of a stinker. Maybe it could be reworked a little
> to make it easier for humans and checkpatch to understand?
>
> __be32 *crazy_pointer = (void *)firmware + calc_size;
> crc = be32_to_cpu(*crazy_pointer);
I admit the code might be convoluted, but it's perfectly valid, and it
eliminates the need for "crazy_pointer". I'm much more inclined to ignore
the checkpatch error than to redesign my code.
Besides, your argument is a bit of a strawman. The real problem is with checkpatch.
> (Does this need to worry about get_unaligned() at all?)
Well, I suppose it's technically possible, but only if my data has been corrupted.
--
Timur Tabi
Linux kernel developer at Freescale
next prev parent reply other threads:[~2007-10-30 20:03 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-30 19:27 checkpatch bug: space between left parenthesis and asterisk Timur Tabi
2007-10-30 19:54 ` Zach Brown
2007-10-30 20:02 ` Timur Tabi [this message]
2007-10-30 21:46 ` Andy Whitcroft
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=47278DB8.7000401@freescale.com \
--to=timur@freescale.com \
--cc=apw@shadowen.org \
--cc=linux-kernel@vger.kernel.org \
--cc=zach.brown@oracle.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