From: Intel Date: Wed, 18 Sep 2013 10:00:00 +0000 (+0200) Subject: app/test: fix memzone test X-Git-Tag: spdx-start~11119 X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=65043089720a39aedfef178fe2c2d9ac1b54b5ac;p=dpdk.git app/test: fix memzone test Signed-off-by: Intel --- diff --git a/app/test/test_memzone.c b/app/test/test_memzone.c index 79e5231496..294c0dbcce 100644 --- a/app/test/test_memzone.c +++ b/app/test/test_memzone.c @@ -296,7 +296,7 @@ test_memzone_reserve_max(void) /* check if the memzone is in our memseg and subtract length */ if ((config->mem_config->memzone[memzone_idx].addr >= ms[memseg_idx].addr) && - (config->mem_config->memzone[memzone_idx].addr <= + (config->mem_config->memzone[memzone_idx].addr < (RTE_PTR_ADD(ms[memseg_idx].addr, ms[memseg_idx].len)))) { /* since the zones can now be aligned and occasionally skip * some space, we should calculate the length based on @@ -389,7 +389,7 @@ test_memzone_reserve_max_aligned(void) /* check if the memzone is in our memseg and subtract length */ if ((config->mem_config->memzone[memzone_idx].addr >= ms[memseg_idx].addr) && - (config->mem_config->memzone[memzone_idx].addr <= + (config->mem_config->memzone[memzone_idx].addr < (RTE_PTR_ADD(ms[memseg_idx].addr, ms[memseg_idx].len)))) { /* since the zones can now be aligned and occasionally skip * some space, we should calculate the length based on