[lustre-devel] [PATCH 27/30] lustre: ptlrpc: increase sleep time in ptlrpc_request_bufs_pack()

James Simmons jsimmons at infradead.org
Mon Sep 17 10:30:37 PDT 2018


From: Vitaly Fertman <c17818 at cray.com>

schedule_timeout_uninterruptible() does not necessarily expire.
Increase the sleeping time in ptlrpc_request_bufs_pack() as 2
seconds is too short, given the 1 second sleep used in the test
suite.

Signed-off-by: Vitaly Fertman <c17818 at cray.com>
Signed-off-by: Andreas Dilger <adilger at whamcloud.com>
WC-bug-id: https://jira.whamcloud.com/browse/LU-8062
Reviewed-on: https://review.whamcloud.com/26815
Reviewed-by: James Simmons <uja.ornl at yahoo.com>
Reviewed-by: Fan Yong <fan.yong at intel.com>
Reviewed-by: John L. Hammond <jhammond at whamcloud.com>
Signed-off-by: James Simmons <jsimmons at infradead.org>
---
 drivers/staging/lustre/lustre/ptlrpc/client.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/lustre/lustre/ptlrpc/client.c b/drivers/staging/lustre/lustre/ptlrpc/client.c
index eddb920..6d503d7 100644
--- a/drivers/staging/lustre/lustre/ptlrpc/client.c
+++ b/drivers/staging/lustre/lustre/ptlrpc/client.c
@@ -36,7 +36,9 @@
 #define DEBUG_SUBSYSTEM S_RPC
 
 #include <linux/libcfs/libcfs_cpu.h>
+#include <linux/delay.h>
 #include <linux/random.h>
+
 #include <obd_support.h>
 #include <obd_class.h>
 #include <lustre_lib.h>
@@ -763,7 +765,7 @@ int ptlrpc_request_bufs_pack(struct ptlrpc_request *request,
 			/* The RPC is infected, let the test change the
 			 * fail_loc
 			 */
-			schedule_timeout_uninterruptible(2 * HZ);
+			msleep(4 * MSEC_PER_SEC);
 		}
 	}
 
-- 
1.8.3.1



More information about the lustre-devel mailing list