netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Mike Frysinger <vapier.adi@gmail.com>
To: Lennert Buytenhek <buytenh@wantstofly.org>
Cc: Karl Beldan <karl.beldan@gmail.com>,
	netdev@vger.kernel.org, Graf Yang <graf.yang@analog.com>,
	uclinux-dist-devel@blackfin.uclinux.org,
	"David S. Miller" <davem@davemloft.net>
Subject: Re: [Uclinux-dist-devel] [PATCH 1/2] net: dsa: introduce STPID switch tagging handling code
Date: Wed, 21 Jul 2010 11:29:30 -0400	[thread overview]
Message-ID: <AANLkTim1gbnH99GC_dVL8uevRgCRsn7dvAJ_rX-2Xgon@mail.gmail.com> (raw)
In-Reply-To: <20100721150251.GL21121@mail.wantstofly.org>

On Wed, Jul 21, 2010 at 11:02, Lennert Buytenhek wrote:
> On Wed, Jul 21, 2010 at 09:37:21AM -0400, Mike Frysinger wrote:
>> +     source_port = dsa_header[1] & 0x03;
>> +     if (source_port >= DSA_MAX_PORTS || ds->ports[source_port] == NULL)
>> +             goto out_drop;
>> +
>> +     if (((dsa_header[0] & ETH_P_8021QH) == ETH_P_8021QH) &&
>
> This is bogus -- what it does is:
>
>        if ((dsa_header[0] & 0x81) == 0x81)
>
> It doesn't look like you need to mask here at all.

where does it say dsa_header[0] will always have 0x81 set ?
-mike

  reply	other threads:[~2010-07-21 15:29 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-21 13:37 [PATCH 1/2] net: dsa: introduce STPID switch tagging handling code Mike Frysinger
2010-07-21 13:37 ` [PATCH 2/2] net: dsa: introduce MICREL KSZ8893MQL/BL ethernet switch chip support Mike Frysinger
2010-07-21 15:16   ` Lennert Buytenhek
2010-07-21 15:33     ` Eric Dumazet
2010-07-21 15:36       ` Lennert Buytenhek
2010-07-21 16:40       ` Joe Perches
2010-07-21 16:05     ` [Uclinux-dist-devel] " Mike Frysinger
2010-07-21 20:31       ` Karl Beldan
2010-07-21 21:00         ` Mike Frysinger
2010-07-22 19:27           ` Karl Beldan
     [not found]     ` <20100721151608.GM21121-SHk0+jKqY/D5VnbZ9m/NDkB+6BGkLq7r@public.gmane.org>
2010-07-21 17:23       ` David Miller
2010-07-21 16:29   ` [PATCH 2/2 v2] " Mike Frysinger
2010-07-21 20:45     ` Karl Beldan
2010-07-21 15:02 ` [PATCH 1/2] net: dsa: introduce STPID switch tagging handling code Lennert Buytenhek
2010-07-21 15:29   ` Mike Frysinger [this message]
2010-07-21 15:35     ` [Uclinux-dist-devel] " Lennert Buytenhek
2010-07-21 16:08       ` Mike Frysinger
2010-07-29 17:50         ` Mike Frysinger
2010-08-10 14:05           ` Lennert Buytenhek
2010-08-10 17:04             ` Mike Frysinger
2010-08-12 22:38               ` Mike Frysinger

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=AANLkTim1gbnH99GC_dVL8uevRgCRsn7dvAJ_rX-2Xgon@mail.gmail.com \
    --to=vapier.adi@gmail.com \
    --cc=buytenh@wantstofly.org \
    --cc=davem@davemloft.net \
    --cc=graf.yang@analog.com \
    --cc=karl.beldan@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=uclinux-dist-devel@blackfin.uclinux.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).