public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Mark Lord <lkml@rtr.ca>
To: Erez Zadok <ezk@cs.sunysb.edu>
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
	akpm@linux-foundation.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] 0/3 coding standards documentation/code updates
Date: Sun, 30 Sep 2007 13:40:13 -0400	[thread overview]
Message-ID: <46FFDF7D.7080605@rtr.ca> (raw)
In-Reply-To: <200709300401.l8U41AhY024890@agora.fsl.cs.sunysb.edu>

Erez Zadok wrote:
> In message <alpine.LFD.0.999.0709291748160.3579@woody.linux-foundation.org>, Linus Torvalds writes:
>>
>> On Sat, 29 Sep 2007, Erez Zadok wrote:
>>> Would you prefer if CodingStyle was reorganized or even split into (1)
>>> general principles and (2) details?  Perhaps we need a CodingStylePrinciples
>>> and a CodingStyleDetails?
>> I'm certainly ok with the split into two files.
>>
>> What I'm not ok with is really important stuff (indentation), and then 
>> mixing in silly rules ("parenthesis are bad in printk's"?)
>>
>> 		Linus
> 
> OK, looking at CodingStyle, I see two kinds of chapters.  The first is stuff
> that's more generic to C, and the other is more specific to Linux and how
> one codes in the linux kernel.  So I propose the following:
> 
> 1. we create a new file called CodingSuggestions
> 
> 2. we keep in CodingStyle the following chapters
> 
>    Chapter 1: Indentation
>    Chapter 2: Breaking long lines and strings
>    Chapter 3: Placing Braces and Spaces
>    Chapter 4: Naming
>    Chapter 5: Typedefs
>    Chapter 6: Functions
>    Chapter 7: Centralized exiting of functions
>    Chapter 8: Commenting
>    Chapter 9: You've made a mess of it
> 
>    Note: I'd suggest we rename the title of ch9 to "Custom Editor
>    Programming/Indentation Modes" or something more descriptive.
> 
>    Chapter 10: Kconfig configuration files
>    Chapter 11: Data structures
>    Chapter 12: Macros, Enums and RTL
>    Chapter 15: The inline disease
>    Chapter 16: Function return values and names
>    Chapter 18: Editor modelines and other cruft
> 
> 3. move the following chapters to CodingSuggestions:
> 
>    Chapter 13: Printing kernel messages
>    Note: ch13 is the one which mentions the don't put parentheses around %d.
> 
>    Chapter 14: Allocating memory
>    Chapter 17: Don't re-invent the kernel macros
>    Chapter 19: branch prediction optimizations (the un/likely debacle)

Super.  And then, in the spirit of Linus's request,
we can submit another patch that simply removes that second file
completely from the kernel source tree!

Yay!  The suits actually lose for once!
(okay, so I can fantasize if I want to).

  reply	other threads:[~2007-09-30 17:40 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-28 21:31 [PATCH] 0/3 coding standards documentation/code updates Erez Zadok
2007-09-28 21:32 ` [PATCH 1/3] CodingStyle updates Erez Zadok
2007-09-28 21:46   ` Randy Dunlap
2007-09-29 14:43   ` Shawn Bohrer
2007-09-29 15:59   ` Scott Preece
2007-09-29 18:01   ` Randy Dunlap
2007-09-29 18:29     ` Sam Ravnborg
2007-09-29 20:21       ` [OT] kbuild syntax extension for ccflags and asflags (was: [PATCH 1/3] CodingStyle updates) Ingo Oeser
2007-09-29 20:24         ` Sam Ravnborg
2007-09-28 21:32 ` [PATCH 2/3] Update usage string for checkpatch.pl Erez Zadok
2007-09-28 21:32 ` [PATCH 3/3] New script to check coding-style compliance on multiple regular files Erez Zadok
2007-09-29 10:10   ` Sam Ravnborg
2007-09-29 18:18 ` [PATCH] 0/3 coding standards documentation/code updates Linus Torvalds
2007-09-29 19:56   ` J. Bruce Fields
2007-09-29 20:14     ` Randy Dunlap
2007-09-30  2:06     ` Theodore Tso
2007-09-30  3:28       ` Erez Zadok
2007-09-29 21:56   ` Robert P. J. Day
2007-09-30  0:23   ` Erez Zadok
2007-09-30  0:49     ` Linus Torvalds
2007-09-30  4:01       ` Erez Zadok
2007-09-30 17:40         ` Mark Lord [this message]
2007-09-30 17:59           ` Randy Dunlap
2007-09-30  2:24   ` Valdis.Kletnieks
2007-09-30  3:00     ` Linus Torvalds
2007-09-30  3:29       ` Valdis.Kletnieks
2007-09-30  3:35         ` Linus Torvalds
2007-09-30 17:57         ` Theodore Tso
2007-09-30  3:27     ` Al Viro
2007-09-30  3:39       ` Valdis.Kletnieks

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=46FFDF7D.7080605@rtr.ca \
    --to=lkml@rtr.ca \
    --cc=akpm@linux-foundation.org \
    --cc=ezk@cs.sunysb.edu \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.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