WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [linux-2.6.18-xen] Stop low memory from appearing -ve in

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [linux-2.6.18-xen] Stop low memory from appearing -ve in /proc/meminfo when ballooned.
From: "Xen patchbot-linux-2.6.18-xen" <patchbot-linux-2.6.18-xen@xxxxxxxxxxxxxxxxxxx>
Date: Sun, 01 Jul 2007 18:31:36 -0700
Delivery-date: Sun, 01 Jul 2007 18:29:51 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User kfraser@xxxxxxxxxxxxxxxxxxxxx
# Date 1183324052 -3600
# Node ID 57ab8dd47580c2f726556fe1c46b5401f2bddb1e
# Parent  0be610b725fae4cd6de8f0b111660a186f93b86d
Stop low memory from appearing -ve in /proc/meminfo when ballooned.
Signed-off-by: Mark Williamson <mark.williamson@xxxxxxxxxxxx>
---
 drivers/xen/balloon/balloon.c |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletion(-)

diff -r 0be610b725fa -r 57ab8dd47580 drivers/xen/balloon/balloon.c
--- a/drivers/xen/balloon/balloon.c     Wed Jun 27 16:31:36 2007 +0100
+++ b/drivers/xen/balloon/balloon.c     Sun Jul 01 22:07:32 2007 +0100
@@ -83,6 +83,7 @@ static unsigned long frame_list[PAGE_SIZ
 
 /* VM /proc information for memory */
 extern unsigned long totalram_pages;
+extern unsigned long totalhigh_pages;
 
 /* List of ballooned pages, threaded through the mem_map array. */
 static LIST_HEAD(ballooned_pages);
@@ -118,6 +119,7 @@ static void balloon_append(struct page *
        if (PageHighMem(page)) {
                list_add_tail(PAGE_TO_LIST(page), &ballooned_pages);
                bs.balloon_high++;
+               totalhigh_pages--;
        } else {
                list_add(PAGE_TO_LIST(page), &ballooned_pages);
                bs.balloon_low++;
@@ -135,8 +137,10 @@ static struct page *balloon_retrieve(voi
        page = LIST_TO_PAGE(ballooned_pages.next);
        UNLIST_PAGE(page);
 
-       if (PageHighMem(page))
+       if (PageHighMem(page)) {
                bs.balloon_high--;
+               totalhigh_pages++;
+       }
        else
                bs.balloon_low--;
 

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [linux-2.6.18-xen] Stop low memory from appearing -ve in /proc/meminfo when ballooned., Xen patchbot-linux-2.6.18-xen <=