Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/cherry-xenmp]: src/sys/arch/xen Unbreak uniprocessor build
details: https://anonhg.NetBSD.org/src/rev/ce21bcde0f1f
branches: cherry-xenmp
changeset: 765614:ce21bcde0f1f
user: cherry <cherry%NetBSD.org@localhost>
date: Sun Jun 26 12:56:32 2011 +0000
description:
Unbreak uniprocessor build
diffstat:
sys/arch/xen/include/intr.h | 8 +++++++-
sys/arch/xen/xen/hypervisor.c | 23 ++++++++++++-----------
2 files changed, 19 insertions(+), 12 deletions(-)
diffs (97 lines):
diff -r 672a21ed5c98 -r ce21bcde0f1f sys/arch/xen/include/intr.h
--- a/sys/arch/xen/include/intr.h Thu Jun 23 14:17:47 2011 +0000
+++ b/sys/arch/xen/include/intr.h Sun Jun 26 12:56:32 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: intr.h,v 1.31.10.1 2011/06/03 13:27:40 cherry Exp $ */
+/* $NetBSD: intr.h,v 1.31.10.2 2011/06/26 12:56:32 cherry Exp $ */
/* NetBSD intr.h,v 1.15 2004/10/31 10:39:34 yamt Exp */
/*-
@@ -185,9 +185,15 @@
struct pic *intr_findpic(int);
void intr_add_pcibus(struct pcibus_attach_args *);
+#ifdef MULTIPROCESSOR
void xen_ipi_init(void);
int xen_send_ipi(struct cpu_info *, uint32_t);
void xen_broadcast_ipi(uint32_t);
+#else
+#define xen_ipi_init(_1) do {} while(0) /* nothing */
+#define xen_send_ipi(_i1, _i2) do {} while(0) /* nothing */
+#define xen_broadcast_ipi(_i1) do {} while(0) /* nothing */
+#endif /* MULTIPROCESSOR */
#endif /* !_LOCORE */
diff -r 672a21ed5c98 -r ce21bcde0f1f sys/arch/xen/xen/hypervisor.c
--- a/sys/arch/xen/xen/hypervisor.c Thu Jun 23 14:17:47 2011 +0000
+++ b/sys/arch/xen/xen/hypervisor.c Sun Jun 26 12:56:32 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: hypervisor.c,v 1.55.2.1 2011/06/03 13:27:42 cherry Exp $ */
+/* $NetBSD: hypervisor.c,v 1.55.2.2 2011/06/26 12:56:33 cherry Exp $ */
/*
* Copyright (c) 2005 Manuel Bouyer.
@@ -53,7 +53,7 @@
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: hypervisor.c,v 1.55.2.1 2011/06/03 13:27:42 cherry Exp $");
+__KERNEL_RCSID(0, "$NetBSD: hypervisor.c,v 1.55.2.2 2011/06/26 12:56:33 cherry Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -128,7 +128,6 @@
hypervisor_match, hypervisor_attach, NULL, NULL);
static int hypervisor_print(void *, const char *);
-static int hypervisor_vcpu_print(void *, const char *);
union hypervisor_attach_cookie {
const char *hac_device; /* first elem of all */
@@ -183,6 +182,15 @@
return 0;
}
+#ifdef MULTIPROCESSOR
+static int
+hypervisor_vcpu_print(void *aux, const char *parent)
+{
+ /* Unconfigured cpus are ignored quietly. */
+ return (QUIET);
+}
+#endif /* MULTIPROCESSOR */
+
/*
* Attach the hypervisor.
*/
@@ -190,7 +198,6 @@
hypervisor_attach(device_t parent, device_t self, void *aux)
{
int xen_version;
- cpuid_t vcpuid;
#if NPCI >0
#ifdef PCI_BUS_FIXUP
@@ -226,6 +233,7 @@
* allocated vcpus (See: cpu.c:vcpu_match()) by iterating
* through the maximum supported by NetBSD MP.
*/
+ cpuid_t vcpuid;
for (vcpuid = 1; vcpuid < maxcpus; vcpuid++) {
memset(&hac, 0, sizeof(hac));
@@ -331,13 +339,6 @@
return (UNCONF);
}
-static int
-hypervisor_vcpu_print(void *aux, const char *parent)
-{
- /* Unconfigured cpus are ignored quietly. */
- return (QUIET);
-}
-
#if defined(DOM0OPS)
#define DIR_MODE (S_IRUSR|S_IXUSR|S_IRGRP|S_IXGRP|S_IROTH|S_IXOTH)
Home |
Main Index |
Thread Index |
Old Index