On Thu, Sep 27, 2007 at 08:31:16PM +0200, Stefan Reinauer wrote:
* Uwe Hermann <uwe(a)hermann-uwe.de> [070927
No duplicated code whatsoever. Sure, this may not
be too elegant
(there's some room for improvements, though), but it's definately a
_lot_ better than duplicating all those files.
Another question: If that code needs to be duplicated for each of those
boards, is it generic (NB, SB, SUPERIO) code?
Parts of it, maybe. Didn't look closer, yet. Common component code should be
moved into the respective directory/files, of course. But there'll still
be many files/parts which are not common to the chipsets but rather
common to some (very similar) mainboards. That can (and should IMO) be
handled with a method similar to the one in my patch.
In this case, we could even rename the A8N-E directory to 'a8n-base' or
something, and make a8n-e, a8n5x, a8ne_fm_s be symlinks with only minor
differences in targets/*.
ouch.. this is really nasty ;-)
Yeah, not exactly elegant.
I didn't figure out how to do something like
if BOARD_NAME == "A8N-E"
in Config.lb, that would improve the code (number of variables) a bit.
And it will potentially make it hard for us in v3..
On the contrary, I think with kconfig we can handle this sort
of things even more easily and elegantly.
We even already have MAINBOARD_NAME etc. there, and those macros can
be used in Makefiles as well as C code, so no problem at all.