Thread (138 messages) flat view 138 messages, 14 authors, 2012-05-24
STALE5187d

[PATCH] arm: Add basic support for new Marvell Armada SoC family

From: Jason Cooper <hidden>
Date: 2012-05-21 15:35:59

On Mon, May 21, 2012 at 10:30:42AM +0100, Russell King - ARM Linux wrote:
On Sun, May 20, 2012 at 09:30:50PM -0400, Jason Cooper wrote:
quoted
On Sun, May 20, 2012 at 12:10:25PM +0100, Russell King - ARM Linux wrote:
quoted
On Sun, May 20, 2012 at 10:58:37AM +0000, Arnd Bergmann wrote:
quoted
On Sunday 20 May 2012, Russell King - ARM Linux wrote:
quoted
And try to avoid putting anything in the include/mach/ directory which
isn't needed by any code outside of arch/arm/{plat,mach}-* directory.

In other words, headers needed only for code in arch/arm/plat-mvvebu/
should be in that very same directory.
Ok, so let me make sure I got it all right:

* all *.c files that are used for multiple boards go to plat-mvebu
* all *-setup.c files go to mach-mvebu
* only headers that are used outside of {mach,plat}-mvebug go to
  plat-mvebu/include/mach
plat-mvebu/include/plat ?
Better.
quoted
quoted
quoted
* headers used to inteface between the first two go to
  plat-mvebu/include/plat (?)
plat-mvebu/include ?
No, we don't put include files in that directory, always a subdirectory.
But note - any header file used _only_ by files in plat-mvebu should be
in plat-mvebu itself and not some subdirectory.  Locality of reference
is the key idea there.
Got it, thanks for the clarification.
quoted
quoted
That sounds reasonable.  The only eyebrow raising thing is having an
include/mach inside a plat-* directory... that seems an odd way to do
things as mach/ includes normally come from the mach-* directory.

So I wonder whether Nicolas' idea of "dt-only stuff in arch/arm/plat-*"
is the right idea.  It just makes plat-* the same as a mach-* but with
a different name, whereas it is _supposed_ to be for stuff shared
between a bunch of mach-* directories.
In an ideal (dt) world, plat-*/ would hold all the dt source files, and
arch/arm/boot/dts/ would become the new mach-*/.  mach-*/ is kept around
for the few legacy, unconverted boards.
At that point I'd suggest the plat-* is renamed to mach-* ;)

plat-* was only invented to allow SoC folk to have some place to put
common code shared between a set of mach-*, and nothing more.
So lets follow that to it's logical end.  How about we rename
plat-orion/ to mach-mvebu/, put all dt-compatible code in mach-mvebu/,
and empty the remaining mach-*/'s as they get converted?

mach-mvebu/'s directory tree structure could be:
	include/	# no headers
	include/mach/	# headers used by drivers, etc
	include/board/	# common headers used by legacy board files
	board/		# common source code for legacy board files

The end goal being to empty and remove the board/'s and remove the other
mach-*/ directories.

Alternatively, in this scenario we could name 'board' -> 'legacy' to
make it more obvious.

thx,

Jason.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help