From: Guenter Roeck <linux@roeck-us.net>
To: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Cc: netdev@vger.kernel.org, "David S. Miller" <davem@davemloft.net>,
linux-kernel@vger.kernel.org, kernel@savoirfairelinux.com
Subject: Re: [PATCH] net: dsa: mv88e6xxx: fix fid_mask when leaving bridge
Date: Wed, 15 Jul 2015 07:23:22 -0700 [thread overview]
Message-ID: <20150715142322.GA32367@roeck-us.net> (raw)
In-Reply-To: <1436969227-30006-1-git-send-email-vivien.didelot@savoirfairelinux.com>
On Wed, Jul 15, 2015 at 10:07:07AM -0400, Vivien Didelot wrote:
> The mv88e6xxx_priv_state structure contains an fid_mask, where 1 means
> the FID is free to use, 0 means the FID is in use.
>
> This patch fixes the bit clear in mv88e6xxx_leave_bridge() when
> assigning a new FID to a port.
>
> Example scenario: I have 7 ports, port 5 is CPU, port 6 is unused (no
> PHY). After setting the ports 0, 1 and 2 in bridge br0, and ports 3 and
> 4 in bridge br1, I have the following fid_mask: 0b111110010110 (0xf96).
>
> Indeed, br0 uses FID 0, and br1 uses FID 3.
>
> After setting nomaster for port 0, I get the wrong fid_mask: 0b10 (0x2).
>
> With this patch we correctly get 0b111110010100 (0xf94), meaning port 0
> uses FID 1, br0 uses FID 0, and br1 uses FID 3.
>
> Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
next prev parent reply other threads:[~2015-07-15 14:23 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-15 14:07 [PATCH] net: dsa: mv88e6xxx: fix fid_mask when leaving bridge Vivien Didelot
2015-07-15 14:23 ` Guenter Roeck [this message]
2015-07-20 19:44 ` 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=20150715142322.GA32367@roeck-us.net \
--to=linux@roeck-us.net \
--cc=davem@davemloft.net \
--cc=kernel@savoirfairelinux.com \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=vivien.didelot@savoirfairelinux.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;
as well as URLs for NNTP newsgroup(s).