qemu-trivial
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-trivial] [Qemu-devel] [PATCH v2] m68k comments break patch sub


From: Laurent Vivier
Subject: Re: [Qemu-trivial] [Qemu-devel] [PATCH v2] m68k comments break patch submission due to being incorrectly formatted
Date: Fri, 7 Jun 2019 11:04:46 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.7.0

Le 07/06/2019 à 10:34, Peter Maydell a écrit :
> On Fri, 7 Jun 2019 at 04:30, Lucien Murray-Pitts
> <address@hidden> wrote:
>> checkpatch is correctly identifying the wrong style in the changed code.
>> This changed code contains the original comments with ADDITIONAL edits
>> resulting in pachew/checkpatch complaining.
>>
>> The m68k is, by my guess, older code and nearly all the comments are 
>> different
>> from the style guide.  Some are "/**" or "/*commment here...." and so on.
> 
> Yeah. We have a fair bit of old-style code in the codebase. There
> are two different approaches we take to this:
>  (1) the most common is "fix the parts your patch is touching anyway"
> (ie in a new-feature patch you make the minimum fixes to the surrounding
> old code needed to keep checkpatch happy with it)
>  (2) mass fix-up of old style stuff as a separate patch
> 
> Mostly we use (1) but this does have the downside that old style
> can lurk in not-often-touched files for a long time. So if the
> maintainer (in this case Laurent) is happy with a type (2) fix-up
> that's good too. (Personally I used to be much more in favour
> of sticking with approach 1 but my opinion has changed over
> time as I've seen the downsides of it.)

I also prefer (1) because (2) hides real commit modifying the code ((2)
complicates the use of 'git blame') but (1) ends with having mixed style
in one file and it's very ugly. Moreover it complicates life of new
contributors that don't know what to do with the errors from checkpatch
or patchew. So, in the case of m68k, I agree with a massive update of
the comment style.

Thanks,
Laurent



reply via email to

[Prev in Thread] Current Thread [Next in Thread]