]> git.baikalelectronics.ru Git - kernel.git/commit
ixgbe: fix RAR entry counting for generic and fdb_add()
authorJohn Fastabend <john.r.fastabend@intel.com>
Thu, 31 May 2012 12:42:26 +0000 (12:42 +0000)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Sat, 21 Jul 2012 23:05:59 +0000 (16:05 -0700)
commit62806c211db1437223153fa52af8a2a9b6e8e160
tree66288cc983efed26cf494915470dda8c80dbb6df
parenta1978e8205ea7cc2566b6d45ab18abb9fd4f6857
ixgbe: fix RAR entry counting for generic and fdb_add()

Do RAR entry accounting correctly so that errors are reported and
promisc mode is set correctly when the number of entries exceeds
the hardware limits.

This can happen with many macvlan devices attached to the PF or
by adding many fdb entries in SR-IOV modes.

Also this includes a small refactor to fdb_add() to avoid having so
many nested if/else statements after adding a check for the number
or RAR entries.

The max entries for the PF is currently 16 we allow 15 additional
entries to account for the defined MAC.

Signed-off-by: John Fastabend <john.r.fastabend@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Tested-by: Ross Brattain <ross.b.brattain@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/ixgbe/ixgbe_main.c