From: David Miller <davem@davemloft.net>
To: jengelh@medozas.de
Cc: sam@ravnborg.org, andrew@walrond.org,
linux-kernel@vger.kernel.org, netdev@vger.kernel.org
Subject: Re: 2.6.28 headers break kbd and net-tools userspace builds
Date: Wed, 28 Jan 2009 12:29:24 -0800 (PST) [thread overview]
Message-ID: <20090128.122924.106238702.davem@davemloft.net> (raw)
In-Reply-To: <alpine.LSU.2.00.0901271143490.3147@fbirervta.pbzchgretzou.qr>
From: Jan Engelhardt <jengelh@medozas.de>
Date: Tue, 27 Jan 2009 11:44:51 +0100 (CET)
>
> On Tuesday 2009-01-27 06:08, David Miller wrote:
> >The fly in the ointment is linux/if_tunnel.h
> >
> >We export a structure there for a userland interface which
> >uses "struct iphdr".
> >
> >Because of that, we are faced with the difficult choice between
> >defining the structure (as we do) in linux/ip.h or using some ugly
> >__KERNEL__ ifdefs in linux/if_tunnel.h to conditionally include
> >netinet/ip.h instead. :-/
> >
> >Really, I have no idea what to do about this as the problem has
> >existed for so long.
>
> I think in the long term, exported structs should probably
> have a "kernel_" prefix, much like userspace libraries use
> such prefixes to (try to) guard against simple name clashes.
This is a reasonable rule for future interfaces, but won't
help us here on this one.
For one thing, users can be making use of the inner types
to build the blobs they send via these interfaces. So it's
not like we can rename "struct iphdr" to "struct kernel_iphdr"
to fix this particular case.
Really, we page a huge price these days because the relationship
between glibc's and the kernel's userland header exports in the
past has been anti-social at best.
next prev parent reply other threads:[~2009-01-28 20:29 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <49786A59.6040706@walrond.org>
[not found] ` <20090122175645.GA14178@uranus.ravnborg.org>
[not found] ` <4978C301.1040705@walrond.org>
2009-01-22 19:12 ` 2.6.28 headers break kbd and net-tools userspace builds Sam Ravnborg
2009-01-27 5:08 ` David Miller
2009-01-27 10:44 ` Jan Engelhardt
2009-01-28 20:29 ` David Miller [this message]
2009-01-30 4:12 ` Jan Engelhardt
2009-02-02 10:35 ` Andrew Walrond
2009-02-02 20:05 ` David Miller
2009-02-02 21:13 ` Andrew Walrond
2009-02-02 21:24 ` David Miller
2009-02-02 21:27 ` David Miller
2009-02-03 4:58 ` Sam Ravnborg
2009-02-03 5:26 ` David Miller
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=20090128.122924.106238702.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=andrew@walrond.org \
--cc=jengelh@medozas.de \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--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;
as well as URLs for NNTP newsgroup(s).