1. 22 4月, 2022 12 次提交
  2. 06 4月, 2022 2 次提交
  3. 21 3月, 2022 1 次提交
  4. 15 12月, 2021 1 次提交
  5. 02 11月, 2021 1 次提交
  6. 02 5月, 2021 1 次提交
  7. 28 1月, 2021 1 次提交
  8. 09 10月, 2020 1 次提交
  9. 23 9月, 2020 1 次提交
    • S
      qemu/atomic.h: rename atomic_ to qatomic_ · d73415a3
      Stefan Hajnoczi 提交于
      clang's C11 atomic_fetch_*() functions only take a C11 atomic type
      pointer argument. QEMU uses direct types (int, etc) and this causes a
      compiler error when a QEMU code calls these functions in a source file
      that also included <stdatomic.h> via a system header file:
      
        $ CC=clang CXX=clang++ ./configure ... && make
        ../util/async.c:79:17: error: address argument to atomic operation must be a pointer to _Atomic type ('unsigned int *' invalid)
      
      Avoid using atomic_*() names in QEMU's atomic.h since that namespace is
      used by <stdatomic.h>. Prefix QEMU's APIs with 'q' so that atomic.h
      and <stdatomic.h> can co-exist. I checked /usr/include on my machine and
      searched GitHub for existing "qatomic_" users but there seem to be none.
      
      This patch was generated using:
      
        $ git grep -h -o '\<atomic\(64\)\?_[a-z0-9_]\+' include/qemu/atomic.h | \
          sort -u >/tmp/changed_identifiers
        $ for identifier in $(</tmp/changed_identifiers); do
              sed -i "s%\<$identifier\>%q$identifier%g" \
                  $(git grep -I -l "\<$identifier\>")
          done
      
      I manually fixed line-wrap issues and misaligned rST tables.
      Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
      Reviewed-by: NPhilippe Mathieu-Daudé <philmd@redhat.com>
      Acked-by: NPaolo Bonzini <pbonzini@redhat.com>
      Message-Id: <20200923105646.47864-1-stefanha@redhat.com>
      d73415a3
  10. 16 9月, 2020 1 次提交
  11. 21 8月, 2020 1 次提交
  12. 10 7月, 2020 1 次提交
  13. 29 4月, 2020 1 次提交
    • P
      various: Remove suspicious '\' character outside of #define in C code · 78ee6bd0
      Philippe Mathieu-Daudé 提交于
      Fixes the following coccinelle warnings:
      
        $ spatch --sp-file --verbose-parsing  ... \
            scripts/coccinelle/remove_local_err.cocci
        ...
        SUSPICIOUS: a \ character appears outside of a #define at ./target/ppc/translate_init.inc.c:5213
        SUSPICIOUS: a \ character appears outside of a #define at ./target/ppc/translate_init.inc.c:5261
        SUSPICIOUS: a \ character appears outside of a #define at ./target/microblaze/cpu.c:166
        SUSPICIOUS: a \ character appears outside of a #define at ./target/microblaze/cpu.c:167
        SUSPICIOUS: a \ character appears outside of a #define at ./target/microblaze/cpu.c:169
        SUSPICIOUS: a \ character appears outside of a #define at ./target/microblaze/cpu.c:170
        SUSPICIOUS: a \ character appears outside of a #define at ./target/microblaze/cpu.c:171
        SUSPICIOUS: a \ character appears outside of a #define at ./target/microblaze/cpu.c:172
        SUSPICIOUS: a \ character appears outside of a #define at ./target/microblaze/cpu.c:173
        SUSPICIOUS: a \ character appears outside of a #define at ./target/i386/cpu.c:5787
        SUSPICIOUS: a \ character appears outside of a #define at ./target/i386/cpu.c:5789
        SUSPICIOUS: a \ character appears outside of a #define at ./target/i386/cpu.c:5800
        SUSPICIOUS: a \ character appears outside of a #define at ./target/i386/cpu.c:5801
        SUSPICIOUS: a \ character appears outside of a #define at ./target/i386/cpu.c:5802
        SUSPICIOUS: a \ character appears outside of a #define at ./target/i386/cpu.c:5804
        SUSPICIOUS: a \ character appears outside of a #define at ./target/i386/cpu.c:5805
        SUSPICIOUS: a \ character appears outside of a #define at ./target/i386/cpu.c:5806
        SUSPICIOUS: a \ character appears outside of a #define at ./target/i386/cpu.c:6329
        SUSPICIOUS: a \ character appears outside of a #define at ./hw/sd/sdhci.c:1133
        SUSPICIOUS: a \ character appears outside of a #define at ./hw/scsi/scsi-disk.c:3081
        SUSPICIOUS: a \ character appears outside of a #define at ./hw/net/virtio-net.c:1529
        SUSPICIOUS: a \ character appears outside of a #define at ./hw/riscv/sifive_u.c:468
        SUSPICIOUS: a \ character appears outside of a #define at ./dump/dump.c:1895
        SUSPICIOUS: a \ character appears outside of a #define at ./block/vhdx.c:2209
        SUSPICIOUS: a \ character appears outside of a #define at ./block/vhdx.c:2215
        SUSPICIOUS: a \ character appears outside of a #define at ./block/vhdx.c:2221
        SUSPICIOUS: a \ character appears outside of a #define at ./block/vhdx.c:2222
        SUSPICIOUS: a \ character appears outside of a #define at ./block/replication.c:172
        SUSPICIOUS: a \ character appears outside of a #define at ./block/replication.c:173
      Reviewed-by: NMarc-André Lureau <marcandre.lureau@redhat.com>
      Signed-off-by: NPhilippe Mathieu-Daudé <f4bug@amsat.org>
      Message-Id: <20200412223619.11284-2-f4bug@amsat.org>
      Reviewed-by: NAlistair Francis <alistair.francis@wdc.com>
      Acked-by: NDavid Gibson <david@gibson.dropbear.id.au>
      Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
      78ee6bd0
  14. 04 4月, 2020 2 次提交
  15. 18 12月, 2019 1 次提交
  16. 16 8月, 2019 3 次提交
    • M
      sysemu: Split sysemu/runstate.h off sysemu/sysemu.h · 54d31236
      Markus Armbruster 提交于
      sysemu/sysemu.h is a rather unfocused dumping ground for stuff related
      to the system-emulator.  Evidence:
      
      * It's included widely: in my "build everything" tree, changing
        sysemu/sysemu.h still triggers a recompile of some 1100 out of 6600
        objects (not counting tests and objects that don't depend on
        qemu/osdep.h, down from 5400 due to the previous two commits).
      
      * It pulls in more than a dozen additional headers.
      
      Split stuff related to run state management into its own header
      sysemu/runstate.h.
      
      Touching sysemu/sysemu.h now recompiles some 850 objects.  qemu/uuid.h
      also drops from 1100 to 850, and qapi/qapi-types-run-state.h from 4400
      to 4200.  Touching new sysemu/runstate.h recompiles some 500 objects.
      
      Since I'm touching MAINTAINERS to add sysemu/runstate.h anyway, also
      add qemu/main-loop.h.
      Suggested-by: NPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
      Message-Id: <20190812052359.30071-30-armbru@redhat.com>
      Reviewed-by: NAlex Bennée <alex.bennee@linaro.org>
      [Unbreak OS-X build]
      54d31236
    • M
      Clean up inclusion of sysemu/sysemu.h · d5938f29
      Markus Armbruster 提交于
      In my "build everything" tree, changing sysemu/sysemu.h triggers a
      recompile of some 5400 out of 6600 objects (not counting tests and
      objects that don't depend on qemu/osdep.h).
      
      Almost a third of its inclusions are actually superfluous.  Delete
      them.  Downgrade two more to qapi/qapi-types-run-state.h, and move one
      from char/serial.h to char/serial.c.
      
      hw/semihosting/config.c, monitor/monitor.c, qdev-monitor.c, and
      stubs/semihost.c define variables declared in sysemu/sysemu.h without
      including it.  The compiler is cool with that, but include it anyway.
      
      This doesn't reduce actual use much, as it's still included into
      widely included headers.  The next commit will tackle that.
      Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
      Reviewed-by: NAlistair Francis <alistair.francis@wdc.com>
      Message-Id: <20190812052359.30071-27-armbru@redhat.com>
      Reviewed-by: NAlex Bennée <alex.bennee@linaro.org>
      d5938f29
    • M
      Include qemu/main-loop.h less · db725815
      Markus Armbruster 提交于
      In my "build everything" tree, changing qemu/main-loop.h triggers a
      recompile of some 5600 out of 6600 objects (not counting tests and
      objects that don't depend on qemu/osdep.h).  It includes block/aio.h,
      which in turn includes qemu/event_notifier.h, qemu/notify.h,
      qemu/processor.h, qemu/qsp.h, qemu/queue.h, qemu/thread-posix.h,
      qemu/thread.h, qemu/timer.h, and a few more.
      
      Include qemu/main-loop.h only where it's needed.  Touching it now
      recompiles only some 1700 objects.  For block/aio.h and
      qemu/event_notifier.h, these numbers drop from 5600 to 2800.  For the
      others, they shrink only slightly.
      Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
      Message-Id: <20190812052359.30071-21-armbru@redhat.com>
      Reviewed-by: NAlex Bennée <alex.bennee@linaro.org>
      Reviewed-by: NPhilippe Mathieu-Daudé <philmd@redhat.com>
      Tested-by: NPhilippe Mathieu-Daudé <philmd@redhat.com>
      db725815
  17. 02 7月, 2019 2 次提交