Re: [PATCH V6 2/2] checkpatch: check format of Vec<String> in modules

From: Andreas Hindborg
Date: Tue Mar 04 2025 - 07:16:40 EST


"Guilherme Giacomo Simoes" <trintaeoitogc@xxxxxxxxx> writes:

> Implement a check to ensure that the author, firmware, and alias fields
> of the module! macro are properly formatted.
>
> * If the array contains more than one value, enforce vertical
> formatting.
> * If the array contains only one value, it may be formatted on a single
> line
>
> Signed-off-by: Guilherme Giacomo Simoes <trintaeoitogc@xxxxxxxxx>

Tested-by: Andreas Hindborg <a.hindborg@xxxxxxxxxx>

Does what it says on the label. However, indentation is not checked and
the following is passing:

authors: [
"John Doe",
"Foo Bar"
],

Another thing: I'm wondering if we could have a rust hostprog to do
this check, rather than a perl script?


Best regards,
Andreas Hindborg