Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/ofppc/ofppc Make it compile with GCC48.
details: https://anonhg.NetBSD.org/src/rev/5be6a09dcfe7
branches: trunk
changeset: 335253:5be6a09dcfe7
user: phx <phx%NetBSD.org@localhost>
date: Wed Dec 31 18:43:18 2014 +0000
description:
Make it compile with GCC48.
diffstat:
sys/arch/ofppc/ofppc/mainbus.c | 16 ++++++++++------
1 files changed, 10 insertions(+), 6 deletions(-)
diffs (55 lines):
diff -r 8fc3776c1577 -r 5be6a09dcfe7 sys/arch/ofppc/ofppc/mainbus.c
--- a/sys/arch/ofppc/ofppc/mainbus.c Wed Dec 31 18:19:21 2014 +0000
+++ b/sys/arch/ofppc/ofppc/mainbus.c Wed Dec 31 18:43:18 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: mainbus.c,v 1.29 2013/04/21 15:42:11 kiyohara Exp $ */
+/* $NetBSD: mainbus.c,v 1.30 2014/12/31 18:43:18 phx Exp $ */
/*-
* Copyright (c) 2007 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: mainbus.c,v 1.29 2013/04/21 15:42:11 kiyohara Exp $");
+__KERNEL_RCSID(0, "$NetBSD: mainbus.c,v 1.30 2014/12/31 18:43:18 phx Exp $");
#include "opt_interrupt.h"
#include "opt_multiprocessor.h"
@@ -100,10 +100,15 @@
uint32_t pci_hi, pci_mid, pci_lo;
uint32_t host;
uint32_t size_hi, size_lo;
- } ranges[6], *rp = ranges;
- unsigned char *baseaddr = NULL;
+ } ranges[6];
uint32_t reg[12];
int parent, len;
+#if defined(PIC_OPENPIC) || defined(PIC_DISTOPENPIC)
+ unsigned char *baseaddr;
+#endif
+#ifdef PIC_OPENPIC
+ struct ranges *rp = ranges;
+#endif
#ifdef PIC_DISTOPENPIC
unsigned char *isu[OPENPIC_MAX_ISUS];
int i, j;
@@ -144,7 +149,6 @@
len -= sizeof(ranges[0]);
}
#endif
- rp = 0; /* satisfy -Wall */
return FALSE;
noaadr:
/* this isn't a PCI-attached openpic */
@@ -153,9 +157,9 @@
return FALSE;
if (len == sizeof(int)*2) {
- baseaddr = (unsigned char *)mapiodev(reg[0], reg[1], false);
aprint_verbose("Found openpic at %08x\n", reg[0]);
#ifdef PIC_OPENPIC
+ baseaddr = (unsigned char *)mapiodev(reg[0], reg[1], false);
(void)setup_openpic(baseaddr, 0);
#ifdef MULTIPROCESSOR
setup_openpic_ipi();
Home |
Main Index |
Thread Index |
Old Index