X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=mm%2Fswap.c;h=45c9f25a8a3be7e2dccc6a6f807e0eaeade1e697;hb=9aef85cc58f54f01bbbafdb3c87af4465f4257c0;hp=91e194445a5eae53ee3ae97e3f616cdcb7d442d0;hpb=ac6aadb24b7d4f0e54246732e221c102073412bf;p=linux-2.6 diff --git a/mm/swap.c b/mm/swap.c index 91e194445a..45c9f25a8a 100644 --- a/mm/swap.c +++ b/mm/swap.c @@ -503,7 +503,7 @@ void vm_acct_memory(long pages) local = &__get_cpu_var(committed_space); *local += pages; if (*local > ACCT_THRESHOLD || *local < -ACCT_THRESHOLD) { - atomic_add(*local, &vm_committed_space); + atomic_long_add(*local, &vm_committed_space); *local = 0; } preempt_enable(); @@ -520,7 +520,7 @@ static int cpu_swap_callback(struct notifier_block *nfb, committed = &per_cpu(committed_space, (long)hcpu); if (action == CPU_DEAD || action == CPU_DEAD_FROZEN) { - atomic_add(*committed, &vm_committed_space); + atomic_long_add(*committed, &vm_committed_space); *committed = 0; drain_cpu_pagevecs((long)hcpu); }