aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/emulex/benet/be_cmds.c
diff options
context:
space:
mode:
authorSomnath Kotur <somnath.kotur@emulex.com>2011-10-27 03:14:05 -0400
committerDavid S. Miller <davem@davemloft.net>2011-10-27 23:16:20 -0400
commite3a7ae2c1819aa210a38f80f6bf13322652c8211 (patch)
tree75cbeb4866aee1e1d8c75148200795a17c1f657a /drivers/net/ethernet/emulex/benet/be_cmds.c
parent106df1e3594c710c74348883a4942f65651781ff (diff)
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.c4
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,
688 688
689err: 689err:
690 spin_unlock_bh(&adapter->mcc_lock); 690 spin_unlock_bh(&adapter->mcc_lock);
691
692 if (status == MCC_STATUS_UNAUTHORIZED_REQUEST)
693 status = -EPERM;
694
691 return status; 695 return status;
692} 696}
693 697