# HG changeset patch
# User kfraser@xxxxxxxxxxxxxxxxxxxxx
# Node ID bec95280b565d0e9d6a58480ed17b0963f180e1b
# Parent 36fe7ca48e540da74c035fd56f99941ffd36e086
[XEN] Quieten down HVM debug output.
Signed-off-by: Keir Fraser <keir@xxxxxxxxxxxxx>
---
xen/arch/x86/hvm/vlapic.c | 2 +-
xen/arch/x86/x86_emulate.c | 40 +++++++++++-----------------------------
2 files changed, 12 insertions(+), 30 deletions(-)
diff -r 36fe7ca48e54 -r bec95280b565 xen/arch/x86/hvm/vlapic.c
--- a/xen/arch/x86/hvm/vlapic.c Fri Dec 01 11:32:32 2006 +0000
+++ b/xen/arch/x86/hvm/vlapic.c Fri Dec 01 11:54:53 2006 +0000
@@ -723,7 +723,7 @@ static void vlapic_write(struct vcpu *v,
break;
default:
- gdprintk(XENLOG_WARNING,
+ gdprintk(XENLOG_DEBUG,
"Local APIC Write to read-only register 0x%x\n", offset);
break;
}
diff -r 36fe7ca48e54 -r bec95280b565 xen/arch/x86/x86_emulate.c
--- a/xen/arch/x86/x86_emulate.c Fri Dec 01 11:32:32 2006 +0000
+++ b/xen/arch/x86/x86_emulate.c Fri Dec 01 11:54:53 2006 +0000
@@ -7,16 +7,14 @@
*/
#ifndef __XEN__
-#include <stdio.h>
+#include <stddef.h>
#include <stdint.h>
#include <public/xen.h>
-#define dprintf(_f, _a...) printf( _f , ## _a )
#else
#include <xen/config.h>
#include <xen/types.h>
#include <xen/lib.h>
#include <asm/regs.h>
-#define dprintf(_f, _a...) gdprintk(XENLOG_WARNING, _f , ## _a )
#undef cmpxchg
#endif
#include <asm-x86/x86_emulate.h>
@@ -440,27 +438,6 @@ decode_register(
return p;
}
-static void
-dump_instr(
- struct x86_emulate_ctxt *ctxt,
- struct x86_emulate_ops *ops)
-{
-#ifdef __XEN__
- int i;
- unsigned long x, eip = ctxt->regs->eip;
-
- dprintf("Instr:");
- for ( i = 0; i < 16; i++, eip++ )
- {
- if ( ops->read(x86_seg_cs, eip, &x, 1, ctxt) != 0 )
- printk(" ??");
- else
- printk(" %02x", (uint8_t)x);
- }
- printk("\n");
-#endif
-}
-
int
x86_emulate_memop(
struct x86_emulate_ctxt *ctxt,
@@ -579,10 +556,7 @@ x86_emulate_memop(
modrm_rm = modrm & 0x07;
if ( modrm_mod == 3 )
- {
- dprintf("Cannot parse ModRM.mod == 3.\n");
goto cannot_emulate;
- }
if ( ad_bytes == 2 )
{
@@ -1206,7 +1180,15 @@ x86_emulate_memop(
goto writeback;
cannot_emulate:
- dprintf("Cannot emulate %02x\n", b);
- dump_instr(ctxt, ops);
+#ifdef __XEN__
+ gdprintk(XENLOG_DEBUG, "Instr:");
+ for ( ea_off = ctxt->regs->eip; ea_off < _regs.eip; ea_off++ )
+ {
+ unsigned long x;
+ ops->read(x86_seg_cs, ea_off, &x, 1, ctxt);
+ printk(" %02x", (uint8_t)x);
+ }
+ printk("\n");
+#endif
return -1;
}
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|