[prev in list] [next in list] [prev in thread] [next in thread] 

List:       xen-cvs
Subject:    [Xen-changelog] [xen master] tmem: add tmem_disable() function
From:       patchbot () xen ! org
Date:       2016-03-18 10:44:12
Message-ID: E1agrt6-0002n4-Q3 () xenbits ! xenproject ! org
[Download RAW message or body]

commit dba8bfb94dd3d51f7576dfbdd1d541aa75f90457
Author:     Doug Goldstein <cardoe@cardoe.com>
AuthorDate: Wed Mar 16 09:10:59 2016 -0500
Commit:     Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
CommitDate: Wed Mar 16 10:54:05 2016 -0400

    tmem: add tmem_disable() function
    
    Instead of manipulating the opt_tmem variable directly utilize a wrapper
    function.
    
    Signed-off-by: Doug Goldstein <cardoe@cardoe.com>
    Acked-by: Jan Beulich <jbeulich@suse.com>
    Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
---
 xen/arch/x86/setup.c       | 4 ++--
 xen/include/xen/tmem_xen.h | 5 +++++
 2 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/xen/arch/x86/setup.c b/xen/arch/x86/setup.c
index a8bf2c9..5011930 100644
--- a/xen/arch/x86/setup.c
+++ b/xen/arch/x86/setup.c
@@ -25,7 +25,7 @@
 #include <xen/dmi.h>
 #include <xen/pfn.h>
 #include <xen/nodemask.h>
-#include <xen/tmem_xen.h> /* for opt_tmem only */
+#include <xen/tmem_xen.h>
 #include <xen/watchdog.h>
 #include <public/version.h>
 #include <compat/platform.h>
@@ -1276,7 +1276,7 @@ void __init noreturn __start_xen(unsigned long mbi_p)
         {
            printk(XENLOG_WARNING
                   "TMEM physical RAM limit exceeded, disabling TMEM\n");
-           opt_tmem = 0;
+           tmem_disable();
         }
     }
     else
diff --git a/xen/include/xen/tmem_xen.h b/xen/include/xen/tmem_xen.h
index c770f3e..f516bbe 100644
--- a/xen/include/xen/tmem_xen.h
+++ b/xen/include/xen/tmem_xen.h
@@ -69,6 +69,11 @@ static inline bool_t tmem_enabled(void)
     return opt_tmem;
 }
 
+static inline void tmem_disable(void)
+{
+    opt_tmem = 0;
+}
+
 /*
  * Memory free page list management
  */
--
generated by git-patchbot for /home/xen/git/xen.git#master

_______________________________________________
Xen-changelog mailing list
Xen-changelog@lists.xen.org
http://lists.xensource.com/xen-changelog
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic