From: Paulius Zaleckas <paulius.zaleckas@gmail.com>
To: kaber@trash.net, netdev@vger.kernel.org
Subject: Re: [PATCH] vlan: Make it possible to add vlan with id 4095
Date: Fri, 28 Sep 2012 16:29:51 +0300 [thread overview]
Message-ID: <5065A64F.4080507@gmail.com> (raw)
In-Reply-To: <20120928123258.9454.95197.stgit@localhost.localdomain>
On 09/28/2012 03:32 PM, Paulius Zaleckas wrote:
> vconfig help tells that vlan_id should be 0-4095, but fails
> with 4095.
>
> There is an off-by-one bug while evaluating vlan_id.
> Fix it by evaluating against count(4096), not mask(0x0fff = 4095).
On the other hand 4095 is reserved by 802.1Q...
http://en.wikipedia.org/wiki/IEEE_802.1Q
VLAN Identifier (VID): a 12-bit field specifying the VLAN to which the
frame belongs. The hexadecimal values of 0x000 and 0xFFF are reserved.
All other values may be used as VLAN identifiers, allowing up to 4,094
VLANs. The reserved value 0x000 indicates that the frame does not belong
to any VLAN; in this case, the 802.1Q tag specifies only a priority and
is referred to as a priority tag.
So maybe we should fix vconfig help?
next prev parent reply other threads:[~2012-09-28 13:37 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-09-28 12:32 [PATCH] vlan: Make it possible to add vlan with id 4095 Paulius Zaleckas
2012-09-28 13:29 ` Paulius Zaleckas [this message]
2012-09-28 17:44 ` David Miller
2012-09-28 17:55 ` Eric Dumazet
2012-11-12 18:42 ` Jan Engelhardt
2012-11-12 19:01 ` Ben Greear
2012-11-12 20:37 ` Jan Engelhardt
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=5065A64F.4080507@gmail.com \
--to=paulius.zaleckas@gmail.com \
--cc=kaber@trash.net \
--cc=netdev@vger.kernel.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).