From 5c5b6da768b6d45efdf5a100bd0f45698d99a511 Mon Sep 17 00:00:00 2001 From: stefan Date: Mon, 9 Aug 2010 17:55:05 +0000 Subject: [PATCH] - fix bug in memory counting git-svn-id: http://svn.lfbs.rwth-aachen.de/svn/scc/trunk/MetalSVM@54 315a16e6-25f9-4109-90ae-ca3045a26c18 --- mm/memory.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/mm/memory.c b/mm/memory.c index 870ae3bc..31f0d567 100644 --- a/mm/memory.c +++ b/mm/memory.c @@ -171,10 +171,10 @@ next_try: page_set_mark(l); alloc_start = i+j; - atomic_int32_add(&total_allocated_pages, npages*PAGE_SIZE); - atomic_int32_sub(&total_available_pages, npages*PAGE_SIZE); + atomic_int32_add(&total_allocated_pages, npages); + atomic_int32_sub(&total_available_pages, npages); if (task) - atomic_int32_add(&(task->mem_usage), npages*PAGE_SIZE); + atomic_int32_add(&(task->mem_usage), npages); oom: spinlock_unlock(&bitmap_lock);