Commit 7c4f4c4f authored by Shannon Nelson's avatar Shannon Nelson Committed by David S. Miller
Browse files

pds_core: smaller adminq poll starting interval



Shorten the adminq poll starting interval in order to notice
any transaction errors more quickly.

Signed-off-by: default avatarShannon Nelson <shannon.nelson@amd.com>
Reviewed-by: default avatarSimon Horman <horms@kernel.org>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 144530c1
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -225,7 +225,7 @@ int pdsc_adminq_post(struct pdsc *pdsc,
		     union pds_core_adminq_comp *comp,
		     bool fast_poll)
{
	unsigned long poll_interval = 1;
	unsigned long poll_interval = 200;
	unsigned long poll_jiffies;
	unsigned long time_limit;
	unsigned long time_start;
@@ -252,7 +252,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, poll_jiffies);
		if (remaining)
			break;
+1 −1
Original line number Diff line number Diff line
@@ -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 */