Module Name: src Committed By: mrg Date: Sun Nov 3 22:27:27 UTC 2013
Modified Files: src/sys/arch/powerpc/oea: cpu_subr.c oea_machdep.c ofwoea_machdep.c Log Message: - remove set but unused variables - move some variables inside their relevant use #ifdef To generate a diff of this commit: cvs rdiff -u -r1.79 -r1.80 src/sys/arch/powerpc/oea/cpu_subr.c cvs rdiff -u -r1.67 -r1.68 src/sys/arch/powerpc/oea/oea_machdep.c cvs rdiff -u -r1.34 -r1.35 src/sys/arch/powerpc/oea/ofwoea_machdep.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/arch/powerpc/oea/cpu_subr.c diff -u src/sys/arch/powerpc/oea/cpu_subr.c:1.79 src/sys/arch/powerpc/oea/cpu_subr.c:1.80 --- src/sys/arch/powerpc/oea/cpu_subr.c:1.79 Sun Sep 22 18:56:11 2013 +++ src/sys/arch/powerpc/oea/cpu_subr.c Sun Nov 3 22:27:27 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: cpu_subr.c,v 1.79 2013/09/22 18:56:11 matt Exp $ */ +/* $NetBSD: cpu_subr.c,v 1.80 2013/11/03 22:27:27 mrg Exp $ */ /*- * Copyright (c) 2001 Matt Thomas. @@ -34,7 +34,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: cpu_subr.c,v 1.79 2013/09/22 18:56:11 matt Exp $"); +__KERNEL_RCSID(0, "$NetBSD: cpu_subr.c,v 1.80 2013/11/03 22:27:27 mrg Exp $"); #include "opt_ppcparam.h" #include "opt_ppccache.h" @@ -747,7 +747,6 @@ cpu_identify(char *str, size_t len) u_int pvr, major, minor; uint16_t vers, rev, revfmt; const struct cputab *cp; - const char *name; size_t n; pvr = mfpvr(); @@ -780,9 +779,7 @@ cpu_identify(char *str, size_t len) } revfmt = cp->revfmt; - name = cp->name; if (rev == MPC750 && pvr == 15) { - name = "755"; revfmt = REVFMT_HEX; } Index: src/sys/arch/powerpc/oea/oea_machdep.c diff -u src/sys/arch/powerpc/oea/oea_machdep.c:1.67 src/sys/arch/powerpc/oea/oea_machdep.c:1.68 --- src/sys/arch/powerpc/oea/oea_machdep.c:1.67 Sat Aug 31 15:01:08 2013 +++ src/sys/arch/powerpc/oea/oea_machdep.c Sun Nov 3 22:27:27 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: oea_machdep.c,v 1.67 2013/08/31 15:01:08 matt Exp $ */ +/* $NetBSD: oea_machdep.c,v 1.68 2013/11/03 22:27:27 mrg Exp $ */ /* * Copyright (C) 2002 Matt Thomas @@ -33,7 +33,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: oea_machdep.c,v 1.67 2013/08/31 15:01:08 matt Exp $"); +__KERNEL_RCSID(0, "$NetBSD: oea_machdep.c,v 1.68 2013/11/03 22:27:27 mrg Exp $"); #include "opt_ppcarch.h" #include "opt_compat_netbsd.h" @@ -656,11 +656,13 @@ void oea_batinit(paddr_t pa, ...) { struct mem_region *allmem, *availmem, *mp; - unsigned int cpuvers; register_t msr = mfmsr(); va_list ap; +#ifdef PPC_OEA601 + unsigned int cpuvers; cpuvers = mfpvr() >> 16; +#endif /* PPC_OEA601 */ /* * we need to call this before zapping BATs so OF calls work Index: src/sys/arch/powerpc/oea/ofwoea_machdep.c diff -u src/sys/arch/powerpc/oea/ofwoea_machdep.c:1.34 src/sys/arch/powerpc/oea/ofwoea_machdep.c:1.35 --- src/sys/arch/powerpc/oea/ofwoea_machdep.c:1.34 Sat Aug 31 07:33:15 2013 +++ src/sys/arch/powerpc/oea/ofwoea_machdep.c Sun Nov 3 22:27:27 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: ofwoea_machdep.c,v 1.34 2013/08/31 07:33:15 matt Exp $ */ +/* $NetBSD: ofwoea_machdep.c,v 1.35 2013/11/03 22:27:27 mrg Exp $ */ /*- * Copyright (c) 2007 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: ofwoea_machdep.c,v 1.34 2013/08/31 07:33:15 matt Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ofwoea_machdep.c,v 1.35 2013/11/03 22:27:27 mrg Exp $"); #include "opt_ppcarch.h" #include "opt_compat_netbsd.h" @@ -623,7 +623,6 @@ ofwoea_map_space(int rangetype, int iome { int i, cur, range, nrofholes, error; static int exmap=0; - u_int32_t addr; rangemap_t region, holes[32], list[32]; memset(list, 0, sizeof(list)); @@ -697,7 +696,6 @@ ofwoea_map_space(int rangetype, int iome DPRINTF("addr=0x%x size=0x%x type=%d\n", list[i].addr, list[i].size, list[i].type); - addr=0; range = find_lowest_range(list, cur, iomem); i = 0; nrofholes = 0;