diff --git a/util/x86emu/x86emu/debug.c b/util/x86emu/x86emu/debug.c index 0c531eae2b..026c03fddd 100644 --- a/util/x86emu/x86emu/debug.c +++ b/util/x86emu/x86emu/debug.c @@ -46,7 +46,7 @@ static void print_encoded_bytes (u16 s, u16 o); static void print_decoded_instruction (void); -static int parse_line (char *s, int *ps, int *n); +int parse_line (char *s, int *ps, int *n); /* should look something like debug's output. */ void X86EMU_trace_regs (void) @@ -83,7 +83,7 @@ void x86emu_just_disassemble (void) print_decoded_instruction(); } -static void disassemble_forward (u16 seg, u16 off, int n) +void disassemble_forward (u16 seg, u16 off, int n) { X86EMU_sysEnv tregs; int i; @@ -331,7 +331,7 @@ int X86EMU_trace_off(void) return M.x86.debug &= ~(DEBUG_STEP_F | DEBUG_DECODE_F | DEBUG_TRACE_F); } -static int parse_line (char *s, int *ps, int *n) +int parse_line (char *s, int *ps, int *n) { #if 0 int cmd; @@ -359,6 +359,8 @@ static int parse_line (char *s, int *ps, int *n) sscanf(s,"%x",&ps[*n]); *n += 1; } +#else + return 0; #endif } diff --git a/util/x86emu/x86emu/debug.h b/util/x86emu/x86emu/debug.h index 93fa5b008e..f6bab3cf78 100644 --- a/util/x86emu/x86emu/debug.h +++ b/util/x86emu/x86emu/debug.h @@ -41,7 +41,7 @@ #define __X86EMU_DEBUG_H //#define DEBUG 0 -#undef DEBUG +//#undef DEBUG /*---------------------- Macros and type definitions ----------------------*/ /* checks to be enabled for "runtime" */ diff --git a/util/x86emu/x86emu/sys.c b/util/x86emu/x86emu/sys.c index 11247b85bf..b9ca7a8387 100644 --- a/util/x86emu/x86emu/sys.c +++ b/util/x86emu/x86emu/sys.c @@ -69,7 +69,7 @@ u8 *mem_ptr(u32 addr, int size) u8 *retaddr = 0; if (addr > M.mem_size - size) { - DB(printk("mem_ptr: address %#lx out of range!\n", addr);) + DB(printk("mem_ptr: address %#x out of range!\n", addr);) HALT_SYS(); } if (addr < 0x200) {