Subject: Re: port-sparc/5220: after autoconfig changes, impossible to build sun4c-only kernel
To: Todd Vierling <tv@NetBSD.ORG>
From: Jason Thorpe <thorpej@nas.nasa.gov>
List: netbsd-bugs
Date: 03/27/1998 15:33:37
On Fri, 27 Mar 1998 18:30:36 -0500 (EST)
Todd Vierling <tv@netbsd.org> wrote:
> : For every driver that has multiple attachments, the file needs to
> : be split like so (example is clock.c):
> :
> : Mostek clock common code: clock.c
> : mainbus attachment: clock_mainbus.c
> : obio attachment: clock_obio.c
>
> That's a lot of source bloat for what it's worth. Wouldn't it be easier to
> set the busses to have `needs-flag' in files.sparc, and #if-conditionalize
> the appropriate code? With needs-flag and use of the proper
> config-generated .h file, as long as you do the proper "make depend", it
> will rebuild those files that change with these flags when appropriate.
No, it's not, really. It's no more source bloat than we currently have,
and is consistent with how the rest of the tree works.
Basically: "Splitting it is correct. All other approaches are not." (At
least in the context of how we do things in NetBSD :-)
Jason R. Thorpe thorpej@nas.nasa.gov
NASA Ames Research Center Home: +1 408 866 1912
NAS: M/S 258-5 Work: +1 650 604 0935
Moffett Field, CA 94035 Pager: +1 415 428 6939