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

[XenPPC] [xenppc-unstable] [ppc] normalize and comment on all gcc warnings used



# HG changeset patch
# User Jimi Xenidis <jimix@xxxxxxxxxxxxxx>
# Node ID cd04c78dd63512ea9933196374d20ab9fbd4eb47
# Parent  ffdf3f94a727de6ccd23a245ba7e70e3ee38a657
[ppc] normalize and comment on all gcc warnings used

Oh yeah, and fix one they caught

Signed-off-by: Jimi Xenidis <jimix@xxxxxxxxxxxxxx>
---
 xen/arch/ppc/Makefile     |    6 ++++--
 xen/arch/ppc/Rules.mk     |    8 +++++++-
 xen/arch/ppc/papr/xlate.c |    2 +-
 3 files changed, 12 insertions(+), 4 deletions(-)

diff -r ffdf3f94a727 -r cd04c78dd635 xen/arch/ppc/Makefile
--- a/xen/arch/ppc/Makefile     Fri Jun 30 07:24:53 2006 -0400
+++ b/xen/arch/ppc/Makefile     Fri Jun 30 08:15:04 2006 -0400
@@ -44,8 +44,10 @@ obj-y += firmware_image.o
 
 obj-y += elf32.o
 
-CFLAGS += -Wundef -Wpointer-arith
-CFLAGS += -Wmissing-prototypes -Wmissing-declarations -Wpacked
+# These are extra warnings like for the arch/ppc directory but may not
+# allow the rest of the tree to build.
+PPC_C_WARNINGS += -Wundef -Wmissing-prototypes -Wmissing-declarations
+CFLAGS += $(PPC_C_WARNINGS)
 
 LINK=0x3000000
 boot32_link_base = $(LINK)
diff -r ffdf3f94a727 -r cd04c78dd635 xen/arch/ppc/Rules.mk
--- a/xen/arch/ppc/Rules.mk     Fri Jun 30 07:24:53 2006 -0400
+++ b/xen/arch/ppc/Rules.mk     Fri Jun 30 08:15:04 2006 -0400
@@ -2,13 +2,19 @@ HAS_PPC64 := y
 
 CC := $(CROSS_COMPILE)gcc
 LD := $(CROSS_COMPILE)ld
+
+# These are gooness that applies to all source.
+C_WARNINGS := -Wpointer-arith -Wredundant-decls
+
+# _no_ common code can have packed data structures or we are in touble.
+C_WARNINGS += -Wpacked
 
 CFLAGS := -m64 -ffreestanding -fno-builtin -fno-common -fno-strict-aliasing
 CFLAGS += -iwithprefix include -Wall -Werror -pipe # -Wpadded
 CFLAGS += -I$(BASEDIR)/include
 CFLAGS += -I$(BASEDIR)/include/asm-ppc/mach-generic
 CFLAGS += -I$(BASEDIR)/include/asm-ppc/mach-default
-CFLAGS += -Wpointer-arith -Wredundant-decls
+CFLAGS += $(C_WARNINGS)
 CFLAGS += -msoft-float -O2
 CFLAGS-$(debug) += -O0 # last one wins
 CFLAGS-$(papr_vterm) += -DPAPR_VDEVICE -DPAPR_VTERM
diff -r ffdf3f94a727 -r cd04c78dd635 xen/arch/ppc/papr/xlate.c
--- a/xen/arch/ppc/papr/xlate.c Fri Jun 30 07:24:53 2006 -0400
+++ b/xen/arch/ppc/papr/xlate.c Fri Jun 30 08:15:04 2006 -0400
@@ -36,7 +36,7 @@ static void not_yet(struct cpu_user_regs
     for (;;);
 }
 
-#if USE_PTE_INSERT
+#ifdef USE_PTE_INSERT
 static inline void pte_insert(union pte volatile *pte,
         ulong vsid, ulong rpn, ulong lrpn)
 {

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


 


Rackspace

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