linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Cristian Ciocaltea <cristian.ciocaltea@collabora.com>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Valentina Manea <valentina.manea.m@gmail.com>,
	Shuah Khan <shuah@kernel.org>, Hongren Zheng <i@zenithal.me>,
	"Brian G. Merrell" <bgmerrell@novell.com>,
	kernel@collabora.com, Greg Kroah-Hartman <gregkh@suse.de>,
	linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/9] usb: vhci-hcd: Fix space, brace, alignment and line length issues
Date: Fri, 18 Jul 2025 09:48:05 +0300	[thread overview]
Message-ID: <044fd9e0-b506-4b79-a708-04e40fd23935@collabora.com> (raw)
In-Reply-To: <2025071837-recoil-fifteen-a977@gregkh>

On 7/18/25 9:26 AM, Greg Kroah-Hartman wrote:
> On Thu, Jul 17, 2025 at 08:26:54PM +0300, Cristian Ciocaltea wrote:
>> On 7/17/25 7:18 PM, Greg Kroah-Hartman wrote:
>>> On Thu, Jul 17, 2025 at 06:54:51PM +0300, Cristian Ciocaltea wrote:
>>>> Perform a first round of coding style cleanup:
>>>>
>>>> * Add new lines after several statement blocks
>>>> * Avoid line wrapping when 100-column width is not exceeded and it helps
>>>>   improve code readability
>>>> * Ensure lines do not end with '('
>>>> * Drop superfluous spaces or empty lines
>>>> * Add spaces where necessary, e.g. around operators
>>>> * Add braces for single if-statements when at least one branch of the
>>>>   conditional requires them
>>>>
>>>> This helps getting rid of the following checkpatch complaints:
>>>>
>>>>   CHECK: Lines should not end with a '('
>>>>   CHECK: braces {} should be used on all arms of this statement
>>>>   CHECK: Unbalanced braces around else statement
>>>>   CHECK: Blank lines aren't necessary before a close brace '}'
>>>>   CHECK: Unnecessary parentheses around
>>>>   CHECK: Alignment should match open parenthesis
>>>>   CHECK: No space is necessary after a cast
>>>>   CHECK: spaces preferred around that '-' (ctx:VxV)
>>>>   CHECK: spaces preferred around that '+' (ctx:VxV)
>>>>
>>>> Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com>
>>>
>>> Coding style cleanups need to be "one patch per logical change", not
>>> "fix them all in one patch!" type of thing.
>>>
>>> Sorry, but can you break this out better?
>>
>> I could split this into something like:
>>
>> - Fix spaces & blank lines
>>   CHECK: Blank lines aren't necessary before a close brace '}'
>>   CHECK: No space is necessary after a cast
>>   CHECK: spaces preferred around that '-' (ctx:VxV)
>>   CHECK: spaces preferred around that '+' (ctx:VxV)
>>
>> - Fix braces
>>   CHECK: braces {} should be used on all arms of this statement
>>   CHECK: Unbalanced braces around else statement
>>
>> - Fix alignment & line length
>>   CHECK: Lines should not end with a '('
>>   CHECK: Alignment should match open parenthesis
>>   
>> - Misc?!
>>   CHECK: Unnecessary parentheses around
> 
> Why not one per CHECK: type?

I've been trying to squash all formatting changes which are kind of similar,
but sure I can handle them separately.

Thanks,
Cristian


  reply	other threads:[~2025-07-18  6:48 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-17 15:54 [PATCH 0/9] USB/IP VHCI suspend fix and driver cleanup Cristian Ciocaltea
2025-07-17 15:54 ` [PATCH 1/9] usb: vhci-hcd: Prevent suspending virtually attached devices Cristian Ciocaltea
2025-07-17 18:26   ` Alan Stern
2025-07-17 19:55     ` Shuah Khan
2025-07-18  6:41       ` Cristian Ciocaltea
2025-07-25 10:20         ` Cristian Ciocaltea
2025-07-17 15:54 ` [PATCH 2/9] usb: vhci-hcd: Fix space, brace, alignment and line length issues Cristian Ciocaltea
2025-07-17 16:18   ` Greg Kroah-Hartman
2025-07-17 17:26     ` Cristian Ciocaltea
2025-07-18  6:26       ` Greg Kroah-Hartman
2025-07-18  6:48         ` Cristian Ciocaltea [this message]
2025-07-17 15:54 ` [PATCH 3/9] usb: vhci-hcd: Simplify NULL comparison Cristian Ciocaltea
2025-07-17 15:54 ` [PATCH 4/9] usb: vhci-hcd: Simplify kzalloc usage Cristian Ciocaltea
2025-07-17 15:54 ` [PATCH 5/9] usb: vhci-hcd: Do not split quoted strings Cristian Ciocaltea
2025-07-17 16:19   ` Greg Kroah-Hartman
2025-07-17 17:35     ` Cristian Ciocaltea
2025-07-17 15:54 ` [PATCH 6/9] usb: vhci-hcd: Fix block comments Cristian Ciocaltea
2025-07-17 16:19   ` Greg Kroah-Hartman
2025-07-17 15:54 ` [PATCH 7/9] usb: vhci-hcd: Use the paranthesized form of sizeof Cristian Ciocaltea
2025-07-17 15:54 ` [PATCH 8/9] usb: vhci-hcd: Consistently use __func__ Cristian Ciocaltea
2025-07-17 16:18   ` Greg Kroah-Hartman
2025-07-17 17:43     ` Cristian Ciocaltea
2025-07-17 15:54 ` [PATCH 9/9] usb: vhci-hcd: Remove ftrace-like logging Cristian Ciocaltea

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=044fd9e0-b506-4b79-a708-04e40fd23935@collabora.com \
    --to=cristian.ciocaltea@collabora.com \
    --cc=bgmerrell@novell.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=gregkh@suse.de \
    --cc=i@zenithal.me \
    --cc=kernel@collabora.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=shuah@kernel.org \
    --cc=valentina.manea.m@gmail.com \
    /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;
as well as URLs for NNTP newsgroup(s).