mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Kyle Moffett <mrmacman_g4@mac.com>
To: Sam Ravnborg <sam@ravnborg.org>
Cc: linux-kernel@vger.kernel.org, nix@esperi.org.uk, rob@landley.net,
	mmazur@kernel.pl, llh-discuss@lists.pld-linux.org
Subject: Re: [RFC][PATCH 1/2] Create initial kernel ABI header infrastructure
Date: Sun, 26 Mar 2006 15:39:32 -0500	[thread overview]
Message-ID: <1DF54B48-4541-4BA9-A71C-A64CE98B4964@mac.com> (raw)
In-Reply-To: <20060326200537.GA5012@mars.ravnborg.org>

On Mar 26, 2006, at 15:05:37, Sam Ravnborg wrote:
> On Sun, Mar 26, 2006 at 06:54:16AM -0500, Kyle Moffett wrote:
>> Create initial kernel ABI header infrastructure
>>
>> diff --git a/Makefile b/Makefile
>> index af6210d..8e9045a 100644
>> --- a/Makefile
>> +++ b/Makefile
>> @@ -787,13 +787,15 @@ ifneq ($(KBUILD_SRC),)
>>  		/bin/false; \
>>  	fi;
>>  	$(Q)if [ ! -d include2 ]; then mkdir -p include2; fi;
>> +	$(Q)if [ ! -d include2/kabi ]; then mkdir -p include2/kabi; fi;
>>  	$(Q)ln -fsn $(srctree)/include/asm-$(ARCH) include2/asm
>> +	$(Q)ln -fsn $(srctree)/include/kabi/arch-$(ARCH) include2/kabi/arch
>
> No - we do not want another symlink.
> Create something like:
> include/i386/kabi-asm/  <= i386 specific files
> include/kabi/           <= general files
>
> Then we can do:
> LINUXINCLUDE += -Iinclude/kabi-$(ARCH)
> And the following would work like expected:
> #include <kabi/foo.h>
> #include <kabi-asm/foo.h>

Hmm, I see where you're going with this.  Thanks for the tip!

> But this leaves all existing users in the dark cold.  So a more  
> involved approach could be to take the opposite approach. To  
> dedicate an area for kernel only header files and make sure this  
> directory is searched _before_ include/

I'm not entirely sure I understand this bit.  The idea behind this  
kabi stuff is precisely to split out portions of the headers so that  
both userspace and kernelspace can get at them; to designate specific  
items as "userspace clean" by putting them in kabi; everything else  
need not care at all, and all those headers would remain in include/ 
linux where they are now.  No sense moving _everything_ in include/  
around, we just want the parts that userspace needs too.

> And we have so many users of include/linux today. They do not need  
> a _kabi_ prefix so let it go.

_Exactly_ the point.  I'd like to leave 99% of the kernel code  
alone.  Userspace doesn't work with the headers in the stock kernel  
as-is, so I see no problem with working to provide a clean source ABI  
even if it's partially incompatible with the old source ABI.  The  
binary ABI would stay the same, though, and I'd try to fix the old  
source ABI where possible.

I think I'll try something like your original proposal:
include/kabi/			<= Userspace-clean generic ABI includes
include/$(ARCH)/		<= New arch-specific include directory
include/$(ARCH)/kabi-arch/	<= Arch-specific ABI includes

Then the following Makefile snippet:
LINUXINCLUDE += -Iinclude/$(ARCH)

And then in the header file:
#include <kabi-arch/stddef.h>
#include <kabi/types.h>

It would also be possible to move files from include/asm-$(ARCH) to  
include/$(ARCH)/asm if desired, but that's a little offtopic for the  
kernel-ABI headers project I'm working on right now.

Thanks for the advice!
Kyle Moffett


  reply	other threads:[~2006-03-26 20:39 UTC|newest]

Thread overview: 102+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-03-14 15:19 [ANNOUNCE] linux-libc-headers dead Mariusz Mazur
2006-03-14 15:28 ` Ismail Donmez
2006-03-16  8:37 ` [llh-announce] " Nigel Kukard
2006-03-16 20:20   ` Jan Engelhardt
2006-03-16 20:42     ` Dan Kegel
2006-03-17  7:56 ` DervishD
2006-03-23 17:11 ` State of userland headers Mariusz Mazur
2006-03-23 23:04   ` Rob Landley
2006-03-26 13:12     ` Mariusz Mazur
2006-03-26 20:59       ` Rob Landley
2006-03-24 18:51   ` Kyle Moffett
2006-03-24 21:23     ` Rob Landley
     [not found]       ` <878xqzpl8g.fsf@hades.wkstn.nix>
