]> Git Repo - qemu.git/commit - hw/core/cpu.c
qom/cpu: Simplify how CPUClass::dump_statistics() prints
authorMarkus Armbruster <[email protected]>
Wed, 17 Apr 2019 19:18:00 +0000 (21:18 +0200)
committerMarkus Armbruster <[email protected]>
Thu, 18 Apr 2019 20:18:59 +0000 (22:18 +0200)
commit11cb6c152a52fdda6a7f5a8bb271344aaf0c2b98
tree40fc2a77e515f2cb6f55bdf50305b1befeee6ad6
parentd3fd9e4b79f77afea17213a7b32ba9eda7fc59c1
qom/cpu: Simplify how CPUClass::dump_statistics() prints

CPUClass method dump_statistics() takes an fprintf()-like callback and
a FILE * to pass to it.

Its only caller hmp_info_cpustats() (via cpu_dump_statistics()) passes
monitor_fprintf() and the current monitor cast to FILE *.
monitor_fprintf() casts it right back, and is otherwise identical to
monitor_printf().  The type-punning is ugly.

Drop the callback, and call qemu_printf() instead.

Signed-off-by: Markus Armbruster <[email protected]>
Reviewed-by: Dr. David Alan Gilbert <[email protected]>
Message-Id: <20190417191805[email protected]>
include/qom/cpu.h
monitor.c
qom/cpu.c
target/ppc/cpu.h
target/ppc/translate.c
This page took 0.02773 seconds and 4 git commands to generate.