mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Shannon Nelson <shannon.nelson@amd.com>
To: <andrew+netdev@lunn.ch>, <brett.creeley@amd.com>,
	<davem@davemloft.net>, <edumazet@google.com>, <kuba@kernel.org>,
	<pabeni@redhat.com>, <michal.swiatkowski@linux.intel.com>,
	<linux-kernel@vger.kernel.org>, <netdev@vger.kernel.org>
Cc: Shannon Nelson <shannon.nelson@amd.com>
Subject: [PATCH net 5/6] pds_core: smaller adminq poll starting interval
Date: Mon, 7 Apr 2025 15:51:12 -0700	[thread overview]
Message-ID: <20250407225113.51850-6-shannon.nelson@amd.com> (raw)
In-Reply-To: <20250407225113.51850-1-shannon.nelson@amd.com>

Shorten the adminq poll starting interval in order to speed
up the transaction response time.

Fixes: 01ba61b55b20 ("pds_core: Add adminq processing and commands")
Signed-off-by: Shannon Nelson <shannon.nelson@amd.com>
---
 drivers/net/ethernet/amd/pds_core/adminq.c | 4 ++--
 include/linux/pds/pds_adminq.h             | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/ethernet/amd/pds_core/adminq.c b/drivers/net/ethernet/amd/pds_core/adminq.c
index c83a0a80d533..2e840112efea 100644
--- a/drivers/net/ethernet/amd/pds_core/adminq.c
+++ b/drivers/net/ethernet/amd/pds_core/adminq.c
@@ -235,7 +235,7 @@ int pdsc_adminq_post(struct pdsc *pdsc,
 		.wait_completion =
 			COMPLETION_INITIALIZER_ONSTACK(wc.wait_completion),
 	};
-	unsigned long poll_interval = 1;
+	unsigned long poll_interval = 200;
 	unsigned long poll_jiffies;
 	unsigned long time_limit;
 	unsigned long time_start;
@@ -261,7 +261,7 @@ int pdsc_adminq_post(struct pdsc *pdsc,
 	time_limit = time_start + HZ * pdsc->devcmd_timeout;
 	do {
 		/* Timeslice the actual wait to catch IO errors etc early */
-		poll_jiffies = msecs_to_jiffies(poll_interval);
+		poll_jiffies = usecs_to_jiffies(poll_interval);
 		remaining = wait_for_completion_timeout(&wc.wait_completion,
 							poll_jiffies);
 		if (remaining)
diff --git a/include/linux/pds/pds_adminq.h b/include/linux/pds/pds_adminq.h
index 339156113fa5..40ff0ec2b879 100644
--- a/include/linux/pds/pds_adminq.h
+++ b/include/linux/pds/pds_adminq.h
@@ -4,7 +4,7 @@
 #ifndef _PDS_CORE_ADMINQ_H_
 #define _PDS_CORE_ADMINQ_H_
 
-#define PDSC_ADMINQ_MAX_POLL_INTERVAL	256
+#define PDSC_ADMINQ_MAX_POLL_INTERVAL	256000	/* usecs */
 
 enum pds_core_adminq_flags {
 	PDS_AQ_FLAG_FASTPOLL	= BIT(1),	/* completion poll at 1ms */
-- 
2.17.1


  parent reply	other threads:[~2025-04-07 22:51 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-07 22:51 [PATCH net 0/6] pds_core: updates and fixes Shannon Nelson
2025-04-07 22:51 ` [PATCH net 1/6] pds_core: Prevent possible adminq overflow/stuck condition Shannon Nelson
2025-04-09  9:37   ` Simon Horman
2025-04-09 23:32     ` Nelson, Shannon
2025-04-11 18:59       ` Simon Horman
2025-04-07 22:51 ` [PATCH net 2/6] pds_core: remove extra name description Shannon Nelson
2025-04-09  9:41   ` Simon Horman
2025-04-07 22:51 ` [PATCH net 3/6] pds_core: handle unsupported PDS_CORE_CMD_FW_CONTROL result Shannon Nelson
2025-04-09 16:34   ` Simon Horman
2025-04-09 23:35     ` Nelson, Shannon
2025-04-07 22:51 ` [PATCH net 4/6] pds_core: Remove unnecessary check in pds_client_adminq_cmd() Shannon Nelson
2025-04-09 17:07   ` Simon Horman
2025-04-07 22:51 ` Shannon Nelson [this message]
2025-04-09 16:50   ` [PATCH net 5/6] pds_core: smaller adminq poll starting interval Simon Horman
2025-04-09 23:28     ` Nelson, Shannon
2025-04-07 22:51 ` [PATCH net 6/6] pds_core: make wait_context part of q_info Shannon Nelson
2025-04-09 17:06   ` Simon Horman

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=20250407225113.51850-6-shannon.nelson@amd.com \
    --to=shannon.nelson@amd.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=brett.creeley@amd.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=michal.swiatkowski@linux.intel.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@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

all inboxes | Powered by JetHome®