[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1294614389.2823.35.camel@localhost>
Date: Sun, 09 Jan 2011 23:06:29 +0000
From: Ben Hutchings <bhutchings@...arflare.com>
To: christoph.paasch@...ouvain.be
Cc: Randy Dunlap <rdunlap@...otime.net>, davem@...emloft.net,
netdev@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] Cleanup include/net/tcp.h include-files and
coding-style
On Sun, 2011-01-09 at 23:33 +0100, Christoph Paasch wrote:
> On Sunday, January 09, 2011 wrote Ben Hutchings:
> > The cost of repeated inclusion is minimal. GCC's preprocessor
> > recognises when the entire content of a file is conditional on #ifndef
> > FOO and will not even open it again if FOO is defined.
> Thanks, I did not knew about that.
>
> > If a file directly references definitions that are supposed to be
> > provided by a certain header, changing it to rely on indirect inclusion
> > of that header generally does *not* aid maintenance.
> But then, to be coherent, we would need to add the following includes (and I'm
> even not 100% sure if it's all we need):
>
> linux/percpu_counter.h (needed for percpu_counter_sum_positive)
Yes.
> linux/mm_types.h (needed for struct page)
> linux/aio.h (needed for struct kiocb)
> net/inet_sock.h (needed for struct ip_options)
> linux/pipe_fs_i.h (needed for struct pipe_inode_info)
> linux/poll.h (needed for struct poll_table_struct)
Or declarations of those structs.
> linux/compiler.h (needed for __percpu)
[...]
Yes.
Ben.
--
Ben Hutchings, Senior Software Engineer, Solarflare Communications
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists