Re: 1131 unneeded includes in the kernel...

2000-09-21 Thread Greg Lehey

On Wednesday, 20 September 2000 at  3:10:21 -0400, Brandon D. Valentine wrote:
> On Tue, 19 Sep 2000, Matthew Jacob wrote:
>
>>
>> Oh- don't get me wrong. Valuable info. Thanks.
>
> What would be very cool is to feed this into another script which strips
> these unnecesary includes out.  Then do a test build of LINT in your
> local tree and if it succeeds commit a mass removal of them.  The same
> concept could be applied to the greater source tree.

Things aren't that simple.  I've checked some of the vinum ones, and I
find something like:

 #ifdef VINUMDEBUG
 #include 
 #endif

sys/reboot.h has been flagged as unnecessary.  Obviously the #ifdef's
have to do as well--if the script is correct.  There are a number of
options in Vinum which never get as far as the source tree.

Greg
--
Finger [EMAIL PROTECTED] for PGP public key
See complete headers for address and phone numbers


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: 1131 unneeded includes in the kernel...

2000-09-20 Thread Mark Murray


> UNNEEDED #includes in the FreeBSD kernel
:
:
> dev/randomdev/harvest.c
>   
>   
>   
> 
> dev/randomdev/hash.c
>   
>   
> 
> dev/randomdev/randomdev.c
>   
>   
> 
> dev/randomdev/yarrow.c
>   
>   
...

Thanks! Dealt with.

M
--
Mark Murray
Join the anti-SPAM movement: http://www.cauce.org


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: 1131 unneeded includes in the kernel...

2000-09-20 Thread Warner Losh

In message <98558.969478759@critter> Poul-Henning Kamp writes:
: In message <[EMAIL PROTECTED]>, Warner Losh writes:
: >In message <94952.969433843@critter> Poul-Henning Kamp writes:
: >: Oh, forgot to say: it could also be indicative of options not
: >: excercised by NOTES/LINT...
: >
: >There are a few NEWCARD/OLDCARD issues that you catch here  I'll
: >fix the rest.  Thanks!
: 
: Yeah, from time to time we have mutually exclusive options, it may
: be an idea to introduce an LINT2 kernel to contain the options
: which cannot co-exist in LINT.

I'd planned on doing that when I had a working NEWCARD.  That should
happen fairly soon, if I can ever thread the knot on the legacy
interface.

Warner


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: 1131 unneeded includes in the kernel...

2000-09-20 Thread Poul-Henning Kamp

In message <[EMAIL PROTECTED]>, Warner Losh writes:
>In message <94952.969433843@critter> Poul-Henning Kamp writes:
>: Oh, forgot to say: it could also be indicative of options not
>: excercised by NOTES/LINT...
>
>There are a few NEWCARD/OLDCARD issues that you catch here  I'll
>fix the rest.  Thanks!

Yeah, from time to time we have mutually exclusive options, it may
be an idea to introduce an LINT2 kernel to contain the options
which cannot co-exist in LINT.

--
Poul-Henning Kamp   | UNIX since Zilog Zeus 3.20
[EMAIL PROTECTED] | TCP/IP since RFC 956
FreeBSD coreteam member | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: 1131 unneeded includes in the kernel...

2000-09-20 Thread Warner Losh

In message <94952.969433843@critter> Poul-Henning Kamp writes:
: Oh, forgot to say: it could also be indicative of options not
: excercised by NOTES/LINT...

There are a few NEWCARD/OLDCARD issues that you catch here  I'll
fix the rest.  Thanks!

Warner


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: 1131 unneeded includes in the kernel...

2000-09-20 Thread Alfred Perlstein

* Poul-Henning Kamp <[EMAIL PROTECTED]> [000919 23:51] wrote:
> 
> UNNEEDED #includes in the FreeBSD kernel
> 
> agp_if.c
>   
> 

[snip]

These reports would be a lot more useful if you included the last person
to touch these files along with the first line of the Copyright.

-Alfred


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



RE: 1131 unneeded includes in the kernel...

2000-09-20 Thread John Baldwin


On 20-Sep-00 Poul-Henning Kamp wrote:
> 
> UNNEEDED #includes in the FreeBSD kernel

Err, how exactly are you generating these?

> i386/i386/db_interface.c
>   

If you compile a kernel with KTR and DDB. *bewm*
If you are using LINT for these tests, then it probably
means that the KTR #define's aren't in NOTES, which I'll
put on the todo list.
 
> i386/i386/synch_machdep.c
>   

Err, if DDB is defined, this file looks at db_active, which
is declared in 

-- 

John Baldwin <[EMAIL PROTECTED]> -- http://www.FreeBSD.org/~jhb/
PGP Key: http://www.cslab.vt.edu/~jobaldwi/pgpkey.asc
"Power Users Use the Power to Serve!"  -  http://www.FreeBSD.org/


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: 1131 unneeded includes in the kernel...

2000-09-20 Thread Matthew Jacob



On Wed, 20 Sep 2000, Poul-Henning Kamp wrote:

> In message <[EMAIL PROTECTED]>, Matthew J
> acob writes:
> >
> >How did you manage to generate this list. You're smoking
> >crack on this one
> >
> >> dev/isp/isp_target.c
> >>
> >> 
> >
> >as the isp_OS_PLATFORM.h includes is the only include this file has.
> 
> Oh, forgot to say: it could also be indicative of options not
> excercised by NOTES/LINT...

Yup.





To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: 1131 unneeded includes in the kernel...

2000-09-20 Thread Matthew Jacob



On Wed, 20 Sep 2000, Poul-Henning Kamp wrote:

