summaryrefslogtreecommitdiffstats
path: root/drivers/net/bonding/bond_main.c
diff options
context:
space:
mode:
authorVivien Didelot2015-07-15 16:07:07 +0200
committerDavid S. Miller2015-07-20 21:44:14 +0200
commit40a7166044a6fce3dbcaa8b5c89845980c218c98 (patch)
treec381031781bfd5ca31bf27ba68296f422dc77f4f /drivers/net/bonding/bond_main.c
parentvirtio_net: don't require ANY_LAYOUT with VERSION_1 (diff)
downloadkernel-qcow2-linux-40a7166044a6fce3dbcaa8b5c89845980c218c98.tar.gz
kernel-qcow2-linux-40a7166044a6fce3dbcaa8b5c89845980c218c98.tar.xz
kernel-qcow2-linux-40a7166044a6fce3dbcaa8b5c89845980c218c98.zip
net: dsa: mv88e6xxx: fix fid_mask when leaving bridge
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> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/bonding/bond_main.c')
0 files changed, 0 insertions, 0 deletions