diff options
author | Laurent Vivier <laurent@vivier.eu> | 2018-01-18 20:38:46 +0100 |
---|---|---|
committer | Laurent Vivier <laurent@vivier.eu> | 2018-01-25 16:02:25 +0100 |
commit | 2097dca6d3a30b80ac5a6232f518548d5ae644a9 (patch) | |
tree | 281a18487e27d8f35cb4fcafcd3582815bb11862 /target/m68k/monitor.c | |
parent | e55886c3340c3a3f1267a3a3d42082008bb255fb (diff) |
target/m68k: add HMP command "info tlb"
Dump MMU state and address mappings.
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20180118193846.24953-8-laurent@vivier.eu>
Diffstat (limited to 'target/m68k/monitor.c')
-rw-r--r-- | target/m68k/monitor.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/target/m68k/monitor.c b/target/m68k/monitor.c index 486213cd8b..db582a34ac 100644 --- a/target/m68k/monitor.c +++ b/target/m68k/monitor.c @@ -8,6 +8,19 @@ #include "qemu/osdep.h" #include "cpu.h" #include "monitor/hmp-target.h" +#include "monitor/monitor.h" + +void hmp_info_tlb(Monitor *mon, const QDict *qdict) +{ + CPUArchState *env1 = mon_get_cpu_env(); + + if (!env1) { + monitor_printf(mon, "No CPU available\n"); + return; + } + + dump_mmu((FILE *)mon, (fprintf_function)monitor_printf, env1); +} static const MonitorDef monitor_defs[] = { { "d0", offsetof(CPUM68KState, dregs[0]) }, |