From: Arnd Bergmann <arnd@arndb.de>
To: Mark McLoughlin <markmc@redhat.com>
Cc: Avi Kivity <avi@redhat.com>, kvm@vger.kernel.org
Subject: Re: [PATCH] kvm: user: include arch specific headers from $(KERNELDIR)
Date: Wed, 13 May 2009 21:57:02 +0000 [thread overview]
Message-ID: <200905132157.02633.arnd@arndb.de> (raw)
In-Reply-To: <1242203541-12959-1-git-send-email-markmc@redhat.com>
On Wednesday 13 May 2009 08:32:21 Mark McLoughlin wrote:
> Currently we only include $(KERNELDIR)/include in CFLAGS,
> but we also have $(KERNELDIR)/arch/$(arch)/include or else
> we'll get mis-matched headers.
>
I think this is fundamentally wrong. User files should never directly
access kernel headers, because they are postprocessed in various
ways in order to get files that are valid in user space, e.g. __user
annotations are removed.
The three possible sources for kernel headers are:
/usr/include
- system provided headers, may be older than the running kernel
/lib/modules/$(uname -r)/build/usr/include
- user space headers for the currently running kernel
$(KERNELDIR)/usr/include
- user space headers from a configured kernel tree after 'make headers_install'
Arnd <><
next prev parent reply other threads:[~2009-05-13 21:57 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-05-13 8:32 [PATCH] kvm: user: include arch specific headers from $(KERNELDIR) Mark McLoughlin
2009-05-13 21:57 ` Arnd Bergmann [this message]
2009-05-14 7:52 ` Mark McLoughlin
2009-05-14 8:02 ` Avi Kivity
2009-05-14 15:49 ` Arnd Bergmann
2009-05-14 15:55 ` Avi Kivity
2009-05-14 16:07 ` Arnd Bergmann
2009-05-17 22:18 ` Avi Kivity
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=200905132157.02633.arnd@arndb.de \
--to=arnd@arndb.de \
--cc=avi@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=markmc@redhat.com \
/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