]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx4_core: Keep VLAN/MAC tables mirrored in multifunc HA mode
authorMoni Shoua <monis@mellanox.com>
Sun, 6 Dec 2015 16:07:41 +0000 (18:07 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 7 Dec 2015 03:40:45 +0000 (22:40 -0500)
commit6ae0b5d6aeaf91a006c1504b7022843c9117fde2
tree2a39c035a40b1064b45ec09453226182b956640e
parentb64d4ffbeed822f3c60fea94f6b5ec46b4cb5664
net/mlx4_core: Keep VLAN/MAC tables mirrored in multifunc HA mode

Due to HW limitations, indexes to MAC and VLAN tables are always taken
from the table of the actual port. So, if a resource holds an index to
a table, it may refer to different values during the lifetime of the
resource,  unless the tables are mirrored. Also, even when
driver is not in HA mode the policy of allocating an index to these
tables is such to make sure, as much as possible, that when the time
comes the mirroring will be successful. This means that in multifunction
mode the allocation of a free index in a port's table tries to make sure
that the same index in the other's port table is also free.

Signed-off-by: Moni Shoua <monis@mellanox.com>
Reviewed-by: Jack Morgenstein <jackm@dev.mellanox.co.il>
Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlx4/mlx4.h
drivers/net/ethernet/mellanox/mlx4/port.c
include/linux/mlx4/driver.h