summaryrefslogtreecommitdiffstats
path: root/commands
diff options
context:
space:
mode:
Diffstat (limited to 'commands')
-rw-r--r--commands/memtest.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/commands/memtest.c b/commands/memtest.c
index 403ab91f6f..dc8f7db279 100644
--- a/commands/memtest.c
+++ b/commands/memtest.c
@@ -36,8 +36,7 @@ static int do_test_one_area(struct mem_test_resource *r, int bus_only,
printf("Testing memory space: %pa -> %pa:\n",
&r->r->start, &r->r->end);
- remap_range((void *)r->r->start, r->r->end -
- r->r->start + 1, cache_flag);
+ remap_range((void *)r->r->start, resource_size(r->r), cache_flag);
ret = mem_test_bus_integrity(r->r->start, r->r->end);
if (ret < 0)