diff options
author | Somnath Kotur <somnath.kotur@emulex.com> | 2011-10-27 09:14:05 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2011-10-28 05:16:20 +0200 |
commit | e3a7ae2c1819aa210a38f80f6bf13322652c8211 (patch) | |
tree | 75cbeb4866aee1e1d8c75148200795a17c1f657a /drivers/net/ethernet/emulex/benet/be_cmds.c | |
parent | be2net: Refactored be_cmds.c file. (diff) | |
download | linux-e3a7ae2c1819aa210a38f80f6bf13322652c8211.tar.xz linux-e3a7ae2c1819aa210a38f80f6bf13322652c8211.zip |
be2net: Changing MAC Address of a VF was broken.
Allow for MAC Address change of VF(SR-IOV case) on the fly- First add and then
delete MAC Address to allow for 'out of pool' errors.
When MAC Addr configured from a VM, the MAC on the NIC will aleady have
the supplied MAC,so just copy the supplied MAC to the netdev structure
before returning success to the stack
Signed-off-by: Somnath Kotur <somnath.kotur@emulex.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/emulex/benet/be_cmds.c')
-rw-r--r-- | drivers/net/ethernet/emulex/benet/be_cmds.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/ethernet/emulex/benet/be_cmds.c b/drivers/net/ethernet/emulex/benet/be_cmds.c index 83b8a46cdf41..824b8e6021f6 100644 --- a/drivers/net/ethernet/emulex/benet/be_cmds.c +++ b/drivers/net/ethernet/emulex/benet/be_cmds.c @@ -688,6 +688,10 @@ int be_cmd_pmac_add(struct be_adapter *adapter, u8 *mac_addr, err: spin_unlock_bh(&adapter->mcc_lock); + + if (status == MCC_STATUS_UNAUTHORIZED_REQUEST) + status = -EPERM; + return status; } |