public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Document from line in patch format
@ 2005-10-02  6:21 Paul Jackson
  2005-10-02  7:02 ` Antonino A. Daplas
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: Paul Jackson @ 2005-10-02  6:21 UTC (permalink / raw)
  To: Linus Torvalds
  Cc: Andrew Morton, Jeff Garzik, Paul Jackson, linux-kernel,
	Randy.Dunlap

Document more details of patch format such as the "from" line
used to specify the patch author, and provide more references
for patch guidelines.

Signed-off-by: Paul Jackson <pj@sgi.com>

Index: 2.6.14-rc2-mm2/Documentation/SubmittingPatches
===================================================================
--- 2.6.14-rc2-mm2.orig/Documentation/SubmittingPatches
+++ 2.6.14-rc2-mm2/Documentation/SubmittingPatches
@@ -301,8 +301,47 @@ now, but you can do this to mark interna
 point out some special detail about the sign-off. 
 
 
+12) The canonical patch format
 
-12) More references for submitting patches
+The canonical patch subject line is:
+
+    Subject: [PATCH 001/123] [<area>:] <explanation>
+
+The canonical patch message body contains the following:
+
+    The first line of the body contains a "from" line specifying
+    the author of the patch:
+
+        From: Original Author <author@email.com>
+
+    If the "from" line is missing, then the author of the patch will
+    be recorded in the source code revision history as whomever is
+    listed in the last "Signed-off-by:" line in the message when Linus
+    receives it.
+
+    The "from" line is followed by an empty line and then the body
+    of the explanation.
+
+    After the body of the explanation comes the "Signed-off-by:"
+    lines, and then a simple "---" line, and below that comes the
+    diffstat of the patch and then the patch itself.  The "---" line
+    and diffstat are optional, but helpful to readers of non-trivial
+    patches.
+
+The Subject line format makes it very easy to sort the emails
+alphabetically by subject line - pretty much any email reader will
+support that - since because the sequence number is zero-padded,
+the numerical and alphabetic sort is the same.
+
+See further details on how to phrase the "<explanation>" in
+the "Subject:" line in Andrew Morton's "The perfect patch",
+referenced below.
+
+See more details on the proper patch format in the following
+references.
+
+
+13) More references for submitting patches
 
 Andrew Morton, "The perfect patch" (tpp).
   <http://www.zip.com.au/~akpm/linux/patches/stuff/tpp.txt>
@@ -310,6 +349,14 @@ Andrew Morton, "The perfect patch" (tpp)
 Jeff Garzik, "Linux kernel patch submission format."
   <http://linux.yyz.us/patch-format.html>
 
+Jeff Garzik, "How to piss off a kernel subsystem maintainer"
+  <http://www.kroah.com/log/2005/03/31/>
+
+Kernel Documentation/CodingStyle
+  <http://lxr.linux.no/source/Documentation/CodingStyle>
+
+Linus Torvald's mail on the canonical patch format:
+  <http://lkml.org/lkml/2005/4/7/183>
 
 
 -----------------------------------

-- 
                          I won't rest till it's the best ...
                          Programmer, Linux Scalability
                          Paul Jackson <pj@sgi.com> 1.650.933.1373

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] Document from line in patch format
  2005-10-02  6:21 [PATCH] Document from line in patch format Paul Jackson
@ 2005-10-02  7:02 ` Antonino A. Daplas
  2005-10-02  7:07   ` Paul Jackson
  2005-10-02  7:20 ` Coywolf Qi Hunt
  2005-10-02 15:49 ` Greg KH
  2 siblings, 1 reply; 9+ messages in thread
From: Antonino A. Daplas @ 2005-10-02  7:02 UTC (permalink / raw)
  To: Paul Jackson
  Cc: Linus Torvalds, Andrew Morton, Jeff Garzik, linux-kernel,
	Randy.Dunlap

Paul Jackson wrote:
> Document more details of patch format such as the "from" line
> used to specify the patch author, and provide more references
> for patch guidelines.
> 
> Signed-off-by: Paul Jackson <pj@sgi.com>
> 
> Index: 2.6.14-rc2-mm2/Documentation/SubmittingPatches
> ===================================================================
> --- 2.6.14-rc2-mm2.orig/Documentation/SubmittingPatches
> +++ 2.6.14-rc2-mm2/Documentation/SubmittingPatches
> @@ -301,8 +301,47 @@ now, but you can do this to mark interna
>  point out some special detail about the sign-off. 
>  
>  
> +12) The canonical patch format
>  
> -12) More references for submitting patches
> +The canonical patch subject line is:
> +
> +    Subject: [PATCH 001/123] [<area>:] <explanation>
> +
> +The canonical patch message body contains the following:
> +
> +    The first line of the body contains a "from" line specifying
> +    the author of the patch:
> +
> +        From: Original Author <author@email.com>
> +
> +    If the "from" line is missing, then the author of the patch will
> +    be recorded in the source code revision history as whomever is
> +    listed in the last "Signed-off-by:" line in the message when Linus
                     ^^^^ 
Shouldn't this be the first?

Tony

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] Document from line in patch format
  2005-10-02  7:02 ` Antonino A. Daplas
