All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
To: davem@davemloft.net
Cc: Dan Nowlin <dan.nowlin@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 04/14] ice: Increase timeout after PFR
Date: Sun, 31 May 2020 05:36:09 -0700	[thread overview]
Message-ID: <20200531123619.2887469-5-jeffrey.t.kirsher@intel.com> (raw)
In-Reply-To: <20200531123619.2887469-1-jeffrey.t.kirsher@intel.com>

From: Dan Nowlin <dan.nowlin@intel.com>

To allow for resets during package download, increase the timeout period
after performing a PFR. The time waited is the global config lock
timeout plus the normal PFSWR timeout.

Signed-off-by: Dan Nowlin <dan.nowlin@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_common.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/intel/ice/ice_common.c b/drivers/net/ethernet/intel/ice/ice_common.c
index 8c73e161829d..d4a31c734326 100644
--- a/drivers/net/ethernet/intel/ice/ice_common.c
+++ b/drivers/net/ethernet/intel/ice/ice_common.c
@@ -964,7 +964,12 @@ static enum ice_status ice_pf_reset(struct ice_hw *hw)
 
 	wr32(hw, PFGEN_CTRL, (reg | PFGEN_CTRL_PFSWR_M));
 
-	for (cnt = 0; cnt < ICE_PF_RESET_WAIT_COUNT; cnt++) {
+	/* Wait for the PFR to complete. The wait time is the global config lock
+	 * timeout plus the PFR timeout which will account for a possible reset
+	 * that is occurring during a download package operation.
+	 */
+	for (cnt = 0; cnt < ICE_GLOBAL_CFG_LOCK_TIMEOUT +
+	     ICE_PF_RESET_WAIT_COUNT; cnt++) {
 		reg = rd32(hw, PFGEN_CTRL);
 		if (!(reg & PFGEN_CTRL_PFSWR_M))
 			break;
-- 
2.26.2


  parent reply	other threads:[~2020-05-31 12:36 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-31 12:36 [net-next 00/14][pull request] 100GbE Intel Wired LAN Driver Updates 2020-05-31 Jeff Kirsher
2020-05-31 12:36 ` [net-next 01/14] ice: allow host to clear administratively set VF MAC Jeff Kirsher
2020-05-31 12:36 ` [net-next 02/14] ice: support adding 16 unicast/multicast filter on untrusted VF Jeff Kirsher
2020-05-31 12:36 ` [net-next 03/14] ice: Fix transmit for all software offloaded VLANs Jeff Kirsher
2020-05-31 12:36 ` Jeff Kirsher [this message]
2020-05-31 12:36 ` [net-next 05/14] ice: Update ICE_PHY_TYPE_HIGH_MAX_INDEX value Jeff Kirsher
2020-05-31 12:36 ` [net-next 06/14] ice: Reset VF for all port VLAN changes from host Jeff Kirsher
2020-05-31 12:36 ` [net-next 07/14] ice: Always clear QRXFLXP_CNTXT before writing new value Jeff Kirsher
2020-05-31 12:36 ` [net-next 08/14] ice: Fix inability to set channels when down Jeff Kirsher
2020-05-31 12:36 ` [net-next 09/14] ice: Allow VF to request reset as soon as it's initialized Jeff Kirsher
2020-05-31 12:36 ` [net-next 10/14] ice: fix function signature style format Jeff Kirsher
2020-05-31 12:36 ` [net-next 11/14] ice: fix PCI device serial number to be lowercase values Jeff Kirsher
2020-05-31 12:36 ` [net-next 12/14] ice: Use coalesce values from q_vector 0 when increasing q_vectors Jeff Kirsher
2020-05-31 12:36 ` [net-next 13/14] ice: fix aRFS after flow director delete Jeff Kirsher
2020-05-31 12:36 ` [net-next 14/14] ice: Ignore EMODE when setting PHY config Jeff Kirsher
2020-05-31 12:50 ` [net-next 00/14][pull request] 100GbE Intel Wired LAN Driver Updates 2020-05-31 Kirsher, Jeffrey T
2020-06-01 19:10 ` 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=20200531123619.2887469-5-jeffrey.t.kirsher@intel.com \
    --to=jeffrey.t.kirsher@intel.com \
    --cc=andrewx.bowers@intel.com \
    --cc=dan.nowlin@intel.com \
    --cc=davem@davemloft.net \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.