[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [PATCH] xen-tmem: Build cleancache shim to Xen Transcendent Memory only if Cleancache is enabled


  • To: xen-devel@xxxxxxxxxxxxxxxxxxx
  • From: Nikanth Karthikesan <nikanth@xxxxxxxxxx>
  • Date: Fri, 10 Jun 2011 14:27:03 +0530
  • Cc: Jeremy Fitzhardinge <jeremy.fitzhardinge@xxxxxxxxxx>, Konrad Rzeszutek Wilk <konrad.wilk@xxxxxxxxxx>
  • Delivery-date: Fri, 10 Jun 2011 14:44:34 -0700
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=google.com; s=beta; h=subject:from:to:cc:content-type:date:message-id:mime-version :x-mailer:content-transfer-encoding; b=TXNHAy4+Ik1T1iZsHwtAHbrtPL1Xi4rEUJemtyqFHfpBl01hcDLoNN90xGeJFbvUkK 2zkdxf2JjU+QIXUSbgYA==
  • List-id: Xen developer discussion <xen-devel.lists.xensource.com>

xen-tmem: Build cleancache shim to Xen Transcendent Memory only if Cleancache 
is enabled

Fix compilation warning

drivers/xen/tmem.c: In function âxen_tmem_initâ:
drivers/xen/tmem.c:246: warning: unused variable âold_opsâ
drivers/xen/tmem.c: At top level:
drivers/xen/tmem.c:234: warning: âtmem_cleancache_opsâ defined but not used

Signed-off-by: Nikanth Karthikesan <nikanth@xxxxxxxxxx>

---

Index: linux-2.6/drivers/xen/Makefile
===================================================================
--- linux-2.6.orig/drivers/xen/Makefile 2011-06-10 13:42:18.521140982 +0530
+++ linux-2.6/drivers/xen/Makefile      2011-06-10 13:44:50.110986353 +0530
@@ -1,6 +1,6 @@
 obj-y  += grant-table.o features.o events.o manage.o balloon.o
 obj-y  += xenbus/
-obj-y  += tmem.o
+obj-$(CONFIG_CLEAN_CACHE)      += tmem.o
 
 nostackp := $(call cc-option, -fno-stack-protector)
 CFLAGS_features.o                      := $(nostackp)
Index: linux-2.6/drivers/xen/tmem.c
===================================================================
--- linux-2.6.orig/drivers/xen/tmem.c   2011-06-10 12:19:14.522391890 +0530
+++ linux-2.6/drivers/xen/tmem.c        2011-06-10 13:45:42.500984200 +0530
@@ -247,7 +247,6 @@
 
        if (!xen_domain())
                return 0;
-#ifdef CONFIG_CLEANCACHE
        BUG_ON(sizeof(struct cleancache_filekey) != sizeof(struct tmem_oid));
        if (tmem_enabled && use_cleancache) {
                char *s = "";
@@ -257,7 +256,6 @@
                printk(KERN_INFO "cleancache enabled, RAM provided by "
                                 "Xen Transcendent Memory%s\n", s);
        }
-#endif
        return 0;
 }
 



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


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.