[Devel] [PATCH] swappages in /proc/userbeancounters

Anton Vorobev anton.vorobev at gmail.com
Tue Nov 15 07:46:58 PST 2011


Hi, guys.

There is no swappages  line in /proc/user_beancounters.

Fix:


diff -uprN linux-rhel6.orig/kernel/bc/proc.c linux-rhel6/kernel/bc/proc.c
--- linux-rhel6.orig/kernel/bc/proc.c    2011-11-15 15:41:15.000000000 +0100
+++ linux-rhel6/kernel/bc/proc.c    2011-11-15 15:38:49.000000000 +0100
@@ -177,6 +177,10 @@ static int ub_show(struct seq_file *f, v

     for (i = 0; i < UB_RESOURCES_COMPAT; i++)
         ub_show_res(f, ub, i, precharge[i], 1);
+
+    for (i = UB_RESOURCES_COMPAT; i < UB_RESOURCES; i++)
+        ub_show_res(f, ub, i, precharge[i], 1);
+
     return 0;
 }
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openvz.org/pipermail/devel/attachments/20111115/7268b6f1/attachment-0001.html>


More information about the Devel mailing list