From: Michal Schmidt <mschmidt@redhat.com>
To: intel-wired-lan@lists.osuosl.org
Cc: netdev@vger.kernel.org,
Jesse Brandeburg <jesse.brandeburg@intel.com>,
Karol Kolacinski <karol.kolacinski@intel.com>,
Tony Nguyen <anthony.l.nguyen@intel.com>
Subject: [Intel-wired-lan] [PATCH net-next 4/4] ice: sleep, don't busy-wait, in the SQ send retry loop
Date: Sat, 1 Apr 2023 19:26:59 +0200 [thread overview]
Message-ID: <20230401172659.38508-5-mschmidt@redhat.com> (raw)
In-Reply-To: <20230401172659.38508-1-mschmidt@redhat.com>
10 ms is a lot of time to spend busy-waiting. Sleeping is clearly
allowed here, because we have just returned from ice_sq_send_cmd(),
which takes a mutex.
On kernels with HZ=100, this msleep may be twice as long, but I don't
think it matters.
I did not actually observe any retries happening here.
Signed-off-by: Michal Schmidt <mschmidt@redhat.com>
---
drivers/net/ethernet/intel/ice/ice_common.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/intel/ice/ice_common.c b/drivers/net/ethernet/intel/ice/ice_common.c
index 539b756f227c..438367322bcd 100644
--- a/drivers/net/ethernet/intel/ice/ice_common.c
+++ b/drivers/net/ethernet/intel/ice/ice_common.c
@@ -1643,7 +1643,7 @@ ice_sq_send_cmd_retry(struct ice_hw *hw, struct ice_ctl_q_info *cq,
memcpy(desc, &desc_cpy, sizeof(desc_cpy));
- mdelay(ICE_SQ_SEND_DELAY_TIME_MS);
+ msleep(ICE_SQ_SEND_DELAY_TIME_MS);
} while (++idx < ICE_SQ_SEND_MAX_EXECUTE);
--
2.39.2
_______________________________________________
Intel-wired-lan mailing list
Intel-wired-lan@osuosl.org
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
prev parent reply other threads:[~2023-04-01 17:27 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-01 17:26 [Intel-wired-lan] [PATCH net-next 0/4] ice: lower CPU usage with GNSS Michal Schmidt
2023-04-01 17:26 ` [Intel-wired-lan] [PATCH net-next 1/4] ice: lower CPU usage of the GNSS read thread Michal Schmidt
2023-04-01 18:29 ` Andrew Lunn
2023-04-03 13:36 ` Michal Schmidt
2023-04-04 9:25 ` Kolacinski, Karol
2023-04-01 17:26 ` [Intel-wired-lan] [PATCH net-next 2/4] ice: sleep, don't busy-wait, for sq_cmd_timeout Michal Schmidt
2023-04-02 11:18 ` Simon Horman
2023-04-03 13:42 ` Michal Schmidt
2023-04-01 17:26 ` [Intel-wired-lan] [PATCH net-next 3/4] ice: remove unused buffer copy code in ice_sq_send_cmd_retry() Michal Schmidt
2023-04-01 17:26 ` Michal Schmidt [this message]
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=20230401172659.38508-5-mschmidt@redhat.com \
--to=mschmidt@redhat.com \
--cc=anthony.l.nguyen@intel.com \
--cc=intel-wired-lan@lists.osuosl.org \
--cc=jesse.brandeburg@intel.com \
--cc=karol.kolacinski@intel.com \
--cc=netdev@vger.kernel.org \
/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.