Re: [Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-13 Thread Paolo Bonzini
On 13/08/2018 08:18, Thomas Huth wrote: > On 08/10/2018 02:45 PM, Paolo Bonzini wrote: >> On 10/08/2018 11:10, Peter Maydell wrote: So my proposal, which is actually consistent with what QEMU is doing, is the following: 1) the first line of a file should always be "/*", otherwis

Re: [Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-12 Thread Thomas Huth
On 08/09/2018 06:00 PM, Peter Maydell wrote: > We now require Linux-kernel-style multiline comments: > /* > * line one > * line two > */ > > Enforce this in checkpatch.pl, by backporting the relevant > parts of the Linux kernel's checkpatch.pl. (The only changes > needed are tha

Re: [Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-12 Thread Thomas Huth
On 08/10/2018 02:45 PM, Paolo Bonzini wrote: > On 10/08/2018 11:10, Peter Maydell wrote: >>> So my proposal, which is actually consistent with what QEMU is doing, is >>> the following: >>> >>> 1) the first line of a file should always be "/*", otherwise warn >>> >>> 2) a comment that starts with "/

Re: [Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-10 Thread Paolo Bonzini
On 10/08/2018 14:53, Peter Maydell wrote: >> But otherwise, at least Eric, you, me (only now I admit), Thomas >> expressed a preference for the other style; on the other side it's >> Markus, Stefan, Conny and Alex, some of whom were okay with applying >> maintainer discretion; John and rth wanted a

Re: [Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-10 Thread Markus Armbruster
Paolo Bonzini writes: > On 10/08/2018 11:41, Markus Armbruster wrote: >>> Lone "/*" or "/**": 9986 cases >>> of which in the first column: 7617 >>> of which the first line in the file (license headers): 2834 >>> regex: ^[ \t]*/\*\*?[ \t]*$ >>> >>> "/*" with the first line of the comme

Re: [Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-10 Thread Peter Maydell
On 10 August 2018 at 13:45, Paolo Bonzini wrote: > On 10/08/2018 11:10, Peter Maydell wrote: >>> So my proposal, which is actually consistent with what QEMU is doing, is >>> the following: >>> >>> 1) the first line of a file should always be "/*", otherwise warn >>> >>> 2) a comment that starts wi

Re: [Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-10 Thread Paolo Bonzini
On 10/08/2018 11:41, Markus Armbruster wrote: >> Lone "/*" or "/**": 9986 cases >> of which in the first column: 7617 >> of which the first line in the file (license headers): 2834 >> regex: ^[ \t]*/\*\*?[ \t]*$ >> >> "/*" with the first line of the comment: 11246 >> of which in

Re: [Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-10 Thread Paolo Bonzini
On 10/08/2018 11:10, Peter Maydell wrote: >> So my proposal, which is actually consistent with what QEMU is doing, is >> the following: >> >> 1) the first line of a file should always be "/*", otherwise warn >> >> 2) a comment that starts with "/**" should have it on a lone line >> >> 3) every othe

Re: [Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-10 Thread Markus Armbruster
Peter Maydell writes: > On 10 August 2018 at 07:22, Markus Armbruster wrote: >> Peter Maydell writes: >> >>> We now require Linux-kernel-style multiline comments: >>> /* >>> * line one >>> * line two >>> */ >>> >>> Enforce this in checkpatch.pl, by backporting the relevant >>

Re: [Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-10 Thread Markus Armbruster
Paolo Bonzini writes: > On 09/08/2018 19:03, Peter Maydell wrote: >> On 9 August 2018 at 17:43, Paolo Bonzini wrote: I'm still not used to the leeading-/*-on-it's-own style, so having checkpatch catch my lapses is handy... >>> >>> ... if it's not what we are using, why enforce it? >>

Re: [Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-10 Thread Peter Maydell
On 10 August 2018 at 09:34, Paolo Bonzini wrote: > This is one of the cases where we are decently consistent: > > Lone "/*" or "/**": 9986 cases > of which in the first column: 7617 > of which the first line in the file (license headers): 2834 > regex: ^[ \t]*/\*\*?[ \t]*$

Re: [Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-10 Thread Peter Maydell
On 10 August 2018 at 07:22, Markus Armbruster wrote: > Peter Maydell writes: > >> We now require Linux-kernel-style multiline comments: >> /* >> * line one >> * line two >> */ >> >> Enforce this in checkpatch.pl, by backporting the relevant >> parts of the Linux kernel's checkp

Re: [Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-10 Thread Paolo Bonzini
On 09/08/2018 19:03, Peter Maydell wrote: > On 9 August 2018 at 17:43, Paolo Bonzini wrote: >>> I'm still not used to the leeading-/*-on-it's-own style, >>> so having checkpatch catch my lapses is handy... >> >> ... if it's not what we are using, why enforce it? > > See the enormous long threads

Re: [Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-09 Thread Markus Armbruster
Peter Maydell writes: > We now require Linux-kernel-style multiline comments: > /* > * line one > * line two > */ > > Enforce this in checkpatch.pl, by backporting the relevant > parts of the Linux kernel's checkpatch.pl. (The only changes > needed are that Linux's checkpatch.p

Re: [Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-09 Thread Peter Maydell
On 9 August 2018 at 17:43, Paolo Bonzini wrote: > On 09/08/2018 18:00, Peter Maydell wrote: >> The kernel's checkpatch does not enforce "leading /* on >> a line of its own, so that part is unique to QEMU's checkpatch. > > Yeah, that's because for some reason the Linux network subsystem uses > the

Re: [Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-09 Thread Paolo Bonzini
On 09/08/2018 18:00, Peter Maydell wrote: > The kernel's checkpatch does not enforce "leading /* on > a line of its own, so that part is unique to QEMU's checkpatch. Yeah, that's because for some reason the Linux network subsystem uses the style without the lone leading "/*". Which is actually wh

[Qemu-devel] [PATCH] scripts/checkpatch.pl: Enforce multiline comment syntax

2018-08-09 Thread Peter Maydell
We now require Linux-kernel-style multiline comments: /* * line one * line two */ Enforce this in checkpatch.pl, by backporting the relevant parts of the Linux kernel's checkpatch.pl. (The only changes needed are that Linux's checkpatch.pl WARN() function takes an extra argument