From 48d50de8e086e6669979889fb58dbf1092d10347 Mon Sep 17 00:00:00 2001 From: Daniel De Graaf Date: Tue, 10 Sep 2013 16:39:46 +0200 Subject: console: buffer and show origin of guest PV writes Guests other than domain 0 using the console output have previously been controlled by the VERBOSE #define, but with no designation of which guest's output was on the console. This patch converts the HVM output buffering to be used by all domains except the hardware domain (dom0): stripping non-printable characters, line buffering the output, and prefixing it with the domain ID. This is especially useful for debugging stub domains during early boot. Signed-off-by: Daniel De Graaf Acked-by: Keir Fraser --- xen/include/xen/sched.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'xen/include/xen/sched.h') diff --git a/xen/include/xen/sched.h b/xen/include/xen/sched.h index ae6a3b843b..0013a8d8ce 100644 --- a/xen/include/xen/sched.h +++ b/xen/include/xen/sched.h @@ -341,6 +341,12 @@ struct domain /* Control-plane tools handle for this domain. */ xen_domain_handle_t handle; + /* hvm_print_line() and guest_console_write() logging. */ +#define DOMAIN_PBUF_SIZE 80 + char *pbuf; + unsigned pbuf_idx; + spinlock_t pbuf_lock; + /* OProfile support. */ struct xenoprof *xenoprof; int32_t time_offset_seconds; -- cgit v1.2.3