Thread (17 messages) 17 messages, 4 authors, 2011-01-10

Re: [PATCH] Cleanup include/net/tcp.h include-files and coding-style

flat view

From: Alexey Dobriyan <hidden>
Date: 2011-01-10 12:12:49
Also in: lkml

2011/1/10 Christoph Paasch [off-list ref]:
On Monday, January 10, 2011 wrote Alexey Dobriyan:
quoted
quoted
quoted
linux/percpu_counter.h (needed for percpu_counter_sum_positive)
Yes.
Currently code compiles fine, so necessary headers are in place,
so simply adding new headers doesn't help anything.
I totally agree with you.
However we need a consistent coding style.

Or we just include the minimum necessary headers (as originally proposed by
me).
Or we include every header whose structs/functions are referenced.
This is false dichotomy and extreme siding.

We need code that compiles.
We need headers to include realistically minimum amount of stuff (not
#include lines,
but stuff)
In my opinion the current "mixed" state is not ok, because some includes are
there because there *are* references (even if these includes could be omitted,
e.g., linux/list.h).
Other includes (like linux/percpu_counter.h) are not there, because they are
indirectly included by another header and thus the code compiles. Even if
there are references.
And there are no rules/guidelines to identify the headers that should be
included and those that should not.
That because the issue not that important. :-)
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help