Subject: Re: pkg/10616: sparc/cpu.h includes non-installed kernel includes
To: =?iso-8859-1?Q?Jarom=EDr_Dole=E8ek?= <dolecek@ibis.cz>
From: Andrew Brown <atatat@atatdot.net>
List: tech-kern
Date: 08/03/2000 16:03:14
>(moving to tech-kern)
(following up :)
>> only that i don't think it will work. or that it will be very
>> difficult at the very least. at one i needed to include sys/lockf.h
>> in a userland program.
>
>This makes me curious - what do you need sys/lockf.h for in userland
>program ? Some kernel groveller ? The contents are not usable
>at all for userland otherwise (it defines some internal kernel API).
i was fiddling with lsof 4.51D (the mother of all kmem grovellers) and
it needs it. when it's processing a vnode, it looks at stuff in there
to print out locks on file descriptors, if any.
on the other hand...it only needs the forward struct declaration to
get rid of the warning from the prototype for lf_advlock(), a function
it will *never* call. if the function prototypes were protected from
normal inclusion by a _KERNEL define wrapper, then i think the problem
could be reduced.
--
|-----< "CODE WARRIOR" >-----|
codewarrior@daemon.org * "ah! i see you have the internet
twofsonet@graffiti.com (Andrew Brown) that goes *ping*!"
andrew@crossbar.com * "information is power -- share the wealth."