linux/drivers/net/ethernet/intel/e1000e
David Ertman b3e5bf1ff3 e1000e: Failure to write SHRA turns on PROMISC mode
Previously, the check to turn on promiscuous mode only took into account
the total number of SHared Receive Address (SHRA) registers and if the
request was for a register within that range.  It is possible that the
Management Engine might have locked a number of SHRA and not allowed a
new address to be written to the requested register.

Add a function to determine the number of unlocked SHRA registers.  Then
determine if the number of registers available is sufficient for our needs,
if not then return -ENOMEM so that UNICAST PROMISC mode is activated.

Since the method by which ME claims SHRA registers is non-deterministic,
also add a return value to the function attempting to write an address
to a SHRA, and return a -E1000_ERR_CONFIG if the write fails.  The error
will be passed up the function chain and allow the driver to also set
UNICAST PROMISC when this happens.

Cc: Vlad Yasevich <vyasevic@redhat.com>
Signed-off-by: Dave Ertman <davidx.m.ertman@intel.com>
Tested-by: Aaron Brown <aaron.f.brown@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2014-05-26 23:53:11 -07:00
..
80003es2lan.c e1000e: Failure to write SHRA turns on PROMISC mode 2014-05-26 23:53:11 -07:00
80003es2lan.h e1000e: Cleanup - Update GPL header and Copyright 2014-03-07 21:55:27 -08:00
82571.c e1000e: Failure to write SHRA turns on PROMISC mode 2014-05-26 23:53:11 -07:00
82571.h e1000e: Cleanup - Update GPL header and Copyright 2014-03-07 21:55:27 -08:00
defines.h e1000e: Feature Enable PHY Ultra Low Power Mode (ULP) 2014-03-07 22:52:07 -08:00
e1000.h e1000e: Cleanup checkpatch extra space 2014-04-23 01:07:39 -07:00
ethtool.c net: get rid of SET_ETHTOOL_OPS 2014-05-13 17:43:20 -04:00
hw.h e1000e: Failure to write SHRA turns on PROMISC mode 2014-05-26 23:53:11 -07:00
ich8lan.c e1000e: Failure to write SHRA turns on PROMISC mode 2014-05-26 23:53:11 -07:00
ich8lan.h e1000e: Fix issue with link flap on 82579 2014-05-05 13:02:57 -07:00
mac.c e1000e: Failure to write SHRA turns on PROMISC mode 2014-05-26 23:53:11 -07:00
mac.h e1000e: Failure to write SHRA turns on PROMISC mode 2014-05-26 23:53:11 -07:00
Makefile e1000e: Cleanup - Update GPL header and Copyright 2014-03-07 21:55:27 -08:00
manage.c e1000e: Cleanup - Update GPL header and Copyright 2014-03-07 21:55:27 -08:00
manage.h e1000e: Cleanup - Update GPL header and Copyright 2014-03-07 21:55:27 -08:00
netdev.c e1000e: Failure to write SHRA turns on PROMISC mode 2014-05-26 23:53:11 -07:00
nvm.c e1000e: Cleanup to fix checkpatch missing blank lines 2014-04-23 01:05:08 -07:00
nvm.h e1000e: Cleanup - Update GPL header and Copyright 2014-03-07 21:55:27 -08:00
param.c e1000e: Cleanup to fix checkpatch missing blank lines 2014-04-23 01:05:08 -07:00
phy.c e1000e: Cleanup to fix checkpatch missing blank lines 2014-04-23 01:05:08 -07:00
phy.h e1000e: Workaround for dropped packets in Gig/100 speeds on 82579 2014-05-05 12:54:33 -07:00
ptp.c ptp: drivers: set the number of programmable pins. 2014-03-21 14:21:14 -04:00
regs.h e1000e: Feature Enable PHY Ultra Low Power Mode (ULP) 2014-03-07 22:52:07 -08:00