Re: Module versioning (was: Re: OFFTOPIC: binary modules, bad idea!)

Stefan Monnier (monnier+lists/linux/kernel/news/@TEQUILA.SYSTEMSZ.CS.YALE.EDU)
21 Dec 1997 11:13:11 -0500

Jacques Gelinas <> writes:
> As far as I know from my own experience with kernel design (umsdos), most
> kernel structure are often tricky to manipulate (access count, locking,
> mutex, whatever) so most operation are done using helper functions. Also,
> a lot of kernel structure are making reference to other structure using
> pointers.

And the standard C way to express what you want is to have

struct foo;

in your foo.h and

struct foo {
int bar;

in foo.c. If you really need the full struct definition in more than one file,
than you can move the struct definition into foo_intern.h.