rpms/kernel/devel fix-ppc-debug_kmap_atomic.patch, NONE, 1.1 kernel.spec, 1.1497, 1.1498

Kyle McMartin kyle at fedoraproject.org
Thu Apr 2 13:04:31 UTC 2009


Author: kyle

Update of /cvs/pkgs/rpms/kernel/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv402

Modified Files:
	kernel.spec 
Added Files:
	fix-ppc-debug_kmap_atomic.patch 
Log Message:
* Thu Apr 02 2009 Kyle McMartin <kyle at redhat.com>
- fix-ppc-debug_kmap_atomic.patch: fix build failures on ppc.


fix-ppc-debug_kmap_atomic.patch:

--- NEW FILE fix-ppc-debug_kmap_atomic.patch ---
The following commit breaks PPC builds with CONFIG_HIGHMEM=y

commit f4112de6b679d84bd9b9681c7504be7bdfb7c7d5
Author: Akinobu Mita <akinobu.mita at gmail.com>
Date:   Tue Mar 31 15:23:25 2009 -0700

    mm: introduce debug_kmap_atomic

We get:

 CC      init/main.o
In file included from include/linux/highmem.h:25,
                 from include/linux/pagemap.h:11,
                 from include/linux/mempolicy.h:63,
                 from init/main.c:53:
linux-2.6/arch/powerpc/include/asm/highmem.h: In function 'kmap_atomic_prot':
linux-2.6/arch/powerpc/include/asm/highmem.h:98: error: implicit declaration of function 'debug_kmap_atomic'
In file included from include/linux/pagemap.h:11,
                 from include/linux/mempolicy.h:63,
                 from init/main.c:53:
include/linux/highmem.h: At top level:
include/linux/highmem.h:196: warning: conflicting types for 'debug_kmap_atomic'
include/linux/highmem.h:196: error: static declaration of 'debug_kmap_atomic' follows non-static declaration
linux-2.6/include/asm/highmem.h:98: error: previous implicit declaration of 'debug_kmap_atomic' was here
make[1]: *** [init/main.o] Error 1
make: *** [init] Error 2

Signed-off-by: Kumar Gala <galak at kernel.crashing.org>
---

Should address Akinobu issues w/having this build properly on x86

- k

 include/linux/highmem.h |   29 ++++++++++++++---------------
 1 files changed, 14 insertions(+), 15 deletions(-)

diff --git a/include/linux/highmem.h b/include/linux/highmem.h
index 7ff5c55..1fcb712 100644
--- a/include/linux/highmem.h
+++ b/include/linux/highmem.h
@@ -19,8 +19,21 @@ static inline void flush_kernel_dcache_page(struct page *page)
 }
 #endif
 
-#ifdef CONFIG_HIGHMEM
+#include <asm/kmap_types.h>
+
+#if defined(CONFIG_DEBUG_HIGHMEM) && defined(CONFIG_TRACE_IRQFLAGS_SUPPORT)
+
+void debug_kmap_atomic(enum km_type type);
+
+#else
 
+static inline void debug_kmap_atomic(enum km_type type)
+{
+}
+
+#endif
+
+#ifdef CONFIG_HIGHMEM
 #include <asm/highmem.h>
 
 /* declarations for linux/mm/highmem.c */
@@ -44,8 +57,6 @@ static inline void *kmap(struct page *page)
 
 #define kunmap(page) do { (void) (page); } while (0)
 
-#include <asm/kmap_types.h>
-
 static inline void *kmap_atomic(struct page *page, enum km_type idx)
 {
 	pagefault_disable();
@@ -187,16 +198,4 @@ static inline void copy_highpage(struct page *to, struct page *from)
 	kunmap_atomic(vto, KM_USER1);
 }
 
-#if defined(CONFIG_DEBUG_HIGHMEM) && defined(CONFIG_TRACE_IRQFLAGS_SUPPORT)
-
-void debug_kmap_atomic(enum km_type type);
-
-#else
-
-static inline void debug_kmap_atomic(enum km_type type)
-{
-}
-
-#endif
-
 #endif /* _LINUX_HIGHMEM_H */
-- 
1.5.6.6

_______________________________________________
Linuxppc-dev mailing list
Linuxppc-dev at ozlabs.org
https://ozlabs.org/mailman/listinfo/linuxppc-dev



Index: kernel.spec
===================================================================
RCS file: /cvs/pkgs/rpms/kernel/devel/kernel.spec,v
retrieving revision 1.1497
retrieving revision 1.1498
diff -u -r1.1497 -r1.1498
--- kernel.spec	2 Apr 2009 04:04:34 -0000	1.1497
+++ kernel.spec	2 Apr 2009 13:04:01 -0000	1.1498
@@ -599,6 +599,7 @@
 Patch41: linux-2.6-sysrq-c.patch
 
 Patch50: rds-only-on-64-bit-or-x86.patch
+Patch51: fix-ppc-debug_kmap_atomic.patch
 
 Patch141: linux-2.6-ps3-storage-alias.patch
 Patch143: linux-2.6-g5-therm-shutdown.patch
@@ -1103,6 +1104,7 @@
 ApplyPatch linux-2.6-sysrq-c.patch
 
 ApplyPatch rds-only-on-64-bit-or-x86.patch
+ApplyPatch fix-ppc-debug_kmap_atomic.patch
 
 # Architecture patches
 # x86(-64)
@@ -1889,6 +1891,9 @@
 #	                ||     ||
 %changelog
 * Thu Apr 02 2009 Kyle McMartin <kyle at redhat.com>
+- fix-ppc-debug_kmap_atomic.patch: fix build failures on ppc.
+
+* Thu Apr 02 2009 Kyle McMartin <kyle at redhat.com>
 - Linux 2.6.29-git9
 
 * Tue Mar 31 2009 Kyle McMartin <kyle at redhat.com>




More information about the scm-commits mailing list