2006-03-24 22:46         ` Kyle Moffett
2006-03-24 23:01           ` Randy.Dunlap
2006-03-25  6:48             ` Kyle Moffett
2006-03-28 20:17               ` Jim Gifford
2006-03-25  1:36           ` Jeff Dike
2006-03-25  6:33             ` Kyle Moffett
2006-03-25 16:03               ` Jeff Dike
2006-03-25  3:19           ` Rob Landley
2006-03-25  6:27             ` Kyle Moffett
2006-03-26 11:52           ` [RFC][PATCH 0/2] KABI example conversion and cleanup Kyle Moffett
2006-03-26 11:54             ` [RFC][PATCH 1/2] Create initial kernel ABI header infrastructure Kyle Moffett
2006-03-26 12:32               ` Arjan van de Ven
2006-03-26 12:50                 ` Kyle Moffett
2006-03-26 12:59                   ` Martin Mares
2006-03-26 13:14                     ` Kyle Moffett
2006-03-26 15:38                       ` Martin Mares
2006-03-26 16:16                         ` Kyle Moffett
2006-03-26 14:39                   ` Arjan van de Ven
2006-03-26 15:23                     ` Kyle Moffett
2006-03-29 22:26                   ` Pavel Machek
2006-04-02  0:22                     ` Randy.Dunlap
2006-04-02  2:42                       ` Kyle Moffett
2006-04-02  3:01                         ` Arjan van de Ven
2006-04-02  5:53                           ` Kyle Moffett
2006-04-02 13:09                             ` Arjan van de Ven
2006-04-02 10:32                         ` Pavel Machek
2006-04-02 11:16                           ` Kyle Moffett
2006-03-26 20:05               ` Sam Ravnborg
2006-03-26 20:39                 ` Kyle Moffett [this message]
2006-03-26 21:26                   ` Sam Ravnborg
2006-03-27  0:27                     ` Kyle Moffett
2006-03-26 11:55             ` [RFC][PATCH 2/2] Generalize fd_set handling across architectures Kyle Moffett
2006-03-26 12:06             ` [RFC][PATCH 0/2] KABI example conversion and cleanup Kyle Moffett
2006-03-26 13:43               ` Nix
2006-03-26 12:26             ` Arjan van de Ven
2006-03-26 12:30               ` Arjan van de Ven
2006-03-26 12:34               ` Kyle Moffett
2006-03-26 13:22                 ` Giuseppe Bilotta
2006-03-26 13:29                 ` Avi Kivity
2006-03-26 13:47                   ` Kyle Moffett
2006-03-26 13:53                     ` Giuseppe Bilotta
2006-03-26 14:30                       ` Kyle Moffett
2006-03-26 14:45                         ` Giuseppe Bilotta
2006-03-26 17:24                     ` Avi Kivity
2006-03-26 17:29                       ` Arjan van de Ven
2006-03-26 17:57                         ` Avi Kivity
2006-03-26 18:32                           ` Arjan van de Ven
2006-03-26 21:18                           ` Rob Landley
2006-03-27  0:18                             ` Kyle Moffett
2006-03-27  6:19                             ` Avi Kivity
2006-03-27 19:48                               ` Rob Landley
2006-03-28 20:04                                 ` Mariusz Mazur
2006-03-28 20:13                                   ` Kyle Moffett
2006-03-28 22:57                                   ` Rob Landley
2006-03-26 20:55                 ` Rob Landley
2006-03-27  0:12                   ` Kyle Moffett
2006-03-26 14:31             ` Eric Piel
2006-03-26 21:09               ` Rob Landley
2006-03-26 23:06                 ` Eric Piel
2006-03-27  0:40                   ` Kyle Moffett
2006-03-27  3:12                     ` Jeff Dike
2006-03-28 14:20                     ` Jan Engelhardt
2006-03-28 15:57                       ` [OT] Non-GCC compilers used for linux userspace Kyle Moffett
2006-03-28 16:13                         ` Eric Piel
2006-03-28 16:20                           ` Kyle Moffett
2006-03-28 16:59                             ` Jason L Tibbitts III
2006-03-28 17:13                               ` Kyle Moffett
2006-03-28 17:28                                 ` Daniel Jacobowitz
2006-03-28 17:41                                   ` Kyle Moffett
2006-04-05 17:01                                 ` Bryan O'Sullivan
2006-03-28 17:08                             ` Jan-Benedict Glaw
2006-03-28 17:56                             ` Jesper Juhl
2006-03-28 21:47                             ` Rob Landley
2006-03-29 21:23                               ` Nix
2006-03-30  1:36                                 ` Rob Landley
2006-03-30  7:24                                   ` Nix
2006-03-30 20:26                                     ` Rob Landley
2006-03-30 22:02                                       ` Nix
2006-03-30 23:00                                         ` Harald Arnesen
2006-03-30 23:16                                         ` Rob Landley
2006-03-29 13:25                             ` Mathieu Chouquet-Stringer
2006-03-28 18:44                           ` Eric W. Biederman
2006-03-29  4:26                         ` Peter Chubb
2006-03-30 15:15                         ` Roger Heflin
2006-03-28 17:16                       ` [RFC][PATCH 0/2] KABI example conversion and cleanup Ben Pfaff
2006-03-28 17:08                     ` Catalin Marinas
2006-03-31  0:20             ` Arch-specific header inconsistency (asm-*/termios.h) Kyle Moffett
2006-04-02 17:58             ` [RFC][PATCH 0/2] KABI example conversion and cleanup Sam Ravnborg
2006-04-02 19:30               ` Kyle Moffett
2006-04-02 20:47                 ` Arnd Bergmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1DF54B48-4541-4BA9-A71C-A64CE98B4964@mac.com \
    --to=mrmacman_g4@mac.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=llh-discuss@lists.pld-linux.org \
    --cc=mmazur@kernel.pl \
    --cc=nix@esperi.org.uk \
    --cc=rob@landley.net \
    --cc=sam@ravnborg.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®