Martin Roth
be08c1d6dc
Treewide: Fix incorrect SPDX license strings
...
These strings didn't match the license names exactly, so update them
to match.
Change-Id: Ib946eb15ca5fa64cbd6b657350b989b4a4c1b7b7
Signed-off-by: Martin Roth <gaumless@gmail.com >
Reviewed-on: https://review.coreboot.org/c/coreboot/+/80583
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Felix Singer <service+coreboot-gerrit@felixsinger.de >
2024-02-18 01:55:57 +00:00
Elyes Haouas
281d6623f2
lint/checkpatch.pl: Check for 0-length and 1-element arrays
...
Use C99 flexible arrays instead of deprecated fake flexible arrays.
This reduce difference with upstream.
Change-Id: I24016493280e22f34ae5cce49fe7c1f520270f9a
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76869
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@gmail.com >
2023-08-09 20:42:08 +00:00
Elyes Haouas
b8c0e326a3
lint/checkpatch: Add check for unnecessary <signed> int declarations
...
This reduce the difference with linux v6.5-rc4.
Change-Id: I64bbc09b531ea217514601386dd517af92aa40f1
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Reviewed-on: https://review.coreboot.org/c/coreboot/+/70200
Reviewed-by: Martin L Roth <gaumless@gmail.com >
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
2023-08-09 20:41:37 +00:00
Elyes Haouas
e572765be1
lint/checkpatch: Add check for old-style declarations
...
This reduce the difference with linux v6.5-rc4. and check for
const static or static <non ptr type> const declarations.
Change-Id: Ib4b37e130f2edbfe0385f0707a8c910a244bcfc7
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Reviewed-on: https://review.coreboot.org/c/coreboot/+/70202
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@gmail.com >
2023-08-09 20:41:21 +00:00
Elyes Haouas
dcb59dcec4
lint/checkpatch: Add check for initialized const char arrays
...
This reduces the difference with linux v6.5-rc4.
Change-Id: I9f0e9f12a177c32b401fda74cbb30c5c259b3744
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Reviewed-on: https://review.coreboot.org/c/coreboot/+/70201
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@gmail.com >
2023-08-09 20:40:48 +00:00
Elyes Haouas
32cae13714
lint/checkpatch.pl: Update check for TRAILING_STATEMENTS
...
This reduces the difference with linux v6.5-rc4.
Change-Id: I59d9619f2e58f24e0a5474bcfa79351e3afb933d
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76870
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@gmail.com >
2023-08-09 20:40:34 +00:00
Elyes Haouas
d2bb4858f3
lint/checkpatch: Update 'check for illegal assignment in if conditional'
...
This reduce the difference with linux v6.5-rc4.
Change-Id: I63b3561471d3bd0ebfe7e5733c6dd6fb673904e0
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Reviewed-on: https://review.coreboot.org/c/coreboot/+/65829
Reviewed-by: Martin L Roth <gaumless@gmail.com >
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
2023-08-09 20:40:10 +00:00
Martin Roth
57f1162363
util/lint: Ignore braces around single line statements
...
In a recent coreboot leadership meeting, the decision was made to allow
(but not require) braces around single line statements if the author
wishes to put them in.
This patch removes the checks for single line statement blocks, while
still checking for other issues in braces.
Just because they're allowed now, please do not reformat the entire
codebase to add them. coreboot has a policy of not making widespread
changes to the entire codebase unless something actually violates the
style guidelines.
Signed-off-by: Martin Roth <gaumless@gmail.com >
Change-Id: I137b10889ec880959c4c1b035dc54bf8ebf32488
Reviewed-on: https://review.coreboot.org/c/coreboot/+/73515
Reviewed-by: Felix Held <felix-coreboot@felixheld.de >
Reviewed-by: Elyes Haouas <ehaouas@noos.fr >
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
2023-03-07 21:34:11 +00:00
Elyes Haouas
2ed4b0bd7c
lint/checkpatch.pl: Remove check for keyword 'boolean' in Kconfig
...
We can not use 'boolean' since commit 53ea1d44 "util/kconfig: Uprev to Linux 5.13's kconfig".
This also reduce difference with upstream.
Change-Id: Iff9fbde46784547c07726816d2fdd71967e0595e
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Reviewed-on: https://review.coreboot.org/c/coreboot/+/71940
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Lean Sheng Tan <sheng.tan@9elements.com >
Reviewed-by: Maximilian Brune <maximilian.brune@9elements.com >
Reviewed-by: Felix Singer <felixsinger@posteo.net >
2023-02-17 14:50:29 +00:00
Elyes Haouas
d27b2e818b
lint/checkpatch: Add XA_STATE and XA_STATE_ORDER to the macro declaration
...
This reduce the difference with linux v6.0-rc3.
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Change-Id: Ica20264d744ea8f77b56c63d29e1fafc2e68a869
Reviewed-on: https://review.coreboot.org/c/coreboot/+/67338
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@gmail.com >
2022-11-24 06:05:27 +00:00
Michael Niewöhner
8cfd3f88d3
checkpatch: add Co-authored-by to signature list
...
Co-authored-by is commonly used for changes that have more than one
author. Add it to the list to make Jenkins happy.
Change-Id: I7f66824febe3be756c64ebf44c94bc653a66f1e1
Signed-off-by: Michael Niewöhner <foss@mniewoehner.de >
Reviewed-on: https://review.coreboot.org/c/coreboot/+/69166
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Angel Pons <th3fanbus@gmail.com >
Reviewed-by: Patrick Georgi <patrick@coreboot.org >
2022-11-04 00:36:11 +00:00
Michael Niewöhner
8eb7b35010
lint/checkpatch: consider leading + in the line length limit check
...
The line length limit in coreboot's coding style guidelines applies to
the final file, while checkpatch currently checks the patch line length.
Since patches´ lines start with a `+` (only added content is checked),
the line length being checked is one character longer than the actual
content.
Increase max_line_length by 1 to take this into account.
Change-Id: I8da45bb0d5fbe7d0e12c8b181cf01e5685186bf6
Signed-off-by: Michael Niewöhner <foss@mniewoehner.de >
Reviewed-on: https://review.coreboot.org/c/coreboot/+/68869
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Tim Wawrzynczak <inforichland@gmail.com >
2022-10-28 15:57:06 +00:00
Elyes Haouas
0d42db666b
lint/checkpatch: Fix incorrect camelcase detection on numeric constant
...
This reduce the difference with linux v6.0-rc3.
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Change-Id: I15e1a935665c38b8a2109d412b1d16f935cbb402
Reviewed-on: https://review.coreboot.org/c/coreboot/+/67337
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@gmail.com >
2022-09-06 17:59:55 +00:00
Elyes Haouas
50eef6566b
lint/checkpatch: Add check for used comma where semicolon could be
...
This reduce the difference with linux v5.19-rc7.
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Change-Id: I6d3a49378008bad61b2a18bd8cb28be952a18006
Reviewed-on: https://review.coreboot.org/c/coreboot/+/65837
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@tutanota.com >
2022-07-19 01:48:35 +00:00
Elyes Haouas
f9a3554a4a
lint/checkpatch: Add a check for use of self-assignments
...
This reduce the difference with linux v5.19-rc7.
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Change-Id: If47a7826ee67a2be25a4caa2a447484e5f11411b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/65836
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@tutanota.com >
2022-07-19 01:48:24 +00:00
Elyes Haouas
e83e090b05
lint/checkpatch: Add a check for existence of a commit log
...
This reduce the difference with linux v5.19-rc7.
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Change-Id: I4e3b98140d900c5717f4badde71c7be88fd1e23a
Reviewed-on: https://review.coreboot.org/c/coreboot/+/65835
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@tutanota.com >
2022-07-19 01:48:13 +00:00
Elyes Haouas
6e84c2ca70
lint/checkpatch: Update 'Check patch "separator" and "signoff"'
...
This reduce the difference with linux v5.19-rc7.
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Change-Id: Id3d7375216af5bf75ed7ce61fa8ea2dfebe8ac77
Reviewed-on: https://review.coreboot.org/c/coreboot/+/65834
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@tutanota.com >
2022-07-19 01:47:59 +00:00
Elyes Haouas
cb346842ad
lint/checkpatch: Update 'check for unwanted Gerrit info'
...
This reduce the difference with linux v5.19-rc7.
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Change-Id: I856bfa0f0d39fda549671b1029cccdc39f831bab
Reviewed-on: https://review.coreboot.org/c/coreboot/+/65833
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@tutanota.com >
2022-07-19 01:47:49 +00:00
Elyes Haouas
e235a0de18
lint/checkpatch: Update 'uncoalesced string fragments'
...
This reduce the difference with linux v5.19-rc7.
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Change-Id: I21b2a0d87cbf610fc48e273ed78ab779ad4a6932
Reviewed-on: https://review.coreboot.org/c/coreboot/+/65832
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@tutanota.com >
2022-07-19 01:47:34 +00:00
Elyes Haouas
71bfcf528d
lint/checkpatch: Update 'concatenated string without spaces between elements'
...
This reduce the difference with linux v5.19-rc7.
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Change-Id: I04e58aca4a30e82f3da0cda08403d0daf3b5fb10
Reviewed-on: https://review.coreboot.org/c/coreboot/+/65831
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@tutanota.com >
2022-07-19 01:47:17 +00:00
Elyes Haouas
a59a87ca17
lint/checkpatch: Update 'check indentation of a line with a break'
...
This reduce the difference with linux v5.19-rc7.
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Change-Id: I79170a45cd8184ebc816b4f16656a3cfdc257f60
Reviewed-on: https://review.coreboot.org/c/coreboot/+/65828
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@tutanota.com >
2022-07-19 01:46:40 +00:00
Elyes Haouas
d92fcf448f
lint/checkpatch: Update 'check for logical continuations'
...
This reduce the difference with linux v5.19-rc7.
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Change-Id: I222e3378ded4cd73d0141cd1e38ac3282d311cc4
Reviewed-on: https://review.coreboot.org/c/coreboot/+/65827
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@tutanota.com >
2022-07-19 01:46:22 +00:00
Elyes Haouas
86e4a3ae05
lint/checkpatch: Update 'check for adding lines without a newline'
...
This reduce the difference with linux v5.19-rc7.
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Change-Id: I1bd68e9a6609a3dfa7dc856f24e4b616714d9990
Reviewed-on: https://review.coreboot.org/c/coreboot/+/65826
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@tutanota.com >
2022-07-19 01:46:09 +00:00
Elyes Haouas
c5ede53ba8
lint/checkpatch: Update 'check for assignments on the start of a line'
...
This reduce the difference with linux v5.19-rc7.
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Change-Id: Ia7d4b0176bad849e79f037f74c3d99ce9eb061c0
Reviewed-on: https://review.coreboot.org/c/coreboot/+/65825
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@tutanota.com >
2022-07-19 01:45:55 +00:00
Elyes Haouas
709fdb1995
util/lint/checkpatch: Add alloc functions to alloc with multiplies check
...
This reduce difference with linux v5.18.
Change-Id: Id9412f7b6c0b9f76b39a094142aaded5c2aa1059
Signed-off-by: Elyes Haouas <ehaouas@noos.fr >
Reviewed-on: https://review.coreboot.org/c/coreboot/+/64740
Tested-by: build bot (Jenkins) <no-reply@coreboot.org >
Reviewed-by: Martin L Roth <gaumless@tutanota.com >
2022-05-29 14:55:38 +00:00