login
Header Space

 
 

Re: Moving include/asm-* [was: Re: Moving sound/* to drivers/ ?]

Score:
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Paul Mackerras <paulus@...>
Cc: Takashi Iwai <tiwai@...>, <linux-kernel@...>
Date: Wednesday, May 21, 2008 - 7:51 pm

On Thu, 22 May 2008, Paul Mackerras wrote:

That would work, but there's a few alternatives that I think would work 
even better.

The downside with what you suggest is that I'd like the arch-specific 
include files to be clearly separated (ie I think the naming should be 
"something/include/something", which makes things clearer. 

Also, I hate how doing '-Iarch/$(ARCH)' would basically make any random 
arch/xyz/ subdirectory be a potential location for a header file. I'd hate 
for the include-path to contain subdirectories that simply aren't meant 
for that (ie #include <kernel/tls.h> would now quite by mistake find the 
*private* header file in arch/x86/kernel/tls.h that was never meant to be 
generally visible!)

So the trivial alternative is to just do

	git mv include/asm-xyz arch/xyz/include

and keep the symlink that we already set up (just make it point to 
arch/xyz/include instead of include/asm-xyz). That is conceptually the 
smallest change.

But the alternative I'd actually *prefer* would avoid the symlink, and 
would be roughly:

	for i in $(arch-list)
	do
		mkdir arch/$i/include
		git mv include/asm-$i arch/$i/asm
		
	done
	git mv include/asm-generic include/asm

and then remove the symlink to asm entirely, and instead add a 
-Iarch/xyz/include, and put that as the *first* entry in the include path.

This would mean that:

 - no symlink games

 - if some architecture just uses the generic header file, it doesn't need 
   to do anything: it just wouldn't implement that header file at all, and 
   the next entry in the search-path would just find the generic 
   include/asm entry.

I dunno. It's not a huge deal, but it really would be nice to have all the 
arch/xyz code together for diffstat's etc.

		Linus
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Moving sound/* to drivers/ ?, Takashi Iwai, (Wed May 21, 5:20 pm)
Re: Moving sound/* to drivers/ ?, Jeff Garzik, (Wed May 21, 7:37 pm)
Re: Moving sound/* to drivers/ ?, Rene Herman, (Wed May 21, 7:53 pm)
Re: Moving sound/* to drivers/ ?, Takashi Iwai, (Thu May 22, 4:27 am)
Re: Moving sound/* to drivers/ ?, Adrian Bunk, (Thu May 22, 10:22 am)
Re: Moving sound/* to drivers/ ?, Rene Herman, (Thu May 22, 5:57 am)
Re: Moving sound/* to drivers/ ?, Jan Engelhardt, (Thu May 22, 4:55 am)
Re: Moving sound/* to drivers/ ?, Linus Torvalds, (Thu May 22, 11:04 am)
Re: Moving sound/* to drivers/ ?, Rene Herman, (Thu May 22, 12:40 pm)
Re: Moving sound/* to drivers/ ?, Jan Engelhardt, (Thu May 22, 11:50 am)
Re: Moving sound/* to drivers/ ?, Jaroslav Kysela, (Thu May 22, 2:26 am)
Re: Moving sound/* to drivers/ ?, Rene Herman, (Thu May 22, 4:11 am)
Re: Moving sound/* to drivers/ ?, Sam Ravnborg, (Thu May 22, 3:12 am)
Re: Moving sound/* to drivers/ ?, Jaroslav Kysela, (Thu May 22, 3:20 am)
Re: Moving sound/* to drivers/ ?, Adrian Bunk, (Wed May 21, 6:23 pm)
Re: Moving sound/* to drivers/ ?, Takashi Iwai, (Thu May 22, 4:22 am)
Re: [alsa-devel] Moving sound/* to drivers/ ?, Timur Tabi, (Wed May 21, 6:05 pm)
Re: Moving sound/* to drivers/ ?, Linus Torvalds, (Wed May 21, 5:44 pm)
Re: Moving include/asm-* [was: Re: Moving sound/* to drivers..., Linus Torvalds, (Wed May 21, 7:51 pm)
Re: Moving include/asm-*, David Miller, (Wed May 21, 9:25 pm)
Re: Moving include/asm-*, David Miller, (Wed May 21, 9:23 pm)
Re: Moving include/asm-*, Andreas Schwab, (Thu May 22, 4:09 am)
Re: Moving include/asm-*, David Miller, (Thu May 22, 12:12 pm)
Re: Moving include/asm-*, Andreas Schwab, (Thu May 22, 12:32 pm)
Re: Moving include/asm-*, David Miller, (Thu May 22, 1:43 pm)
Re: [alsa-devel] Moving sound/* to drivers/ ?, Rene Herman, (Wed May 21, 5:58 pm)
Re: [alsa-devel] Moving sound/* to drivers/ ?, Rene Herman, (Wed May 21, 6:08 pm)
Re: Moving sound/* to drivers/ ?, Sam Ravnborg, (Wed May 21, 5:54 pm)
speck-geostationary