[PATCH] ppc64: fix some compiler warnings

Anton Blanchard anton at samba.org
Tue Jan 4 16:07:27 EST 2005


Fix some compiler warnings:

- The first two are spurious gcc warnings, but quieten them up regardless
- Add a missing include
- Use register_sysrq_key instead of __sysrq_put_key_op

Signed-off-by: Anton Blanchard <anton at samba.org>

diff -puN arch/ppc64/mm/hash_native.c~remove_compiler_warnings arch/ppc64/mm/hash_native.c
--- gr_work/arch/ppc64/mm/hash_native.c~remove_compiler_warnings	2004-12-25 21:44:00.112288718 -0600
+++ gr_work-anton/arch/ppc64/mm/hash_native.c	2004-12-25 21:44:35.782093438 -0600
@@ -242,7 +242,7 @@ static long native_hpte_updatepp(unsigne
  */
 static void native_hpte_updateboltedpp(unsigned long newpp, unsigned long ea)
 {
-	unsigned long vsid, va, vpn, flags;
+	unsigned long vsid, va, vpn, flags = 0;
 	long slot;
 	HPTE *hptep;
 	int lock_tlbie = !(cur_cpu_spec->cpu_features & CPU_FTR_LOCKLESS_TLBIE);
diff -puN arch/ppc64/kernel/pSeries_lpar.c~remove_compiler_warnings arch/ppc64/kernel/pSeries_lpar.c
--- gr_work/arch/ppc64/kernel/pSeries_lpar.c~remove_compiler_warnings	2004-12-25 21:44:48.291973925 -0600
+++ gr_work-anton/arch/ppc64/kernel/pSeries_lpar.c	2004-12-25 21:45:08.829912888 -0600
@@ -504,7 +504,7 @@ void pSeries_lpar_flush_hash_range(unsig
 				   int local)
 {
 	int i;
-	unsigned long flags;
+	unsigned long flags = 0;
 	struct ppc64_tlb_batch *batch = &__get_cpu_var(ppc64_tlb_batch);
 	int lock_tlbie = !(cur_cpu_spec->cpu_features & CPU_FTR_LOCKLESS_TLBIE);
 
diff -puN arch/ppc64/kernel/pSeries_setup.c~remove_compiler_warnings arch/ppc64/kernel/pSeries_setup.c
--- gr_work/arch/ppc64/kernel/pSeries_setup.c~remove_compiler_warnings	2004-12-25 21:46:35.016298826 -0600
+++ gr_work-anton/arch/ppc64/kernel/pSeries_setup.c	2004-12-25 21:47:05.188173311 -0600
@@ -59,6 +59,7 @@
 #include <asm/naca.h>
 #include <asm/time.h>
 #include <asm/nvram.h>
+#include <asm/plpar_wrappers.h>
 
 #include "i8259.h"
 #include <asm/xics.h>
diff -puN arch/ppc64/xmon/start.c~remove_compiler_warnings arch/ppc64/xmon/start.c
--- gr_work/arch/ppc64/xmon/start.c~remove_compiler_warnings	2004-12-25 21:48:27.578625901 -0600
+++ gr_work-anton/arch/ppc64/xmon/start.c	2004-12-25 21:48:55.121385858 -0600
@@ -40,7 +40,7 @@ static struct sysrq_key_op sysrq_xmon_op
 
 static int __init setup_xmon_sysrq(void)
 {
-	__sysrq_put_key_op('x', &sysrq_xmon_op);
+	register_sysrq_key('x', &sysrq_xmon_op);
 	return 0;
 }
 __initcall(setup_xmon_sysrq);
_



More information about the Linuxppc64-dev mailing list