Netdev List
 help / color / mirror / Atom feed
From: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
To: davem@davemloft.net
Cc: Jacob Keller <jacob.e.keller@intel.com>,
	netdev@vger.kernel.org, nhorman@redhat.com, sassmann@redhat.com,
	Andrew Bowers <andrewx.bowers@intel.com>,
	Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Subject: [net-next 06/14] ice: reject VF attempts to enable head writeback
Date: Fri, 23 Aug 2019 16:37:42 -0700	[thread overview]
Message-ID: <20190823233750.7997-7-jeffrey.t.kirsher@intel.com> (raw)
In-Reply-To: <20190823233750.7997-1-jeffrey.t.kirsher@intel.com>

From: Jacob Keller <jacob.e.keller@intel.com>

The virtchnl interface provides a mechanism for a VF driver to request
head writeback support. This feature is deprecated as of AVF 1.0, but
older versions of a VF driver may still attempt to request the mode.

Since the ice hardware does not support head writeback, we should not
accept Tx queue configuration which attempts to enable it.

Currently, the driver simply assumes that the headwb_enabled bit will
never be set.

If a VF driver does request head writeback, the configuration will
return successfully, even though head writeback is not enabled. This
leaves the VF driver in a non functional state since it is assuming to
be operating in head writeback mode.

Fix the PF driver to reject any attempt to setup headwb_enabled.

Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
---
 drivers/net/ethernet/intel/ice/ice_virtchnl_pf.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/ethernet/intel/ice/ice_virtchnl_pf.c b/drivers/net/ethernet/intel/ice/ice_virtchnl_pf.c
index 1b1d1ea0c8f9..73ab6222d29b 100644
--- a/drivers/net/ethernet/intel/ice/ice_virtchnl_pf.c
+++ b/drivers/net/ethernet/intel/ice/ice_virtchnl_pf.c
@@ -2109,6 +2109,7 @@ static int ice_vc_cfg_qs_msg(struct ice_vf *vf, u8 *msg)
 		if (qpi->txq.vsi_id != qci->vsi_id ||
 		    qpi->rxq.vsi_id != qci->vsi_id ||
 		    qpi->rxq.queue_id != qpi->txq.queue_id ||
+		    qpi->txq.headwb_enabled ||
 		    !ice_vc_isvalid_q_id(vf, qci->vsi_id, qpi->txq.queue_id)) {
 			v_ret = VIRTCHNL_STATUS_ERR_PARAM;
 			goto error_param;
-- 
2.21.0


  parent reply	other threads:[~2019-08-23 23:38 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-23 23:37 [net-next 00/14][pull request] 100GbE Intel Wired LAN Driver Updates 2019-08-23 Jeff Kirsher
2019-08-23 23:37 ` [net-next 01/14] ice: Allow egress control packets from PF_VSI Jeff Kirsher
2019-08-23 23:37 ` [net-next 02/14] ice: Account for all states of FW DCBx and LLDP Jeff Kirsher
2019-08-23 23:37 ` [net-next 03/14] ice: Don't call synchronize_irq() for VF's from the host Jeff Kirsher
2019-08-23 23:37 ` [net-next 04/14] ice: Treat DCBx state NOT_STARTED as valid Jeff Kirsher
2019-08-23 23:37 ` [net-next 05/14] ice: Copy dcbx configuration only if mode is correct Jeff Kirsher
2019-08-23 23:37 ` Jeff Kirsher [this message]
2019-08-23 23:37 ` [net-next 07/14] ice: Rename ethtool private flag for lldp Jeff Kirsher
2019-08-24  1:31   ` Jakub Kicinski
2019-08-24 23:47     ` David Miller
2019-08-25  0:04       ` Kirsher, Jeffrey T
2019-08-23 23:37 ` [net-next 08/14] ice: silence some bogus error messages Jeff Kirsher
2019-08-23 23:37 ` [net-next 09/14] ice: Fix flag used for module query Jeff Kirsher
2019-08-23 23:37 ` [net-next 10/14] ice: Don't clear auto_fec bit in ice_cfg_phy_fec() Jeff Kirsher
2019-08-23 23:37 ` [net-next 11/14] ice: Add input handlers for virtual channel handlers Jeff Kirsher
2019-08-23 23:37 ` [net-next 12/14] ice: update ethtool stats on-demand Jeff Kirsher
2019-08-23 23:37 ` [net-next 13/14] ice: Fix issues updating VSI MAC filters Jeff Kirsher
2019-08-23 23:37 ` [net-next 14/14] ice: Don't allow VSI to remove unassociated ucast filter Jeff Kirsher
2019-08-24 23:47 ` [net-next 00/14][pull request] 100GbE Intel Wired LAN Driver Updates 2019-08-23 David Miller

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=20190823233750.7997-7-jeffrey.t.kirsher@intel.com \
    --to=jeffrey.t.kirsher@intel.com \
    --cc=andrewx.bowers@intel.com \
    --cc=davem@davemloft.net \
    --cc=jacob.e.keller@intel.com \
    --cc=netdev@vger.kernel.org \
    --cc=nhorman@redhat.com \
    --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