@ 2005-10-02  7:07   ` Paul Jackson
  2005-10-02 15:33     ` Linus Torvalds
  0 siblings, 1 reply; 9+ messages in thread
From: Paul Jackson @ 2005-10-02  7:07 UTC (permalink / raw)
  To: Antonino A. Daplas; +Cc: torvalds, akpm, jgarzik, linux-kernel, rdunlap

Tony wrote:
> > +    listed in the last "Signed-off-by:" line in the message when Linus
>                      ^^^^ 
> Shouldn't this be the first?

When I sent a patch with no "from" line, and two "Signed-off-by"
lines (the patch that prompted this excursion into documentation
excellence) Linus stated that the patch author ended up coming from
the second "Signed-off-by" line.

Perhaps it "should" be the first (actually - I tend to agree),
but it seems that it "is" the last.

-- 
                  I won't rest till it's the best ...
                  Programmer, Linux Scalability
                  Paul Jackson <pj@sgi.com> 1.925.600.0401

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] Document from line in patch format
  2005-10-02  6:21 [PATCH] Document from line in patch format Paul Jackson
  2005-10-02  7:02 ` Antonino A. Daplas
@ 2005-10-02  7:20 ` Coywolf Qi Hunt
  2005-10-02 16:30   ` Paul Jackson
  2005-10-02 15:49 ` Greg KH
  2 siblings, 1 reply; 9+ messages in thread
From: Coywolf Qi Hunt @ 2005-10-02  7:20 UTC (permalink / raw)
  To: Paul Jackson
  Cc: Linus Torvalds, Andrew Morton, Jeff Garzik, linux-kernel,
	Randy.Dunlap

On 10/2/05, Paul Jackson <pj@sgi.com> wrote:
> Document more details of patch format such as the "from" line
> used to specify the patch author, and provide more references
> for patch guidelines.
>
> Signed-off-by: Paul Jackson <pj@sgi.com>
>
> Index: 2.6.14-rc2-mm2/Documentation/SubmittingPatches
> ===================================================================
> --- 2.6.14-rc2-mm2.orig/Documentation/SubmittingPatches
> +++ 2.6.14-rc2-mm2/Documentation/SubmittingPatches
> @@ -301,8 +301,47 @@ now, but you can do this to mark interna
>  point out some special detail about the sign-off.
>
>
> +12) The canonical patch format
>
> -12) More references for submitting patches
> +The canonical patch subject line is:
> +
> +    Subject: [PATCH 001/123] [<area>:] <explanation>
> +
> +The canonical patch message body contains the following:
> +
> +    The first line of the body contains a "from" line specifying
> +    the author of the patch:
> +
> +        From: Original Author <author@email.com>
> +
> +    If the "from" line is missing, then the author of the patch will
> +    be recorded in the source code revision history as whomever is
> +    listed in the last "Signed-off-by:" line in the message when Linus
> +    receives it.
> +
> +    The "from" line is followed by an empty line and then the body
> +    of the explanation.
> +
> +    After the body of the explanation comes the "Signed-off-by:"
> +    lines, and then a simple "---" line, and below that comes the
> +    diffstat of the patch and then the patch itself.  The "---" line
> +    and diffstat are optional, but helpful to readers of non-trivial
> +    patches.
> +
> +The Subject line format makes it very easy to sort the emails
> +alphabetically by subject line - pretty much any email reader will
> +support that - since because the sequence number is zero-padded,
> +the numerical and alphabetic sort is the same.
> +
> +See further details on how to phrase the "<explanation>" in
> +the "Subject:" line in Andrew Morton's "The perfect patch",
> +referenced below.
> +
> +See more details on the proper patch format in the following
> +references.
> +
> +
> +13) More references for submitting patches
>
>  Andrew Morton, "The perfect patch" (tpp).
>    <http://www.zip.com.au/~akpm/linux/patches/stuff/tpp.txt>
> @@ -310,6 +349,14 @@ Andrew Morton, "The perfect patch" (tpp)
>  Jeff Garzik, "Linux kernel patch submission format."
>    <http://linux.yyz.us/patch-format.html>
>
> +Jeff Garzik, "How to piss off a kernel subsystem maintainer"
> +  <http://www.kroah.com/log/2005/03/31/>
> +
> +Kernel Documentation/CodingStyle
> +  <http://lxr.linux.no/source/Documentation/CodingStyle>

There's another one more updated at http://sosdg.org/~coywolf/lxr/source/

> +
> +Linus Torvald's mail on the canonical patch format:
> +  <http://lkml.org/lkml/2005/4/7/183>
>

