All of lore.kernel.org
 help / color / mirror / Atom feed
* checkpatch: ERROR: Does not appear to be a unified-diff format patch
@ 2007-10-13 12:28 Geert Uytterhoeven
  2007-10-13 12:47 ` Adrian Bunk
  0 siblings, 1 reply; 5+ messages in thread
From: Geert Uytterhoeven @ 2007-10-13 12:28 UTC (permalink / raw)
  To: Andy Whitcroft, Randy Dunlap, Joel Schopp; +Cc: Linux Kernel Development

scripts/checkpatch.pl doesn't seem to like this patch:

$ scripts/checkpatch.pl m68k-export-asm-cachectl-h.diff 
ERROR: Does not appear to be a unified-diff format patch

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.
$ cat m68k-export-asm-cachectl-h.diff 
Subject: m68k: Export cachectl.h

From: Matthew Wilcox <matthew@wil.cx>

libffi in GCC 4.2 needs cachectl.h to do its cache flushing.  But we
don't currently export it.  I believe this patch should do the trick.

Signed-off-by: Matthew Wilcox <matthew@wil.cx>
---
 include/asm-m68k/Kbuild |    1 +
 1 file changed, 1 insertion(+)

--- a/include/asm-m68k/Kbuild
+++ b/include/asm-m68k/Kbuild
@@ -1 +1,2 @@
 include include/asm-generic/Kbuild.asm
+header-y += cachectl.h
$ 

Gr{oetje,eeting}s,

						Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
							    -- Linus Torvalds

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

* Re: checkpatch: ERROR: Does not appear to be a unified-diff format patch
  2007-10-13 12:28 checkpatch: ERROR: Does not appear to be a unified-diff format patch Geert Uytterhoeven
@ 2007-10-13 12:47 ` Adrian Bunk
  2007-10-13 12:55   ` Jan Engelhardt
  0 siblings, 1 reply; 5+ messages in thread
From: Adrian Bunk @ 2007-10-13 12:47 UTC (permalink / raw)
  To: Geert Uytterhoeven
  Cc: Andy Whitcroft, Randy Dunlap, Joel Schopp,
	Linux Kernel Development, Matthew Wilcox

On Sat, Oct 13, 2007 at 02:28:00PM +0200, Geert Uytterhoeven wrote:
> scripts/checkpatch.pl doesn't seem to like this patch:
> 
> $ scripts/checkpatch.pl m68k-export-asm-cachectl-h.diff 
> ERROR: Does not appear to be a unified-diff format patch
>...
> --- a/include/asm-m68k/Kbuild
> +++ b/include/asm-m68k/Kbuild
> @@ -1 +1,2 @@
>... ^^

Broken patch, this has to be "-1,1".

> Gr{oetje,eeting}s,
> 
> 						Geert

cu
Adrian

-- 

       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed


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

* Re: checkpatch: ERROR: Does not appear to be a unified-diff format patch
  2007-10-13 12:47 ` Adrian Bunk
@ 2007-10-13 12:55   ` Jan Engelhardt
  2007-10-13 13:52     ` Adrian Bunk
  2007-10-13 14:47     ` Andy Whitcroft
  0 siblings, 2 replies; 5+ messages in thread
From: Jan Engelhardt @ 2007-10-13 12:55 UTC (permalink / raw)
  To: Adrian Bunk
  Cc: Geert Uytterhoeven, Andy Whitcroft, Randy Dunlap, Joel Schopp,
	Linux Kernel Development, Matthew Wilcox


On Oct 13 2007 14:47, Adrian Bunk wrote:
>On Sat, Oct 13, 2007 at 02:28:00PM +0200, Geert Uytterhoeven wrote:
>> scripts/checkpatch.pl doesn't seem to like this patch:
>> 
>> $ scripts/checkpatch.pl m68k-export-asm-cachectl-h.diff 
>> ERROR: Does not appear to be a unified-diff format patch
>>...
>> --- a/include/asm-m68k/Kbuild
>> +++ b/include/asm-m68k/Kbuild
>> @@ -1 +1,2 @@
>>... ^^
>
>Broken patch, this has to be "-1,1".

No, this is actually how diff outputs it.
/([-+]\d+)\b/ seems to imply /$1,1/

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

* Re: checkpatch: ERROR: Does not appear to be a unified-diff format patch
  2007-10-13 12:55   ` Jan Engelhardt
