From: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
To: davem@davemloft.net
Cc: Greg Rose <gregory.v.rose@intel.com>,
netdev@vger.kernel.org, gospo@redhat.com, sassmann@redhat.com,
Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Subject: [net-next 7/8] ixgbe: Deny MACVLAN requests from VFs with admin set MAC
Date: Tue, 1 May 2012 01:51:08 -0700 [thread overview]
Message-ID: <1335862269-28914-8-git-send-email-jeffrey.t.kirsher@intel.com> (raw)
In-Reply-To: <1335862269-28914-1-git-send-email-jeffrey.t.kirsher@intel.com>
From: Greg Rose <gregory.v.rose@intel.com>
If the host VMM administrator has set the virtual function device's
MAC address then also deny VF requests for MACVLAN filters.
Signed-off-by: Greg Rose <gregory.v.rose@intel.com>
Tested-by: Garrett, Robert <robertx.e.garrett@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
---
drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c
index 88a58cb..3985637 100644
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c
@@ -635,6 +635,12 @@ static int ixgbe_rcv_msg_from_vf(struct ixgbe_adapter *adapter, u32 vf)
}
break;
case IXGBE_VF_SET_MACVLAN:
+ if (adapter->vfinfo[vf].pf_set_mac) {
+ e_warn(drv, "VF %d requested MACVLAN filter but is "
+ "administratively denied\n", vf);
+ retval = -1;
+ break;
+ }
index = (msgbuf[0] & IXGBE_VT_MSGINFO_MASK) >>
IXGBE_VT_MSGINFO_SHIFT;
/*
--
1.7.7.6
next prev parent reply other threads:[~2012-05-01 8:51 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-01 8:51 [net-next 0/8][pull request] Intel Wired LAN Driver Updates Jeff Kirsher
2012-05-01 8:51 ` [net-next 1/8] e1000e: workaround EEPROM configuration change on 82579 Jeff Kirsher
2012-05-01 8:51 ` [net-next 2/8] e1000e: PHY initialization flow changes for 82577/8/9 Jeff Kirsher
2012-05-01 8:51 ` [net-next 3/8] e1000e: fix .ndo_set_rx_mode for 82579 Jeff Kirsher
2012-05-01 8:51 ` [net-next v2 4/8] ixgbe: add support functions to access thermal data Jeff Kirsher
2012-05-01 8:51 ` [net-next v2 5/8] ixgbe: add hwmon interface to export " Jeff Kirsher
2012-05-01 8:51 ` [net-next v2 6/8] ixgbe: add syfs interface for to export read only driver information Jeff Kirsher
2012-05-01 14:02 ` David Miller
2012-05-01 14:30 ` Ben Greear
2012-05-02 8:41 ` Jeff Kirsher
2012-05-02 8:51 ` David Miller
2012-05-01 8:51 ` Jeff Kirsher [this message]
2012-05-01 8:51 ` [net-next 8/8] ixgbe: Reset max_vfs to zero when user request is out of range Jeff Kirsher
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1335862269-28914-8-git-send-email-jeffrey.t.kirsher@intel.com \
--to=jeffrey.t.kirsher@intel.com \
--cc=davem@davemloft.net \
--cc=gospo@redhat.com \
--cc=gregory.v.rose@intel.com \
--cc=netdev@vger.kernel.org \
--cc=sassmann@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).