mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-21 16:29:59 +00:00
mv643xx_eth: fix unicast address filter corruption on mtu change
When mv643xx_eth_open() is called to up an interface, port_start() will first re-program the unicast address filter, and then re-initialise the PORT_CONFIG register, but that will disable unicast promiscuous mode if it was enabled by the unicast address filter setup. This isn't a problem on ifconfig up, as ->set_rx_mode() will be called shortly afterwards which will program the filters again, but it does trigger when changing the MTU, which calls mv643xx_eth_stop() and then mv643xx_eth_open() by hand to repopulate the receive rings with skbuffs of the new size. Swap the initialisation of the PORT_START register and the call to the unicast filter setup function to fix this. Signed-off-by: Lennert Buytenhek <buytenh@marvell.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
08ec9af1c0
commit
5a89392225
1 changed files with 5 additions and 5 deletions
|
@ -2029,11 +2029,6 @@ static void port_start(struct mv643xx_eth_private *mp)
|
|||
txq_set_fixed_prio_mode(txq);
|
||||
}
|
||||
|
||||
/*
|
||||
* Add configured unicast address to address filter table.
|
||||
*/
|
||||
mv643xx_eth_program_unicast_filter(mp->dev);
|
||||
|
||||
/*
|
||||
* Receive all unmatched unicast, TCP, UDP, BPDU and broadcast
|
||||
* frames to RX queue #0, and include the pseudo-header when
|
||||
|
@ -2046,6 +2041,11 @@ static void port_start(struct mv643xx_eth_private *mp)
|
|||
*/
|
||||
wrlp(mp, PORT_CONFIG_EXT, 0x00000000);
|
||||
|
||||
/*
|
||||
* Add configured unicast addresses to address filter table.
|
||||
*/
|
||||
mv643xx_eth_program_unicast_filter(mp->dev);
|
||||
|
||||
/*
|
||||
* Enable the receive queues.
|
||||
*/
|
||||
|
|
Loading…
Reference in a new issue