From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alessandro Rubini Date: Fri, 16 Apr 2010 08:58:42 +0200 Subject: [U-Boot] [STATUS] Heads-up: Reorganize directory structure In-Reply-To: References: <20100415152247.3891BEEE8D9@gemini.denx.de> <20100413092323.44D8719F60@gemini.denx.de> <4BC6BAD2.8040908@monstr.eu> <20100415075232.77202EEE8D8@gemini.denx.de> <1271343853.6519.6.camel@localhost.localdomain> <20100415153127.GA628@morgana.gnudd.com> <1271347099.6519.18.camel@localhost.localdomain> Message-ID: <20100416065842.GA21982@morgana.gnudd.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Graeme, I reply to your messages since it gives somehow more information. I'm now not really convinced that reorganizing board directories would be a big step forward, although I still think it would be better. Si, I'm not arguing strongly, just bringing a point of view. Peter, Wolfgang, I'll try to do my homework and show how nhk8815/usb-s8815 would better share files when under cpu/, but I'm not sure to be able to complete it before a week or so. Graeme Russ: > Almost - it is more like > > board/ > $VENDOR/ > include/ > common/ > lib(?)/ > / > $BOARDA/ > $BOARDB/ > > I really like this structure, particularly if the code under > $VENDOR/[common, include, lib] is arch independent. Yes, that would be good, if it was a common case. However, arch-independent code is usually under drivers. See at91 and avr32 for example: no common code under board/atmel/ . Even boards/freescale, which has three architectures, has only MPC stuff in common/ (no arm or coldfire files, checked by extracting the CONFIG_ symbols from Makefile and grepping for them in include/configs) > If a vendor develops a new board using a different CPU or SOC they > can easily re-use all their pre-existing platform independent code > for the new board. In theory you are correct. In practice, such platform independent material is using drivers/ . > And then there is also > > board/ > $BOARDC > $BOARDD > > I've never liked code existing on multiple depths like this. Agreed. > Maybe we move towards: > > board/ > $VENDOR > include/ > lib/ > $BOARDA/ > $BOARDB/ > $_generic/ > $BOARDC/ > $BOARDD/ That's an option. But "$_generic" is inferior to "cpu-$". At least listing will all "cpu-" directories nearby. If there really was vendor-specific cross-platform code, I agree something like you suggest is best. /alessandro