Commit 07279cdfd964acc032de92a527cb11b1f40f35aa
Committed by
Linus Torvalds
1 parent
16f8c5b2e6
Exists in
master
and in
4 other branches
mm: show free swap as signed
Adjust <Alt><SysRq>m show_swap_cache_info() to show "Free swap" as a signed long: the signed format is preferable, because during swapoff nr_swap_pages can legitimately go negative, so makes more sense thus (it used to be shown redundantly, once as signed and once as unsigned). Signed-off-by: Hugh Dickins <hugh@veritas.com> Reviewed-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Showing 1 changed file with 1 additions and 1 deletions Side-by-side Diff
mm/swap_state.c
... | ... | @@ -60,7 +60,7 @@ |
60 | 60 | printk("Swap cache stats: add %lu, delete %lu, find %lu/%lu\n", |
61 | 61 | swap_cache_info.add_total, swap_cache_info.del_total, |
62 | 62 | swap_cache_info.find_success, swap_cache_info.find_total); |
63 | - printk("Free swap = %lukB\n", nr_swap_pages << (PAGE_SHIFT - 10)); | |
63 | + printk("Free swap = %ldkB\n", nr_swap_pages << (PAGE_SHIFT - 10)); | |
64 | 64 | printk("Total swap = %lukB\n", total_swap_pages << (PAGE_SHIFT - 10)); |
65 | 65 | } |
66 | 66 |