diff options
author | Wanpeng Li <liwanp@linux.vnet.ibm.com> | 2013-09-11 23:22:54 +0200 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-09-12 00:58:09 +0200 |
commit | dd9538a597f9ccd9a65be1cc3f71059a12b5b4ff (patch) | |
tree | d0c4c915b7dc9d38632587964c732cf7f54eff85 /mm | |
parent | mm/hwpoison: fix race against poison thp (diff) | |
download | linux-dd9538a597f9ccd9a65be1cc3f71059a12b5b4ff.tar.xz linux-dd9538a597f9ccd9a65be1cc3f71059a12b5b4ff.zip |
mm/hwpoison: replace atomic_long_sub() with atomic_long_dec()
Replace atomic_long_sub() with atomic_long_dec() since the page is normal
page instead of hugetlbfs page or thp.
Signed-off-by: Wanpeng Li <liwanp@linux.vnet.ibm.com>
Reviewed-by: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com>
Cc: Andi Kleen <andi@firstfloor.org>
Cc: Tony Luck <tony.luck@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm')
-rw-r--r-- | mm/memory-failure.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/memory-failure.c b/mm/memory-failure.c index 32351ec32048..c69217c07faa 100644 --- a/mm/memory-failure.c +++ b/mm/memory-failure.c @@ -1366,7 +1366,7 @@ int unpoison_memory(unsigned long pfn) return 0; } if (TestClearPageHWPoison(p)) - atomic_long_sub(nr_pages, &num_poisoned_pages); + atomic_long_dec(&num_poisoned_pages); pr_info("MCE: Software-unpoisoned free page %#lx\n", pfn); return 0; } |