@ 2007-10-13 13:52     ` Adrian Bunk
  2007-10-13 14:47     ` Andy Whitcroft
  1 sibling, 0 replies; 5+ messages in thread
From: Adrian Bunk @ 2007-10-13 13:52 UTC (permalink / raw)
  To: Jan Engelhardt
  Cc: Geert Uytterhoeven, Andy Whitcroft, Randy Dunlap, Joel Schopp,
	Linux Kernel Development, Matthew Wilcox

On Sat, Oct 13, 2007 at 02:55:01PM +0200, Jan Engelhardt wrote:
> 
> On Oct 13 2007 14:47, Adrian Bunk wrote:
> >On Sat, Oct 13, 2007 at 02:28:00PM +0200, Geert Uytterhoeven wrote:
> >> scripts/checkpatch.pl doesn't seem to like this patch:
> >> 
> >> $ scripts/checkpatch.pl m68k-export-asm-cachectl-h.diff 
> >> ERROR: Does not appear to be a unified-diff format patch
> >>...
> >> --- a/include/asm-m68k/Kbuild
> >> +++ b/include/asm-m68k/Kbuild
> >> @@ -1 +1,2 @@
> >>... ^^
> >
> >Broken patch, this has to be "-1,1".
> 
> No, this is actually how diff outputs it.
>...

You seem to be right.

That's a really strange part of the unidiff format - you have to write
",0" or ",2", but you can omit a ",1".

cu
Adrian

-- 

       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed


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

* Re: checkpatch: ERROR: Does not appear to be a unified-diff format patch
  2007-10-13 12:55   ` Jan Engelhardt
  2007-10-13 13:52     ` Adrian Bunk
@ 2007-10-13 14:47     ` Andy Whitcroft
  1 sibling, 0 replies; 5+ messages in thread
From: Andy Whitcroft @ 2007-10-13 14:47 UTC (permalink / raw)
  To: Jan Engelhardt
  Cc: Adrian Bunk, Geert Uytterhoeven, Randy Dunlap, Joel Schopp,
	Linux Kernel Development, Matthew Wilcox

On Sat, Oct 13, 2007 at 02:55:01PM +0200, Jan Engelhardt wrote:
> 
> On Oct 13 2007 14:47, Adrian Bunk wrote:
> >On Sat, Oct 13, 2007 at 02:28:00PM +0200, Geert Uytterhoeven wrote:
> >> scripts/checkpatch.pl doesn't seem to like this patch:
> >> 
> >> $ scripts/checkpatch.pl m68k-export-asm-cachectl-h.diff 
> >> ERROR: Does not appear to be a unified-diff format patch
> >>...
> >> --- a/include/asm-m68k/Kbuild
> >> +++ b/include/asm-m68k/Kbuild
> >> @@ -1 +1,2 @@
> >>... ^^
> >
> >Broken patch, this has to be "-1,1".
> 
> No, this is actually how diff outputs it.
> /([-+]\d+)\b/ seems to imply /$1,1/

Yep, that occurs a lot in the second parameter which we expect this and
cope with it.  Will fix this for the next release.

Thanks for the analysis.

-apw

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

end of thread, other threads:[~2007-10-13 14:59 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-10-13 12:28 checkpatch: ERROR: Does not appear to be a unified-diff format patch Geert Uytterhoeven
2007-10-13 12:47 ` Adrian Bunk
2007-10-13 12:55   ` Jan Engelhardt
2007-10-13 13:52     ` Adrian Bunk
2007-10-13 14:47     ` Andy Whitcroft

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.