From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LMryH-000733-9j for qemu-devel@nongnu.org; Tue, 13 Jan 2009 17:42:53 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LMryG-00071z-CO for qemu-devel@nongnu.org; Tue, 13 Jan 2009 17:42:52 -0500 Received: from [199.232.76.173] (port=42396 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LMryG-00071n-3b for qemu-devel@nongnu.org; Tue, 13 Jan 2009 17:42:52 -0500 Received: from mx2.redhat.com ([66.187.237.31]:56413) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LMryE-0003pJ-OD for qemu-devel@nongnu.org; Tue, 13 Jan 2009 17:42:51 -0500 From: Eduardo Habkost Date: Tue, 13 Jan 2009 20:42:28 -0200 Message-Id: <1231886553-4728-1-git-send-email-ehabkost@redhat.com> Subject: [Qemu-devel] [PATCH 0/5] Logging cleanup, take 3 Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Anthony Liguori Cc: qemu-devel@nongnu.org, Eduardo Habkost Hi, Anthony, This is a rebase of the previous logging cleanup patches I've sent. There aren't many changes, except for some manually-solved on target-mips/helper.c. This includes changes from two series I've sent before: the logging #ifdef cleanup and the one that killed references to the loglevel/logfile global variables. There are two large patches on the series because I didn't want to send 94 messages at once to qemu-devel. They are available as series of smaller commits commits if you pull from my git tree, as shown on the pull request below. --- The following changes since commit 291c6ff9bf8cec5f7aa3f0da8895bd65b7d9bf93: aliguori (1): Make virtio_net_init() return void (Mark McLoughlin) are available in the git repository at: git://github.com/ehabkost/qemu-hacks.git log-clean-for-anthony Eduardo Habkost (94): hw/ppc.c: LOG_IRQ macro hw/ppc.c: use LOG_IRQ instead of #ifdefs hw/ppc.c: LOG_TB macro hw/ppc.c: use LOG_TB instead of #ifdefs vl.c: LOG_IOPORT macro vl.c: use LOG_IOPORT instead of #ifdefs kqemu.c: LOG_INT macro kqemu.c: use LOG_INT instead of #ifdefs kqemu.c: LOG_INT_STATE macro kqemu.c: use LOG_INT_STATE instead of #ifdefs kqemu.c: kill remaining DEBUG #ifdefs target-i386/op_helper.c: LOG_PCALL macro target-i386/op_helper.c: LOG_PCALL_STATE macro target-i386/op_helper.c: use LOG_PCALL instead of #ifdefs target-i386/op_helper.c: use LOG_PCALL/LOG_PCALL_STATE target-cris/translate.c: LOG_DIS macro target-cris: replace D(fprintf(logfile, ...)) macros with D_LOG(...) target-mips/translate.c: LOG_DISAS macro target-ppc/helper.c: LOG_MMU macro target-ppc/helper.c: LOG_SWTLB macro target-ppc/helper.c: convert commented-out debug code to LOG_SWTLB target-ppc/helper.c: LOG_BATS macro target-ppc/helper.c: LOG_SLB macro target-ppc/helper.c: LOG_EXCP macro target-ppc/helper.c: remaining LOG_BATS & LOG_MMU conversions target-ppc/helper.c: LOG_MMU_STATE macro target-ppc/op_helper.c: LOG_SWTLB macro target-ppc/translate.c: LOG_DISAS macro hw/ppc4xx_devs.c: LOG_UIC macro target-alpha/translate.c: LOG_DISAS macro linux-user/vm86.c: LOG_VM86 macro Define macros that will become the new logging API target-i386/op_helper.c: qemu_log_mask() replacements target-i386/op_helper.c: simultaneous qemu_log_mask()/log_cpu_state_mask() replacements target-i386/op_helper.c: qemu_log()/log_cpu_state() replacements target-i386/op_helper.c: debug macros: use qemu_log*() target-i386/translate.c: use log_cpu_state_mask() target-i386/translate.c: use qemu_log()/log_target_disas() target-mips/helper.c: use qemu_log()/log_cpu_state() target-mips/helper.c: remaining qemu_log() replacements target-mips/op_helper.c: move loglevel check into debug_pre_eret() target-mips/op_helper.c: move loglevel check into debug_post_eret() target-mips/op_helper.c: qemu_log() replacements target-mips/op_helper.c: remaining qemu_log() replacement target-mips/translate.c: debug macros: use qemu_log_mask() target-mips/translate.c: remaining qemu_log*() conversions hw/mips_timer.c: qemu_log() conversions target-ppc/helper.c: qemu_log() conversions target-ppc/helper.c: qemu_log_mask() conversions target-ppc/helper.c: qemu_log_enabled()/qemu_log() conversions target-ppc/helper.c: move loglevel check into dump_syscall() target-ppc/helper.c: dump_syscall(): use qemu_log_mask() target-ppc/helper.c: debug macros: use qemu_log() target-ppc/helper.c: cpu_dump_rfi(): use qemu_log() target-ppc/op_helper.c: qemu_log() conversions target-ppc/op_helper.c: LOG_SWTLB: use qemu_log() target-ppc/translate.c: qemu_log() conversions target-ppc/translate.c: qemu_log_enabled()/qemu_log() conversions target-ppc/translate.c: LOG_DISAS: use qemu_log_mask() target-ppc/translate.c: remaining qemu_log*() conversions hw/ppc.c: debug macros: use qemu_log*() hw/ppc4xx_devs.c: debug macros: use qemu_log*() target-sparc/op_helper.c: qemu_log*() conversions target-sparc/translate.c: qemu_log*() conversions target-cris/op_helper.c: helper_dump: use qemu_log() target-cris/translate.c: qemu_log*() conversions target-cris/translate.c: LOG_DIS: use qemu_log_mask() target-cris/translate.c: use qemu_log_try_set_file() target-cris/*: D_LOG: use qemu_log() hw/alpha_palcode.c: qemu_log() conversions target-alpha/translate.c: qemu_log*() conversions target-alpha/translate.c: LOG_DISAS: use qemu_log() target-sh4/helper.c: qemu_log*() conversions target-sh4/translate.c: qemu_log_*() conversions target-m68k/translate.c: qemu_log*() conversions target-arm/translate.c: qemu_log*() conversions kqemu.c: LOG_INT: use qemu_log_mask() kqemu.c: LOG_INT_STATE: use log_cpu_state_mask() linux-user/main.c: qemu_log*() conversions linux-user/vm86.c: LOG_VM86: use qemu_log() linux-user/elfload.c: load_elf_binary(): use qemu_log_enabled() bsd-user/main.c: use log_page_dump()/qemu_log() bsd-user/elfload.c: load_elf_binary(): use qemu_log_enabled() darwin-user/main.c: qemu_log*() conversions darwin-user: DPRINTF: use qemu_log() block-raw-posix.c: qemu_log*() conversions translate-all.c: qemu_log*() conversions cpu-exec.c: qemu_log*() conversions exec.c: qemu_log*() conversions exec.c: cpu_abort(): use qemu_log_close() tcg.c: qemu_log() conversions vl.c: LOG_IOPORT: use qemu_log_mask() global s/fflush(logfile)/qemu_log_flush()/ global s/loglevel & X/qemu_loglevel_mask(X)/ block-raw-posix.c | 4 +- bsd-user/elfload.c | 2 +- bsd-user/main.c | 28 ++-- cpu-exec.c | 35 ++--- darwin-user/commpage.c | 4 +- darwin-user/machload.c | 4 +- darwin-user/main.c | 6 +- darwin-user/syscall.c | 4 +- exec.c | 26 ++-- hw/alpha_palcode.c | 15 +-- hw/mips_timer.c | 4 +- hw/ppc.c | 307 ++++++++------------------------------ hw/ppc4xx_devs.c | 55 ++----- hw/ppc_prep.c | 11 +- kqemu.c | 70 +++------ linux-user/elfload.c | 2 +- linux-user/main.c | 34 ++--- linux-user/vm86.c | 39 ++--- qemu-log.h | 86 +++++++++++ target-alpha/translate.c | 37 ++--- target-arm/translate.c | 10 +- target-cris/helper.c | 26 +++- target-cris/mmu.c | 12 +- target-cris/op_helper.c | 28 +++-- target-cris/translate.c | 309 +++++++++++++++++++------------------- target-i386/op_helper.c | 120 ++++++--------- target-i386/translate.c | 24 ++-- target-m68k/translate.c | 12 +- target-mips/helper.c | 40 ++--- target-mips/op_helper.c | 68 ++++---- target-mips/translate.c | 147 ++++-------------- target-ppc/helper.c | 378 ++++++++++++++-------------------------------- target-ppc/op_helper.c | 89 +++-------- target-ppc/translate.c | 73 ++++------ target-sh4/helper.c | 8 +- target-sh4/translate.c | 19 +-- target-sparc/op_helper.c | 24 ++-- target-sparc/translate.c | 19 +-- tcg/tcg.c | 12 +- translate-all.c | 10 +- vl.c | 37 ++--- 41 files changed, 857 insertions(+), 1381 deletions(-) -- Eduardo