From: JerryVanBaren <gerald.vanbaren@ge.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 2/3] fix checkpatch errors
Date: Mon, 08 Sep 2008 08:15:47 -0400 [thread overview]
Message-ID: <48C51773.5020803@ge.com> (raw)
In-Reply-To: <12206967521471-git-send-email-schardt@team-ctech.de>
Georg Schardt wrote:
> ---
> include/configs/FX12MM.h | 12 ++++++------
> 1 files changed, 6 insertions(+), 6 deletions(-)
>
> diff --git a/include/configs/FX12MM.h b/include/configs/FX12MM.h
> index b47e403..8b8d41c 100644
> --- a/include/configs/FX12MM.h
> +++ b/include/configs/FX12MM.h
> @@ -15,28 +15,28 @@
> #define CONFIG_DOS_PARTITION 1
> #define CFG_SYSTEMACE_BASE XPAR_SYSACE_0_BASEADDR
> #define CFG_SYSTEMACE_WIDTH XPAR_SYSACE_0_MEM_WIDTH
> -#define ADD_SYSTEMACE_CMDS (| CFG_CMD_FAT)
> +#define ADD_SYSTEMACE_CMDS ( | CFG_CMD_FAT )
> #define RM_SYSTEMACE_CMDS
> #else
> #define ADD_SYSTEMACE_CMDS
> -#define RM_SYSTEMACE_CMDS | CFG_CMD_FAT
> +#define RM_SYSTEMACE_CMDS ( | CFG_CMD_FAT )
Dear List,
Philosophical question: is it better to put silly parenthesis around
#defines to make checkpatch shut up or to accept that checkpatch isn't
perfect and let it bitch about things that were done intentionally and
make sense per their usage?
(Yes, I see the first one already had () and the change is just fixing
the spacing.)
I'm serious about this question: in my day job I see a lot of mechanical
praying to the god of miserableC (MISRA-C) adding a HUGE amount of
unnecessary syntax noise such that it becomes hard to read the code
because of all the noise. I've had people at work ask me why "we"
cannot write code that is as easy to understand as the linux kernel.
The answer is simple: "we" are slavishly and mechanically following the
god of "if it was good practice somewhere, sometime, it must always be a
good practice" and not applying good engineering judgment and experience.
It is WRONG to let our tools rule us.[1]
Thanks for letting me unload,
gvb
[1] It took four movies to kill the Terminators, and now I see we still
haven't succeeded.
<http://en.wikipedia.org/wiki/Terminator_Salvation>
P.S. In my day job I've seen way too much lot of...
#define FOOBAR_THREE (3)
next prev parent reply other threads:[~2008-09-08 12:15 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-09-06 10:25 [U-Boot] First Patch Georg Schardt
2008-09-06 10:25 ` [U-Boot] [PATCH 1/3] Add support for the virtex4fx12 minimodul Georg Schardt
2008-09-06 10:25 ` [U-Boot] [PATCH 2/3] fix checkpatch errors Georg Schardt
2008-09-06 10:25 ` [U-Boot] [PATCH 3/3] fix some other patch errors Georg Schardt
2008-09-06 13:22 ` [U-Boot] [PATCH 2/3] fix checkpatch errors Wolfgang Denk
2008-09-06 14:02 ` Georg Schardt
2008-09-06 15:45 ` Wolfgang Denk
2008-09-07 10:56 ` Georg Schardt
2008-09-07 11:15 ` Wolfgang Denk
2008-09-07 11:48 ` Georg Schardt
2008-09-08 12:15 ` JerryVanBaren [this message]
2008-09-08 12:38 ` Wolfgang Denk
2008-09-08 13:01 ` Haavard Skinnemoen
2008-09-06 13:34 ` [U-Boot] [PATCH 1/3] Add support for the virtex4fx12 minimodul Wolfgang Denk
2008-09-07 21:50 ` Ricardo
-- strict thread matches above, loose matches on Subject: below --
2008-09-09 15:02 [U-Boot] [PATCH 2/3] fix checkpatch errors Hugo Villeneuve
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=48C51773.5020803@ge.com \
--to=gerald.vanbaren@ge.com \
--cc=u-boot@lists.denx.de \
/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