netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Thomas Graf <tgraf@infradead.org>
To: Jan Engelhardt <jengelh@medozas.de>
Cc: Patrick McHardy <kaber@trash.net>,
	"David S. Miller" <davem@davemloft.net>,
	pablo@netfilter.org, netdev@vger.kernel.org
Subject: Re: Netlink limitations
Date: Tue, 9 Nov 2010 18:54:37 -0500	[thread overview]
Message-ID: <20101109235437.GE11005@canuck.infradead.org> (raw)
In-Reply-To: <alpine.LNX.2.01.1011100040220.7998@obet.zrqbmnf.qr>

On Wed, Nov 10, 2010 at 12:42:25AM +0100, Jan Engelhardt wrote:
> On Wednesday 2010-11-10 00:35, Thomas Graf wrote:
> >On Tue, Nov 09, 2010 at 11:02:30PM +0100, Jan Engelhardt wrote:
> >> And while we're discussing this, surely there are no objections
> >> to bumping NLA_ALIGN to 8 at the same time..
> >
> >We can't do that. That would break _everything_.
> 
> Using nlattr_ext also breaks _something_, unless it's only used for new 
> stuff. Similarly, a new NLA_EXT_ALIGN could be used with just those that 
> also start using nlattr_ext.

If you want to change alignment for new protocols that's fine but you won't
be able to use the existing attribute API on either side.

nlattr_ext2 or nlattr32 could be used in existing protocols if we used a special
attribute type (f.e. 0xffff) instead of nla_len == 0 to identify them and as long
as the attribute size does not exceed 64K as obviously no older parser would be
able to skip over such attributes correctly.

So yes, large attributes would only be permitted in new protocols which are
guaranteed to have a capable parser but we would at least not have to duplicate
the API but just slightly extend it.

  reply	other threads:[~2010-11-09 23:54 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-07 16:44 Netlink limitations Jan Engelhardt
2010-11-07 17:17 ` Patrick McHardy
2010-11-08 15:16   ` Thomas Graf
2010-11-08 19:21     ` Jan Engelhardt
2010-11-08 23:36       ` Pablo Neira Ayuso
2010-11-09  9:27     ` Patrick McHardy
2010-11-09 14:49       ` Thomas Graf
2010-11-09 20:20         ` Jan Engelhardt
2010-11-09 21:40           ` Thomas Graf
2010-11-09 22:02             ` Jan Engelhardt
2010-11-09 23:35               ` Thomas Graf
2010-11-09 23:42                 ` Jan Engelhardt
2010-11-09 23:54                   ` Thomas Graf [this message]
2010-11-09 11:58     ` Jan Engelhardt
2010-11-09 12:10   ` Jan Engelhardt
2010-11-09 12:24     ` Patrick McHardy

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=20101109235437.GE11005@canuck.infradead.org \
    --to=tgraf@infradead.org \
    --cc=davem@davemloft.net \
    --cc=jengelh@medozas.de \
    --cc=kaber@trash.net \
    --cc=netdev@vger.kernel.org \
    --cc=pablo@netfilter.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).