[PATCH 21/23] test driver: remove TEST_BLOCK_IOTUNE_MAX checks

Nikolay Shirokovskiy posted 23 patches 5 years ago
[PATCH 21/23] test driver: remove TEST_BLOCK_IOTUNE_MAX checks
Posted by Nikolay Shirokovskiy 5 years ago
The check is copied from qemu driver I guess and does not make much sense for
test driver. This patch is a preparation step to get rid of macros in this
place.  And I guess it make sence just to drop this check instead of moving to
some function.

Signed-off-by: Nikolay Shirokovskiy <nshirokovskiy@virtuozzo.com>
---
 src/test/test_driver.c | 9 ---------
 1 file changed, 9 deletions(-)

diff --git a/src/test/test_driver.c b/src/test/test_driver.c
index 299be2a..58d3d79 100644
--- a/src/test/test_driver.c
+++ b/src/test/test_driver.c
@@ -3599,8 +3599,6 @@ testDomainGetInterfaceParameters(virDomainPtr dom,
 }
 
 
-#define TEST_BLOCK_IOTUNE_MAX 1000000000000000LL
-
 static int
 testDomainSetBlockIoTune(virDomainPtr dom,
                          const char *path,
@@ -3699,13 +3697,6 @@ testDomainSetBlockIoTune(virDomainPtr dom,
     for (i = 0; i < nparams; i++) {
         virTypedParameterPtr param = &params[i];
 
-        if (param->value.ul > TEST_BLOCK_IOTUNE_MAX) {
-            virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED,
-                           _("block I/O throttle limit value must"
-                             " be no more than %llu"), TEST_BLOCK_IOTUNE_MAX);
-            goto cleanup;
-        }
-
         SET_IOTUNE_FIELD(total_bytes_sec,
                          VIR_DOMAIN_BLOCK_IOTUNE_TOTAL_BYTES_SEC,
                          VIR_DOMAIN_TUNABLE_BLKDEV_TOTAL_BYTES_SEC);
-- 
1.8.3.1

Re: [PATCH 21/23] test driver: remove TEST_BLOCK_IOTUNE_MAX checks
Posted by Peter Krempa 4 years, 11 months ago
On Mon, Jan 11, 2021 at 12:50:14 +0300, Nikolay Shirokovskiy wrote:
> The check is copied from qemu driver I guess and does not make much sense for
> test driver. This patch is a preparation step to get rid of macros in this
> place.  And I guess it make sence just to drop this check instead of moving to

s/sence/sense/

> some function.
> 
> Signed-off-by: Nikolay Shirokovskiy <nshirokovskiy@virtuozzo.com>
> ---
>  src/test/test_driver.c | 9 ---------
>  1 file changed, 9 deletions(-)

Reviewed-by: Peter Krempa <pkrempa@redhat.com>