> In message <[EMAIL PROTECTED]>, Matthew J
> acob writes:
> >
> >How did you manage to generate this list. You're smoking
> >crack on this one
> >
> >> dev/isp/isp_target.c
> >>
> >> 
> >
> >as the isp_OS_PLATFORM.h includes is the only include this file has.
> 
> Well,
> 
> According to src/tools/tools/kerninclude that include is not even
> needed.
> 
> I'm not claiming that every single line is dogmatically true, but
> at least it merits some amount of investigation...

Sure.

But your tool did not try the ISP_TARGET_MODE kernel option, which is what
would then cause this file to even be compiled. The compile would fail, since
99% of all defined values, as in CT_SENDSTATUS and so on, are in files brought
in by that header.

I think I see what it is. The includes are outside the

#ifdef ISP_TARGET_MODE

but still

As you say- merited investigation. Thanks.




To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: 1131 unneeded includes in the kernel...

2000-09-20 Thread Poul-Henning Kamp

In message <[EMAIL PROTECTED]>, "Br
andon D. Valentine" writes:
>On Tue, 19 Sep 2000, Matthew Jacob wrote:
>
>>
>>Oh- don't get me wrong. Valuable info. Thanks.
>
>What would be very cool is to feed this into another script which strips
>these unnecesary includes out.  Then do a test build of LINT in your
>local tree and if it succeeds commit a mass removal of them.  The same
>concept could be applied to the greater source tree.

This is found by compiling i386/conf/GENERIC, i386/conf/NOTES, 
pc98/conf/GENERIC and all modules, but I cannot test on alpha
and there are various bogosities which can give false positives
on this list.

--
Poul-Henning Kamp   | UNIX since Zilog Zeus 3.20
[EMAIL PROTECTED] | TCP/IP since RFC 956
FreeBSD coreteam member | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: 1131 unneeded includes in the kernel...

2000-09-20 Thread Matthew Jacob


Yes, but no. Let the MAINTAINERS shoot their own lines. A script with nag mail
is good though.



On Wed, 20 Sep 2000, Brandon D. Valentine wrote:

> On Tue, 19 Sep 2000, Matthew Jacob wrote:
> 
> >
> >Oh- don't get me wrong. Valuable info. Thanks.
> 
> What would be very cool is to feed this into another script which strips
> these unnecesary includes out.  Then do a test build of LINT in your
> local tree and if it succeeds commit a mass removal of them.  The same
> concept could be applied to the greater source tree.
> 
> Brandon D. Valentine
> -- 
> bandix at looksharp.net  |  bandix at structbio.vanderbilt.edu
> "Truth suffers from too much analysis." -- Ancient Fremen Saying
> 



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: 1131 unneeded includes in the kernel...

2000-09-20 Thread Poul-Henning Kamp

In message <[EMAIL PROTECTED]>, Matthew J
acob writes:
>
>How did you manage to generate this list. You're smoking
>crack on this one
>
>> dev/isp/isp_target.c
>>  
>> 
>
>as the isp_OS_PLATFORM.h includes is the only include this file has.

Oh, forgot to say: it could also be indicative of options not
excercised by NOTES/LINT...

--
Poul-Henning Kamp   | UNIX since Zilog Zeus 3.20
[EMAIL PROTECTED] | TCP/IP since RFC 956
FreeBSD coreteam member | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: 1131 unneeded includes in the kernel...

2000-09-20 Thread Kris Kennaway

On Wed, 20 Sep 2000, Brandon D. Valentine wrote:

> On Tue, 19 Sep 2000, Matthew Jacob wrote:
> 
> >
> >Oh- don't get me wrong. Valuable info. Thanks.
> 
> What would be very cool is to feed this into another script which strips
> these unnecesary includes out.  Then do a test build of LINT in your
> local tree and if it succeeds commit a mass removal of them.  The same
> concept could be applied to the greater source tree.

...except to the KAME bits, where we don't make gratuitous changes.

Kris

--
In God we Trust -- all others must submit an X.509 certificate.
-- Charles Forsythe <[EMAIL PROTECTED]>



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: 1131 unneeded includes in the kernel...

2000-09-20 Thread Poul-Henning Kamp

In message <[EMAIL PROTECTED]>, Matthew J
acob writes:
>
>How did you manage to generate this list. You're smoking
>crack on this one
>
>> dev/isp/isp_target.c
>>  
>> 
>
>as the isp_OS_PLATFORM.h includes is the only include this file has.

Well,

According to src/tools/tools/kerninclude that include is not even
needed.

I'm not claiming that every single line is dogmatically true, but
at least it merits some amount of investigation...

--
Poul-Henning Kamp   | UNIX since Zilog Zeus 3.20
[EMAIL PROTECTED] | TCP/IP since RFC 956
FreeBSD coreteam member | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: 1131 unneeded includes in the kernel...

2000-09-20 Thread Brandon D. Valentine

On Tue, 19 Sep 2000, Matthew Jacob wrote:

>
>Oh- don't get me wrong. Valuable info. Thanks.

What would be very cool is to feed this into another script which strips
these unnecesary includes out.  Then do a test build of LINT in your
local tree and if it succeeds commit a mass removal of them.  The same
concept could be applied to the greater source tree.

Brandon D. Valentine
-- 
bandix at looksharp.net  |  bandix at structbio.vanderbilt.edu
"Truth suffers from too much analysis." -- Ancient Fremen Saying



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: 1131 unneeded includes in the kernel...

2000-09-19 Thread Matthew Jacob


Oh- don't get me wrong. Valuable info. Thanks.





To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: 1131 unneeded includes in the kernel...

2000-09-19 Thread Matthew Jacob


How did you manage to generate this list. You're smoking
crack on this one

> dev/isp/isp_target.c
>   
> 

as the isp_OS_PLATFORM.h includes is the only include this file has.

-matt




To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message