Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

checkpatch: remove custom max line length #41

Closed
wants to merge 1 commit into from

Conversation

matttbe
Copy link
Member

@matttbe matttbe commented Oct 21, 2024

I noticed that the recent trend is to avoid coding style differences between subtrees, e.g. commit 82b8000c28b5 ("net: drop special comment style") in the kernel repository.

I then wonder if this netdev specific limit still makes sense today. I didn't find anything about it in the kernel documentation, nor in the commit introducing it here in this repo: commit 950c7e3 ("bring back 80 char max len").

On MPTCP side, the preferred limit on the length of a single line is 80 columns. But when this improves the readability, some lines are a bit over 80 chars, e.g. for the parameters of a function, comments next to fields of a structure, etc. I don't think we abuse of this, but we regularly have warnings on Patchwork that we are over the 80 chars limit. I don't think we ever had any comments about that, that's why we continued to use the default limit, while still keeping most of the code under the 80 chars limit.

Then is it fine to drop this limit, and use the default one? Or should we really try to limit the length to 80 chars and the documentation needs to be updated instead?

I noticed that the recent trend is to avoid coding style differences
between subtrees, e.g. commit 82b8000c28b5 ("net: drop special comment
style") in the kernel repository.

I then wonder if this netdev specific limit still makes sense today. I
didn't find anything about it in the kernel documentation, nor in the
commit introducing it here in this repo: commit 950c7e3 ("bring back 80
char max len").

On MPTCP side, the preferred limit on the length of a single line is 80
columns. But when this improves the readability, some lines are a bit
over 80 chars, e.g. for the parameters of a function, comments next to
fields of a structure, etc. I don't think we abuse of this, but we
regularly have warnings on Patchwork that we are over the 80 chars
limit. I don't think we ever had any comments about that, that's why we
continued to use the default limit, while still keeping most of the code
under the 80 chars limit.

Then is it fine to drop this limit, and use the default one? Or should
we really try to limit the length to 80 chars and the documentation
needs to be updated instead?

Signed-off-by: Matthieu Baerts (NGI0) <[email protected]>
@jmberg
Copy link
Member

jmberg commented Oct 28, 2024

IIRC there was a netdev specific requirement to not relax it (because too many people were abusing that), but no idea if that's documented anywhere.

@kuba-moo
Copy link
Contributor

Indeed, it's intentional.

@kuba-moo kuba-moo closed this Oct 28, 2024
matttbe added a commit to multipath-tcp/mptcp-upstream-validate-export-action that referenced this pull request Nov 2, 2024
Similar to what is done in Netdev.

Link: linux-netdev/nipa#41
Signed-off-by: Matthieu Baerts (NGI0) <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants