tcmu: Allow cmd_time_out to be set to zero (disabled)
authorNicholas Bellinger <nab@linux-iscsi.org>
Tue, 21 Mar 2017 04:04:05 +0000 (21:04 -0700)
committerNicholas Bellinger <nab@linux-iscsi.org>
Thu, 30 Mar 2017 08:36:44 +0000 (01:36 -0700)
The new cmd_time_out configfs attribute for TCMU is allowed to
be disabled, so go ahead and drop the tcmu_cmd_time_out_store()
check.

Reported-by: Mike Christie <mchristi@redhat.com>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
drivers/target/target_core_user.c

index c6874c3..6a17c78 100644 (file)
@@ -1196,11 +1196,6 @@ static ssize_t tcmu_cmd_time_out_store(struct config_item *item, const char *pag
        if (ret < 0)
                return ret;
 
-       if (!val) {
-               pr_err("Illegal value for cmd_time_out\n");
-               return -EINVAL;
-       }
-
        udev->cmd_time_out = val * MSEC_PER_SEC;
        return count;
 }