qemu-patch-raspberry4/target/sparc
Markus Armbruster fad866daa8 target: Clean up how the dump_mmu() print
The various dump_mmu() take an fprintf()-like callback and a FILE * to
pass to it, and so do their helper functions.  Passing around callback
and argument is rather tiresome.

Most dump_mmu() are called only by the target's hmp_info_tlb().  These
all pass monitor_printf() cast to fprintf_function and the current
monitor cast to FILE *.

SPARC's dump_mmu() gets also called from target/sparc/ldst_helper.c a
few times #ifdef DEBUG_MMU.  These calls pass fprintf() and stdout.

The type-punning is technically undefined behaviour, but works in
practice.  Clean up: drop the callback, and call qemu_printf()
instead.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Message-Id: <20190417191805.28198-11-armbru@redhat.com>
2019-04-18 22:18:59 +02:00
..
asi.h target-sparc: implement UA2005 scratchpad registers 2017-01-18 22:03:44 +01:00
cc_helper.c Move target-* CPU file into a target/ folder 2016-12-20 21:52:12 +01:00
cpu-qom.h sparc: convert cpu models to SPARC cpu subclasses 2017-09-01 11:54:24 -03:00
cpu.c target: Simplify how the TARGET_cpu_list() print 2019-04-18 22:18:59 +02:00
cpu.h target: Clean up how the dump_mmu() print 2019-04-18 22:18:59 +02:00
fop_helper.c target/*/cpu.h: remove softfloat.h 2018-02-21 10:20:24 +00:00
gdbstub.c Move target-* CPU file into a target/ folder 2016-12-20 21:52:12 +01:00
helper.c linux-user: SPARC "rd %tick" can be used by user application 2018-06-04 01:30:43 +02:00
helper.h target-sparc: implement UA2005 GL register 2017-01-18 22:03:44 +01:00
int32_helper.c sparc: embed sparc_def_t into CPUSPARCState 2017-09-01 11:54:24 -03:00
int64_helper.c sparc: embed sparc_def_t into CPUSPARCState 2017-09-01 11:54:24 -03:00
ldst_helper.c target: Clean up how the dump_mmu() print 2019-04-18 22:18:59 +02:00
machine.c vmstate: constify VMStateField 2018-11-27 15:35:15 +01:00
Makefile.objs Move target-* CPU file into a target/ folder 2016-12-20 21:52:12 +01:00
mmu_helper.c target: Clean up how the dump_mmu() print 2019-04-18 22:18:59 +02:00
monitor.c target: Clean up how the dump_mmu() print 2019-04-18 22:18:59 +02:00
TODO Move target-* CPU file into a target/ folder 2016-12-20 21:52:12 +01:00
trace-events trace-events: Shorten file names in comments 2019-03-22 16:18:07 +00:00
translate.c SPARC64: add icount support 2018-06-17 11:13:06 +01:00
vis_helper.c Move target-* CPU file into a target/ folder 2016-12-20 21:52:12 +01:00
win_helper.c sparc: embed sparc_def_t into CPUSPARCState 2017-09-01 11:54:24 -03:00