aboutsummaryrefslogtreecommitdiff
path: root/include/linux/mman.h
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2009-05-18 07:37:44 +0200
committerIngo Molnar <mingo@elte.hu>2009-05-18 07:37:49 +0200
commitdc3f81b129b5439ba7bac265bbc6a51a39275dae (patch)
tree216030731d911249496d2e97206cd61431e31c89 /include/linux/mman.h
parentd2517a49d55536b38c7a87e5289550cfedaa4dcc (diff)
parent1406de8e11eb043681297adf86d6892ff8efc27a (diff)
Merge commit 'v2.6.30-rc6' into perfcounters/core
Merge reason: this branch was on an -rc4 base, merge it up to -rc6 to get the latest upstream fixes. Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include/linux/mman.h')
-rw-r--r--include/linux/mman.h9
1 files changed, 3 insertions, 6 deletions
diff --git a/include/linux/mman.h b/include/linux/mman.h
index 30d1073bac3..9872d6ca58a 100644
--- a/include/linux/mman.h
+++ b/include/linux/mman.h
@@ -12,21 +12,18 @@
#ifdef __KERNEL__
#include <linux/mm.h>
+#include <linux/percpu_counter.h>
#include <asm/atomic.h>
extern int sysctl_overcommit_memory;
extern int sysctl_overcommit_ratio;
-extern atomic_long_t vm_committed_space;
+extern struct percpu_counter vm_committed_as;
-#ifdef CONFIG_SMP
-extern void vm_acct_memory(long pages);
-#else
static inline void vm_acct_memory(long pages)
{
- atomic_long_add(pages, &vm_committed_space);
+ percpu_counter_add(&vm_committed_as, pages);
}
-#endif
static inline void vm_unacct_memory(long pages)
{