Re: [patch -mm 4/4] mempolicy: remove includes for duplicateheaders

From: Andrew Morton
Date: Fri Mar 07 2008 - 03:46:25 EST


On Thu, 6 Mar 2008 15:01:48 -0600 Paul Jackson <pj@xxxxxxx> wrote:

> David wrote:
> > It simply decreases the remote chance later that ...
> >
> > The only way this would make things more fragile is if ...
>
> Does anyone lurking on this thread know if there is an
> established convention in kernel code, whether to directly
> include all headers that your code explicitly needs, or
> whether it's ok to rely on indirect includes for such?
>
> David and I could debate the fine points of which way is
> best until the cows come home; the two of us are good at
> that. This is too minor an issue for that sort of effort.
>

Directly including what you need is more robust than a) relying upon nested
inclusions by includees or b) relying upon preceding inclusions by
includers.

So we usually go that way, when we notice it and when we think about it.

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/