Re: [2.1.36] parport_procfs.c

Wilfred Brown (wilfred@bayserve.net)
Thu, 08 May 1997 21:43:35 -0400


Philip Blundell wrote:
>
> On 7 May 1997, Matthias Urlichs wrote:
>
> > Tim Waugh <tmw20@cam.ac.uk> writes:
> > > This patch is needed for 2.1.36 (on the Alpha at least).
> > >
> > > -#include <linux/interrupt.h>
> > > #include <linux/ioport.h>
> > > #include <linux/kernel.h>
> > > #include <linux/malloc.h>
> > > +#include <linux/interrupt.h>
> >
> > That's not the correct fix. The correct fix is to have {whatever .h file
> > which needs linux/interrupt.h}.h to include that file by itself.
>
> No, Tim's fix is the correct one. We ought to try to avoid introducing
> ever more #includes between header files. It's no great hardship to
> have to include things in the right order. Otherwise, you end up pulling
> in frequently-used files twenty times, which doesn't do any real harm but
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> is a waste of time.
>
> p.

A quick look at /usr/src/linux/include/linux/*.h shows that most (all?)
files are properly ifdef'ed so that files are only included once. So
you'll have to fall back on a different argument.

Will