--
Coywolf Qi Hunt

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] Document from line in patch format
  2005-10-02  7:07   ` Paul Jackson
@ 2005-10-02 15:33     ` Linus Torvalds
  2005-10-02 16:28       ` Paul Jackson
  0 siblings, 1 reply; 9+ messages in thread
From: Linus Torvalds @ 2005-10-02 15:33 UTC (permalink / raw)
  To: Paul Jackson; +Cc: Antonino A. Daplas, akpm, jgarzik, linux-kernel, rdunlap



On Sun, 2 Oct 2005, Paul Jackson wrote:

> Tony wrote:
> > > +    listed in the last "Signed-off-by:" line in the message when Linus
> >                      ^^^^ 
> > Shouldn't this be the first?
> 
> When I sent a patch with no "from" line, and two "Signed-off-by"
> lines (the patch that prompted this excursion into documentation
> excellence) Linus stated that the patch author ended up coming from
> the second "Signed-off-by" line.
> 
> Perhaps it "should" be the first (actually - I tend to agree),
> but it seems that it "is" the last.

No. If there is no "From:" at the top of the body, the authorship is taken 
from the "From:" from the _email_.

Which _usually_ matches the last Signed-off-line:, of course. But can be 
anything.

		Linus

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] Document from line in patch format
  2005-10-02  6:21 [PATCH] Document from line in patch format Paul Jackson
  2005-10-02  7:02 ` Antonino A. Daplas
  2005-10-02  7:20 ` Coywolf Qi Hunt
@ 2005-10-02 15:49 ` Greg KH
  2005-10-02 16:25   ` Paul Jackson
  2 siblings, 1 reply; 9+ messages in thread
From: Greg KH @ 2005-10-02 15:49 UTC (permalink / raw)
  To: Paul Jackson
  Cc: Linus Torvalds, Andrew Morton, Jeff Garzik, linux-kernel,
	Randy.Dunlap

On Sat, Oct 01, 2005 at 11:21:35PM -0700, Paul Jackson wrote:
>  
> +Jeff Garzik, "How to piss off a kernel subsystem maintainer"
> +  <http://www.kroah.com/log/2005/03/31/>

That was written by me, not Jeff...

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] Document from line in patch format
  2005-10-02 15:49 ` Greg KH
@ 2005-10-02 16:25   ` Paul Jackson
  0 siblings, 0 replies; 9+ messages in thread
From: Paul Jackson @ 2005-10-02 16:25 UTC (permalink / raw)
  To: Greg KH; +Cc: torvalds, akpm, jgarzik, linux-kernel, rdunlap

Greg wrote:
> That was written by me, not Jeff...

Duh - you are obviously right.

I guess you will have one more item to add to your list:
  * Attribute work to the wrong author

(once again brought to you by the letters S, G, and I,
just to keep up tradition ').

A new patch forthcoming ...

-- 
                  I won't rest till it's the best ...
                  Programmer, Linux Scalability
                  Paul Jackson <pj@sgi.com> 1.925.600.0401

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] Document from line in patch format
  2005-10-02 15:33     ` Linus Torvalds
@ 2005-10-02 16:28       ` Paul Jackson
  0 siblings, 0 replies; 9+ messages in thread
From: Paul Jackson @ 2005-10-02 16:28 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: adaplas, akpm, jgarzik, linux-kernel, rdunlap

Linus wrote:
> No. If there is no "From:" at the top of the body, the authorship is taken 
> from the "From:" from the _email_.

So _that_ is the real reason it's called the "from" line,
not the "author" line.

Now it is making more sense.

New patch v2 coming soon.

-- 
                  I won't rest till it's the best ...
                  Programmer, Linux Scalability
                  Paul Jackson <pj@sgi.com> 1.925.600.0401

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] Document from line in patch format
  2005-10-02  7:20 ` Coywolf Qi Hunt
@ 2005-10-02 16:30   ` Paul Jackson
  0 siblings, 0 replies; 9+ messages in thread
From: Paul Jackson @ 2005-10-02 16:30 UTC (permalink / raw)
  To: Coywolf Qi Hunt; +Cc: torvalds, akpm, jgarzik, linux-kernel, rdunlap

Coywolf Qi Hunt wrote:
> There's another one more updated at http://sosdg.org/~coywolf/lxr/source/

Excellent - thank-you for continuing to provide us a current
Linux Cross-Reference (LXR).

An updated PATCHv2 coming soon.

-- 
                  I won't rest till it's the best ...
                  Programmer, Linux Scalability
                  Paul Jackson <pj@sgi.com> 1.925.600.0401

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2005-10-02 16:30 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-10-02  6:21 [PATCH] Document from line in patch format Paul Jackson
2005-10-02  7:02 ` Antonino A. Daplas
2005-10-02  7:07   ` Paul Jackson
2005-10-02 15:33     ` Linus Torvalds
2005-10-02 16:28       ` Paul Jackson
2005-10-02  7:20 ` Coywolf Qi Hunt
2005-10-02 16:30   ` Paul Jackson
2005-10-02 15:49 ` Greg KH
2005-10-02 16:25   ` Paul Jackson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox