Skip to content
Snippets Groups Projects
  1. Jun 12, 2019
    • Markus Armbruster's avatar
      Include qemu-common.h exactly where needed · a8d25326
      Markus Armbruster authored
      
      No header includes qemu-common.h after this commit, as prescribed by
      qemu-common.h's file comment.
      
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Message-Id: <20190523143508.25387-5-armbru@redhat.com>
      [Rebased with conflicts resolved automatically, except for
      include/hw/arm/xlnx-zynqmp.h hw/arm/nrf51_soc.c hw/arm/msf2-soc.c
      block/qcow2-refcount.c block/qcow2-cluster.c block/qcow2-cache.c
      target/arm/cpu.h target/lm32/cpu.h target/m68k/cpu.h target/mips/cpu.h
      target/moxie/cpu.h target/nios2/cpu.h target/openrisc/cpu.h
      target/riscv/cpu.h target/tilegx/cpu.h target/tricore/cpu.h
      target/unicore32/cpu.h target/xtensa/cpu.h; bsd-user/main.c and
      net/tap-bsd.c fixed up]
      a8d25326
  2. May 15, 2018
  3. Feb 23, 2017
  4. Sep 14, 2016
    • Daniel P. Berrangé's avatar
      log: fix parsing of multiple trace:PATTERN log args · 89d0a64f
      Daniel P. Berrangé authored
      
      If giving QEMU a log arg which asks to enable multiple
      different trace event patterns such as
      
        $QEMU -d trace:qio*,trace:qcrypto*
      
      the parser will then invoke
      
        trace_enable_events("qio*,trace:qcrypto*")
        trace_enable_events("qcrypto*")
      
      as when finding a 'trace:' prefix, it is not clever
      enough to strip anything after the next comma. As
      a result only the last 'trace:' match ever works.
      
      Rather than trying to be more clever with parsing the
      command line arg in place, simplify the code by
      using g_strsplit to break it into individual strings
      on ','. These resulting pieces can be directly used
      without worrying about trailing data from the next
      option.
      
      Signed-off-by: default avatarDaniel P. Berrange <berrange@redhat.com>
      Message-Id: <1473186343-16704-1-git-send-email-berrange@redhat.com>
      Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      89d0a64f
  5. Aug 05, 2016
  6. Jul 04, 2016
  7. Jun 20, 2016
    • Markus Armbruster's avatar
      log: Fix qemu_set_log_filename() error handling · daa76aa4
      Markus Armbruster authored
      
      When qemu_set_log_filename() detects an invalid file name, it reports
      an error, closes the log file (if any), and starts logging to stderr
      (unless daemonized or nothing is being logged).
      
      This is wrong.  Asking for an invalid log file on the command line
      should be fatal.  Asking for one in the monitor should fail without
      messing up an existing logfile.
      
      Fix by converting qemu_set_log_filename() to Error.  Pass it
      &error_fatal, except for hmp_logfile report errors.
      
      This also permits testing without a subprocess, so do that.
      
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Message-Id: <1466011636-6112-4-git-send-email-armbru@redhat.com>
      Reviewed-by: default avatarEric Blake <eblake@redhat.com>
      daa76aa4
    • Markus Armbruster's avatar
      log: Fix qemu_set_dfilter_ranges() error reporting · bd6fee9f
      Markus Armbruster authored
      
      g_error() is not an acceptable way to report errors to the user:
      
          $ qemu-system-x86_64 -dfilter 1000+0
      
          ** (process:17187): ERROR **: Failed to parse range in: 1000+0
          Trace/breakpoint trap (core dumped)
      
      g_assert() isn't, either:
      
          $ qemu-system-x86_64 -dfilter 1000x+64
          **
          ERROR:/work/armbru/qemu/util/log.c:180:qemu_set_dfilter_ranges: assertion failed: (e == range_op)
          Aborted (core dumped)
      
      Convert qemu_set_dfilter_ranges() to Error.  Rework its deeply nested
      control flow.  Touch up the error messages.  Call it with
      &error_fatal.
      
      This also permits testing without a subprocess, so do that.
      
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Message-Id: <1466011636-6112-3-git-send-email-armbru@redhat.com>
      Reviewed-by: default avatarEric Blake <eblake@redhat.com>
      bd6fee9f
    • Markus Armbruster's avatar
      log: Plug memory leak on multiple -dfilter · 2ec62fae
      Markus Armbruster authored
      
      -dfilter overwrites any previous filter.  The overwritten filter is
      leaked.  Leaks since the beginning (commit 3514552e, v2.6.0).  Free it
      properly.
      
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Message-Id: <1466011636-6112-2-git-send-email-armbru@redhat.com>
      Reviewed-by: default avatarEric Blake <eblake@redhat.com>
      2ec62fae
  8. May 19, 2016
  9. Mar 31, 2016
  10. Mar 22, 2016
  11. Mar 07, 2016
    • Paolo Bonzini's avatar
      log: do not log if QEMU is daemonized but without -D · c586eac3
      Paolo Bonzini authored
      
      Commit 96c33a45 ("log: Redirect stderr to logfile if deamonized",
      2016-02-22) wanted to move stderr of a daemonized QEMU to the file
      specified with -D.
      
      However, if -D was not passed, the patch had the side effect of not
      redirecting stderr to /dev/null.  This happened because qemu_logfile
      was set to stderr rather than the expected value of NULL.  The fix
      is simply in the "if" condition of do_qemu_set_log; the "if" for
      closing the file is also changed to match.
      
      Reported-by: default avatarJan Tomko <jtomko@redhat.com>
      Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      c586eac3
  12. Feb 22, 2016
  13. Feb 04, 2016
    • Peter Maydell's avatar
      all: Clean up includes · d38ea87a
      Peter Maydell authored
      
      Clean up includes so that osdep.h is included first and headers
      which it implies are not included manually.
      
      This commit was created with scripts/clean-includes.
      
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      Message-id: 1454089805-5470-16-git-send-email-peter.maydell@linaro.org
      d38ea87a
  14. Feb 03, 2016
  15. Dec 17, 2015
  16. Nov 04, 2015
  17. Oct 19, 2015
  18. Feb 10, 2015
  19. Dec 16, 2014
    • Antony Pavlov's avatar
      qemu-log: add log category for MMU info · 339aaf5b
      Antony Pavlov authored
      
      Running barebox on qemu-system-mips* with '-d unimp' overloads
      stderr by very very many mips_cpu_handle_mmu_fault() messages:
      
        mips_cpu_handle_mmu_fault address=b80003fd ret 0 physical 00000000180003fd prot 3
        mips_cpu_handle_mmu_fault address=a0800884 ret 0 physical 0000000000800884 prot 3
        mips_cpu_handle_mmu_fault pc a080cd80 ad b80003fd rw 0 mmu_idx 0
      
      So it's very difficult to find LOG_UNIMP message.
      
      The mips_cpu_handle_mmu_fault() messages appear on enabling ANY
      logging! It's not very handy.
      
      Adding separate log category for *_cpu_handle_mmu_fault()
      logging fixes the problem.
      
      Signed-off-by: default avatarAntony Pavlov <antonynpavlov@gmail.com>
      Acked-by: default avatarAlexander Graf <agraf@suse.de>
      Reviewed-by: default avatarRichard Henderson <rth@twiddle.net>
      Message-id: 1418489298-1184-1-git-send-email-antonynpavlov@gmail.com
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      339aaf5b
  20. Feb 26, 2013
    • Peter Maydell's avatar
      qemu-log: default to stderr for logging output · 989b697d
      Peter Maydell authored
      
      Switch the default for qemu_log logging output from "/tmp/qemu.log"
      to stderr. This is an incompatible change in some sense, but logging
      is mostly used for debugging purposes so it shouldn't affect production
      use. The previous behaviour can be obtained by adding "-D /tmp/qemu.log"
      to the command line.
      
      This change requires us to:
       * update all the documentation/help text (we take the opportunity
         to smooth out minor inconsistencies between the phrasing in
         linux-user/bsd-user/system help messages)
       * make linux-user and bsd-user defer to qemu-log for the default
         logging destination rather than overriding it themselves
       * ensure that all logfile closing is done via qemu_log_close()
         and that that function doesn't close stderr
      as well as the obvious change to the behaviour of do_qemu_set_log()
      when no logfile name has been specified.
      
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      Reviewed-by: default avatarStefan Hajnoczi <stefanha@redhat.com>
      Reviewed-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Message-id: 1361901160-28729-1-git-send-email-peter.maydell@linaro.org
      Signed-off-by: default avatarAnthony Liguori <aliguori@us.ibm.com>
      989b697d
  21. Feb 16, 2013
  22. Jan 30, 2013
  23. Dec 19, 2012
  24. Oct 20, 2012
  25. Jul 14, 2012
Loading