• T
    ppc/spapr: Use qemu_log_mask() for hcall_dprintf() · aaf87c66
    Thomas Huth 提交于
    To see the output of the hcall_dprintf statements, you currently have
    to enable the DEBUG_SPAPR_HCALLS macro in include/hw/ppc/spapr.h.
    This is ugly because a) not every user who wants to debug guest
    problems can or wants to recompile QEMU to be able to see such issues,
    and b) since this macro is disabled by default, the code in the
    hcall_dprintf() brackets tends to bitrot until somebody temporarily
    enables that macro again.
    Since the hcall_dprintf statements except one indicate guest
    problems, let's always use qemu_log_mask(LOG_GUEST_ERROR, ...) for
    this macro instead. One spot indicated an unimplemented host feature,
    so this is changed into qemu_log_mask(LOG_UNIMP, ...) instead. Now
    it's possible to see all those messages by simply adding the CLI
    parameter "-d guest_errors,unimp", without the need to re-compile
    the binary.
    Signed-off-by: NThomas Huth <thuth@redhat.com>
    Reviewed-by: NDavid Gibson <david@gibson.dropbear.id.au>
    Signed-off-by: NDavid Gibson <david@gibson.dropbear.id.au>
    aaf87c66
spapr_hcall.c 28.2 KB