Module Name: src
Committed By: maxv
Date: Thu Jul 26 15:38:26 UTC 2018
Modified Files:
src/sys/arch/xen/conf: files.xen
src/sys/arch/xen/include: xen.h
src/sys/arch/xen/xen: xen_machdep.c
Removed Files:
src/sys/arch/xen/xen: xen_debug.c
Log Message:
Merge the content of xen_debug.c into xen_machdep.c, there is only one
function.
To generate a diff of this commit:
cvs rdiff -u -r1.169 -r1.170 src/sys/arch/xen/conf/files.xen
cvs rdiff -u -r1.38 -r1.39 src/sys/arch/xen/include/xen.h
cvs rdiff -u -r1.10 -r0 src/sys/arch/xen/xen/xen_debug.c
cvs rdiff -u -r1.18 -r1.19 src/sys/arch/xen/xen/xen_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/xen/conf/files.xen
diff -u src/sys/arch/xen/conf/files.xen:1.169 src/sys/arch/xen/conf/files.xen:1.170
--- src/sys/arch/xen/conf/files.xen:1.169 Wed May 23 07:45:35 2018
+++ src/sys/arch/xen/conf/files.xen Thu Jul 26 15:38:26 2018
@@ -1,4 +1,4 @@
-# $NetBSD: files.xen,v 1.169 2018/05/23 07:45:35 maxv Exp $
+# $NetBSD: files.xen,v 1.170 2018/07/26 15:38:26 maxv Exp $
# NetBSD: files.x86,v 1.10 2003/10/08 17:30:00 bouyer Exp
# NetBSD: files.i386,v 1.254 2004/03/25 23:32:10 jmc Exp
@@ -98,7 +98,6 @@ file arch/x86/x86/compat_60_cpu_ucode.c
file arch/xen/xen/xen_machdep.c
-file arch/xen/xen/xen_debug.c
file arch/xen/xen/clock.c
file arch/x86/isa/rtc.c dom0ops
Index: src/sys/arch/xen/include/xen.h
diff -u src/sys/arch/xen/include/xen.h:1.38 src/sys/arch/xen/include/xen.h:1.39
--- src/sys/arch/xen/include/xen.h:1.38 Thu Jul 26 15:26:10 2018
+++ src/sys/arch/xen/include/xen.h Thu Jul 26 15:38:26 2018
@@ -1,4 +1,4 @@
-/* $NetBSD: xen.h,v 1.38 2018/07/26 15:26:10 maxv Exp $ */
+/* $NetBSD: xen.h,v 1.39 2018/07/26 15:38:26 maxv Exp $ */
/*
*
@@ -75,11 +75,8 @@ void idle_block(void);
/* xen_machdep.c */
void sysctl_xen_suspend_setup(void);
-#if defined(XENDEBUG) || 1 /* XXX */
#include <sys/stdarg.h>
-
void printk(const char *, ...);
-#endif
#endif
Index: src/sys/arch/xen/xen/xen_machdep.c
diff -u src/sys/arch/xen/xen/xen_machdep.c:1.18 src/sys/arch/xen/xen/xen_machdep.c:1.19
--- src/sys/arch/xen/xen/xen_machdep.c:1.18 Sat Jun 30 20:53:30 2018
+++ src/sys/arch/xen/xen/xen_machdep.c Thu Jul 26 15:38:26 2018
@@ -1,4 +1,4 @@
-/* $NetBSD: xen_machdep.c,v 1.18 2018/06/30 20:53:30 kre Exp $ */
+/* $NetBSD: xen_machdep.c,v 1.19 2018/07/26 15:38:26 maxv Exp $ */
/*
* Copyright (c) 2006 Manuel Bouyer.
@@ -53,7 +53,7 @@
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: xen_machdep.c,v 1.18 2018/06/30 20:53:30 kre Exp $");
+__KERNEL_RCSID(0, "$NetBSD: xen_machdep.c,v 1.19 2018/07/26 15:38:26 maxv Exp $");
#include "opt_xen.h"
@@ -420,6 +420,21 @@ xen_suspend_domain(void)
}
+#define PRINTK_BUFSIZE 1024
+void
+printk(const char *fmt, ...)
+{
+ va_list ap;
+ int ret;
+ static char buf[PRINTK_BUFSIZE];
+
+ va_start(ap, fmt);
+ ret = vsnprintf(buf, PRINTK_BUFSIZE - 1, fmt, ap);
+ va_end(ap);
+ buf[ret] = 0;
+ (void)HYPERVISOR_console_io(CONSOLEIO_write, ret, buf);
+}
+
bool xen_feature_tables[XENFEAT_NR_SUBMAPS * 32];
void