Drivers: hv: vss: Operation timeouts should match host expectation
authorAlex Ng <alexng@messages.microsoft.com>
Sun, 6 Nov 2016 21:14:11 +0000 (13:14 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 7 Nov 2016 09:01:17 +0000 (10:01 +0100)
Increase the timeout of backup operations. When system is under I/O load,
it needs more time to freeze. These timeout values should also match the
host timeout values more closely.

Signed-off-by: Alex Ng <alexng@microsoft.com>
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/hv/hv_snapshot.c

index 5c95ba1e2ecf9b0e04381248e667a17f0dde4318..eee238cc60bd09da1e260863f5d0532a893cbd7d 100644 (file)
 #define VSS_MINOR  0
 #define VSS_VERSION    (VSS_MAJOR << 16 | VSS_MINOR)
 
-#define VSS_USERSPACE_TIMEOUT (msecs_to_jiffies(10 * 1000))
+/*
+ * Timeout values are based on expecations from host
+ */
+#define VSS_FREEZE_TIMEOUT (15 * 60)
 
 /*
  * Global state maintained for transaction that is being processed. For a class
@@ -186,7 +189,8 @@ static void vss_send_op(void)
 
        vss_transaction.state = HVUTIL_USERSPACE_REQ;
 
-       schedule_delayed_work(&vss_timeout_work, VSS_USERSPACE_TIMEOUT);
+       schedule_delayed_work(&vss_timeout_work, op == VSS_OP_FREEZE ?
+                       VSS_FREEZE_TIMEOUT * HZ : HV_UTIL_TIMEOUT * HZ);
 
        rc = hvutil_transport_send(hvt, vss_msg, sizeof(*vss_msg), NULL);
        if (rc) {