Skip to content
Snippets Groups Projects
  1. Nov 02, 2023
  2. Oct 31, 2023
    • Stefan Hajnoczi's avatar
      Merge tag 'for-upstream' of https://repo.or.cz/qemu/kevin into staging · 6c9ae1ce
      Stefan Hajnoczi authored
      Block layer patches
      
      - virtio-blk: use blk_io_plug_call() instead of notification BH
      - mirror: allow switching from background to active mode
      - qemu-img rebase: add compression support
      - Fix locking in media change monitor commands
      - Fix a few blockjob-related deadlocks when using iothread
      
      # -----BEGIN PGP SIGNATURE-----
      #
      # iQJFBAABCAAvFiEE3D3rFZqa+V09dFb+fwmycsiPL9YFAmVBTkERHGt3b2xmQHJl
      # ZGhhdC5jb20ACgkQfwmycsiPL9ZiqRAAqvsWbblmEGJ7TBKYQK3f8QshJ66RxzbC
      # 4eSjKHrciWNTeeIeU8r8OvFcPPoTcPXxpcmasD2gsAxG5W5N8vkPbBkW+YT4YdDJ
      # pWJXrbJ15nILC4DmnR1ARVtvxKgv9zy5LSm5bjss1K+OSYJl/nx+ILjmfVZnYDF7
      # z1dP/G0JxKKm4JzAIdBE3uZS+6Q5kx/wGYlJv8EQmlH3DYfsJfy6Lthe9jfw8ijg
      # lSqLoQ+D0lEd6Bk4XbkUqqBxFcYBWTfU6qPZoyIO94zCTwTG9yIjmoivxmmfwQZq
      # cJUTGGZjcxpJYnvcC6P13WgcWBtcD9L2kYFVH0JyjpwcSg9cCGHMF66n9pSlyEGq
      # DUikwVzbTwOotwzYQyM88v4ET+2+Qdcwn8pRbv9PllEczh0kAsUAEuxSgtz4NEcN
      # bZrap/16xHFybNOKkMZcmpqxspT5NXKbDODUP0IvbSYMOYpWS983nBTxwMRpyHog
      # 2TFDZu4DjNiPkI2BcYM5VOKk6diNowZFShcEKvoaOLX/n9EBhP0tjoH9VUn1800F
      # myHrhF2jpIf9GhErMWB7N2W3/0aK0pqdQgbpVnd1ARDdIdYkr7G/S+50D9K80b6n
      # 0q2E7br4S5bcsY0HQzBL9YARSayY+lVOssLoolCWEsYzijdBQmAvs5THajFKcism
      # /idI6nlp2Vs=
      # =RdxS
      # -----END PGP SIGNATURE-----
      # gpg: Signature made Wed 01 Nov 2023 03:58:09 JST
      # gpg:                using RSA key DC3DEB159A9AF95D3D7456FE7F09B272C88F2FD6
      # gpg:                issuer "kwolf@redhat.com"
      # gpg: Good signature from "Kevin Wolf <kwolf@redhat.com>" [full]
      # Primary key fingerprint: DC3D EB15 9A9A F95D 3D74  56FE 7F09 B272 C88F 2FD6
      
      * tag 'for-upstream' of https://repo.or.cz/qemu/kevin
      
      : (27 commits)
        iotests: add test for changing mirror's copy_mode
        mirror: return mirror-specific information upon query
        blockjob: query driver-specific info via a new 'query' driver method
        qapi/block-core: turn BlockJobInfo into a union
        qapi/block-core: use JobType for BlockJobInfo's type
        mirror: implement mirror_change method
        block/mirror: determine copy_to_target only once
        block/mirror: move dirty bitmap to filter
        block/mirror: set actively_synced even after the job is ready
        blockjob: introduce block-job-change QMP command
        virtio-blk: remove batch notification BH
        virtio: use defer_call() in virtio_irqfd_notify()
        util/defer-call: move defer_call() to util/
        block: rename blk_io_plug_call() API to defer_call()
        blockdev: mirror: avoid potential deadlock when using iothread
        block: avoid potential deadlock during bdrv_graph_wrlock() in bdrv_close()
        blockjob: drop AioContext lock before calling bdrv_graph_wrlock()
        iotests: Test media change with iothreads
        block: Fix locking in media change monitor commands
        iotests: add tests for "qemu-img rebase" with compression
        ...
      
      Signed-off-by: default avatarStefan Hajnoczi <stefanha@redhat.com>
      6c9ae1ce
    • Stefan Hajnoczi's avatar
      Merge tag 'pull-halloween-omnibus-311023-2' of https://gitlab.com/stsquad/qemu into staging · 997ef293
      Stefan Hajnoczi authored
      Maintainer updates for testing, gitlab, gdbstub and plugins:
      
        - add dtc package to openbsd VMs
        - use -fno-stack-protector for non-stdlib tests
        - split alpha and sh4 compilers into legacy image
        - harmonise other compilers into debian-all-test-cross
        - fix NULL check in gdb_regs
        - fix memleak in semihosting
        - remove unused parameter in plugin code
        - fix fd leak in lockstep plugin
      
      # -----BEGIN PGP SIGNATURE-----
      #
      # iQEzBAABCgAdFiEEZoWumedRZ7yvyN81+9DbCVqeKkQFAmVBCvQACgkQ+9DbCVqe
      # KkR8jAgAjFC3BE6fu80zYT0Dmeu8zh20QY/wgKQebaFfGEmPL4Bqkl2D/Rx7PhQA
      # EH8fR/LAH/iXAO07+LYOB6QiyMb9PWiXS52iHyE3q11mOaM8iKkkj7a59NW8DfGC
      # biSrj9o3wpz9gGkJjzTCcHC8DOMbrAuE12XnmhW7uTqqkrcTMC393dSEeyL+nrP9
      # lKS5XzFyn3FOT4YIL8hAC02ObKH4LpWIO3gdWeDAo56yg24fLir9a2wYSXMaxQtN
      # kDf6UtL97CIIhbNi6qrUPBB13MV8MlXno3wnb9+E4Cn5sGntGSnTyh7j6XrGqYj9
      # p/Vio6ye8xP1IjlavKiBM0nnozcAhw==
      # =ZOMS
      # -----END PGP SIGNATURE-----
      # gpg: Signature made Tue 31 Oct 2023 23:11:00 JST
      # gpg:                using RSA key 6685AE99E75167BCAFC8DF35FBD0DB095A9E2A44
      # gpg: Good signature from "Alex Bennée (Master Work Key) <alex.bennee@linaro.org>" [unknown]
      # gpg: WARNING: This key is not certified with a trusted signature!
      # gpg:          There is no indication that the signature belongs to the owner.
      # Primary key fingerprint: 6685 AE99 E751 67BC AFC8  DF35 FBD0 DB09 5A9E 2A44
      
      * tag 'pull-halloween-omnibus-311023-2' of https://gitlab.com/stsquad/qemu
      
      :
        contrib/plugins: Close file descriptor on error return
        plugins: Remove an extra parameter
        semihosting: fix memleak at semihosting_arg_fallback
        gdbstub: Check if gdb_regs is NULL
        tests/docker: upgrade debian-all-test-cross to bookworm
        tests/docker: use debian-all-test-cross for sparc64
        tests/docker: use debian-all-test-cross for riscv64
        tests/docker: use debian-all-test-cross for mips
        tests/docker: use debian-all-test-cross for mips64
        tests/docker: use debian-all-test-cross for m68k
        tests/docker: use debian-all-test-cross for hppa
        tests/docker: use debian-all-test-cross for power
        tests/docker: move sh4 to use debian-legacy-test-cross
        tests/docker: use debian-legacy-test-cross for alpha
        gitlab: add build-loongarch to matrix
        gitlab: clean-up build-soft-softmmu job
        gitlab: split alpha testing into a legacy container
        tests/tcg: Add -fno-stack-protector
        tests/vm/openbsd: Use the system dtc package
      
      Signed-off-by: default avatarStefan Hajnoczi <stefanha@redhat.com>
      997ef293
    • Stefan Hajnoczi's avatar
      Merge tag 'migration-20231031-pull-request' of https://gitlab.com/juan.quintela/qemu into staging · f13b978c
      Stefan Hajnoczi authored
      Migration Pull request (20231031)
      
      Hi
      
      This is repeat of the Migration PULL for 20231020.
      - I removed vmstate_register(big problems with s390x)
      - I added yet more countes (juan)
      
      CI: https://gitlab.com/juan.quintela/qemu/-/pipelines/1055797950
      
      Please apply.
      
      Thanks, Juan.
      
      # -----BEGIN PGP SIGNATURE-----
      #
      # iQIzBAABCAAdFiEEGJn/jt6/WMzuA0uC9IfvGFhy1yMFAmVAwmYACgkQ9IfvGFhy
      # 1yPJ9g//f8Up+5Az0DmJMWwRe+08vLa3ZRCSh5aCRJguFVfMZSVxRNuoikQ/C/Gz
      # 1ePB+Q8H0NcP86FF7pifhtLU0uE9L4At4Z+vOQP1+n67p7aush050kKQxyDYIfO2
      # 3tO2HkfHvC/R3S5FtqQtE1Y0/MpHdj1vgV9bNidPorA6EZ01KEEfWw3soptuD14I
      # LPvXA8BG5mOvB7R55MymTAej3ZDmOUQlZotsE2KmlkOfzYoqTtApkLtW03/WH8b8
      # fAYJ0ghYpesRTO1rF61n1peLMUr+/HRLqGJmhLDSEZZlB5tnUYeiLR9dRJ1/1+o2
      # zNjLr6X2hnia6Kb0UibRoAcyyy8lSLp79Zt5nhDneuTSQxeYhNh6EecxAzKvd/02
      # vfE/reOEkZn7KzYH/MvlD5P6XmwrT5aV9cqmyC/8BkNnipHAtJ2Av1H4ONdnahuK
      # hOhLRAGE7SINtgo8jdauQNor1QAsIX19nvYk9p7ta5VAysrDSbuD+9Yq7HtUErlP
      # 585z5BPGfaP2GwIXPNJNcqXwPh0InInGASqEWmYSlu8GF3Ic0KNWWrC5bwSn7tHL
      # I7qaMrCHxvWGYx6cRzzp08EqCcbOQCixrPyk8g6o3SgXHrTGKthzjPG5bLe+QXpv
      # P2gblC7Fo3sUo89IwVjsRMO3nU9wBfb9skE7iZM06SILO7QD3u8=
      # =r1DI
      # -----END PGP SIGNATURE-----
      # gpg: Signature made Tue 31 Oct 2023 18:01:26 JST
      # gpg:                using RSA key 1899FF8EDEBF58CCEE034B82F487EF185872D723
      # gpg: Good signature from "Juan Quintela <quintela@redhat.com>" [full]
      # gpg:                 aka "Juan Quintela <quintela@trasno.org>" [full]
      # Primary key fingerprint: 1899 FF8E DEBF 58CC EE03  4B82 F487 EF18 5872 D723
      
      * tag 'migration-20231031-pull-request' of https://gitlab.com/juan.quintela/qemu
      
      : (38 commits)
        qemu-file: Make qemu_fflush() return errors
        migration: Remove transferred atomic counter
        migration: Use migration_transferred_bytes()
        qemu-file: Simplify qemu_file_get_error()
        migration: migration_rate_limit_reset() don't need the QEMUFile
        migration: migration_transferred_bytes() don't need the QEMUFile
        qemu-file: Remove _noflush from qemu_file_transferred_noflush()
        qemu_file: Remove unused qemu_file_transferred()
        migration: Use the number of transferred bytes directly
        qemu_file: total_transferred is not used anymore
        qemu_file: Use a stat64 for qemu_file_transferred
        qemu-file: Don't increment qemu_file_transferred at qemu_file_fill_buffer
        migration: Stop migration immediately in RDMA error paths
        migration: Deprecate old compression method
        migration: Deprecate block migration
        migration: migrate 'blk' command option is deprecated.
        migration: migrate 'inc' command option is deprecated.
        qemu-iotests: Filter warnings about block migration being deprecated
        migration: set file error on subsection loading
        migration: rename vmstate_save_needed->vmstate_section_needed
        ...
      
      Signed-off-by: default avatarStefan Hajnoczi <stefanha@redhat.com>
      f13b978c
    • Fiona Ebner's avatar
      iotests: add test for changing mirror's copy_mode · 900e7d41
      Fiona Ebner authored
      
      One part of the test is using a throttled source to ensure that there
      are no obvious issues when changing the copy_mode while there are
      ongoing requests (source and target images are compared at the very
      end).
      
      The other part of the test is using a throttled target to ensure that
      the change to active mode actually happened. This is done by hitting
      the throttling limit, issuing a synchronous write and then immediately
      verifying the target side. QSD is used, because otherwise, a
      synchronous write would hang there.
      
      Signed-off-by: default avatarFiona Ebner <f.ebner@proxmox.com>
      Message-ID: <20231031135431.393137-11-f.ebner@proxmox.com>
      Reviewed-by: default avatarKevin Wolf <kwolf@redhat.com>
      Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
      900e7d41
    • Fiona Ebner's avatar
      mirror: return mirror-specific information upon query · 76cb2f24
      Fiona Ebner authored
      
      To start out, only actively-synced is returned.
      
      For example, this is useful for jobs that started out in background
      mode and switched to active mode. Once actively-synced is true, it's
      clear that the mode switch has been completed. Note that completion of
      the switch might happen much earlier, e.g. if the switch happens
      before the job is ready, once all background operations have finished.
      It's assumed that whether the disks are actively-synced or not is more
      interesting than whether the mode switch completed. That information
      can still be added if required in the future.
      
      In presence of an iothread, the actively_synced member is now shared
      between the iothread and the main thread, so turn accesses to it
      atomic.
      
      Requires to adapt the output for iotest 109.
      
      Signed-off-by: default avatarFiona Ebner <f.ebner@proxmox.com>
      Message-ID: <20231031135431.393137-10-f.ebner@proxmox.com>
      Reviewed-by: default avatarKevin Wolf <kwolf@redhat.com>
      Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
      76cb2f24
    • Fiona Ebner's avatar
      blockjob: query driver-specific info via a new 'query' driver method · 59fd8254
      Fiona Ebner authored
      
      Signed-off-by: default avatarFiona Ebner <f.ebner@proxmox.com>
      Message-ID: <20231031135431.393137-9-f.ebner@proxmox.com>
      Reviewed-by: default avatarKevin Wolf <kwolf@redhat.com>
      Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
      59fd8254
    • Fiona Ebner's avatar
      qapi/block-core: turn BlockJobInfo into a union · 701efc9f
      Fiona Ebner authored
      
      In preparation to additionally return job-type-specific information.
      
      Signed-off-by: default avatarFiona Ebner <f.ebner@proxmox.com>
      Reviewed-by: default avatarVladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
      Message-ID: <20231031135431.393137-8-f.ebner@proxmox.com>
      Reviewed-by: default avatarKevin Wolf <kwolf@redhat.com>
      Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
      701efc9f
    • Fiona Ebner's avatar
      qapi/block-core: use JobType for BlockJobInfo's type · d67c54d0
      Fiona Ebner authored
      
      In preparation to turn BlockJobInfo into a union with @type as the
      discriminator. That requires it to be an enum. Even without that
      requirement, it's nicer to have an enum instead of a str here.
      
      No functional change is intended.
      
      Signed-off-by: default avatarFiona Ebner <f.ebner@proxmox.com>
      Reviewed-by: default avatarVladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
      Reviewed-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Message-ID: <20231031135431.393137-7-f.ebner@proxmox.com>
      Reviewed-by: default avatarKevin Wolf <kwolf@redhat.com>
      Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
      d67c54d0
    • Fiona Ebner's avatar
      mirror: implement mirror_change method · 2d400d15
      Fiona Ebner authored
      
      which allows switching the @copy-mode from 'background' to
      'write-blocking'.
      
      This is useful for management applications, so they can start out in
      background mode to avoid limiting guest write speed and switch to
      active mode when certain criteria are fulfilled.
      
      In presence of an iothread, the copy_mode member is now shared between
      the iothread and the main thread, so turn accesses to it atomic.
      
      Signed-off-by: default avatarFiona Ebner <f.ebner@proxmox.com>
      Message-ID: <20231031135431.393137-6-f.ebner@proxmox.com>
      Reviewed-by: default avatarKevin Wolf <kwolf@redhat.com>
      Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
      2d400d15
    • Fiona Ebner's avatar
      block/mirror: determine copy_to_target only once · 7b32ad22
      Fiona Ebner authored
      
      In preparation to allow changing the copy_mode via QMP. When running
      in an iothread, it could be that copy_mode is changed from the main
      thread in between reading copy_mode in bdrv_mirror_top_pwritev() and
      reading copy_mode in bdrv_mirror_top_do_write(), so they might end up
      disagreeing about whether copy_to_target is true or false. Avoid that
      scenario by determining copy_to_target only once and passing it to
      bdrv_mirror_top_do_write() as an argument.
      
      Signed-off-by: default avatarFiona Ebner <f.ebner@proxmox.com>
      Reviewed-by: default avatarVladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
      Message-ID: <20231031135431.393137-5-f.ebner@proxmox.com>
      Reviewed-by: default avatarKevin Wolf <kwolf@redhat.com>
      Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
      7b32ad22
    • Fiona Ebner's avatar
      block/mirror: move dirty bitmap to filter · 058cfca5
      Fiona Ebner authored
      
      In preparation to allow switching to active mode without draining.
      Initialization of the bitmap in mirror_dirty_init() still happens with
      the original/backing BlockDriverState, which should be fine, because
      the mirror top has the same length.
      
      Suggested-by: default avatarVladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
      Signed-off-by: default avatarFiona Ebner <f.ebner@proxmox.com>
      Message-ID: <20231031135431.393137-4-f.ebner@proxmox.com>
      Reviewed-by: default avatarKevin Wolf <kwolf@redhat.com>
      Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
      058cfca5
    • Fiona Ebner's avatar
      block/mirror: set actively_synced even after the job is ready · c45d0e1a
      Fiona Ebner authored
      
      In preparation to allow switching from background to active mode. This
      ensures that setting actively_synced will not be missed when the
      switch happens after the job is ready.
      
      Signed-off-by: default avatarFiona Ebner <f.ebner@proxmox.com>
      Reviewed-by: default avatarVladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
      Message-ID: <20231031135431.393137-3-f.ebner@proxmox.com>
      Reviewed-by: default avatarKevin Wolf <kwolf@redhat.com>
      Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
      c45d0e1a
    • Fiona Ebner's avatar
      blockjob: introduce block-job-change QMP command · 61a3a5a7
      Fiona Ebner authored
      
      which will allow changing job-type-specific options after job
      creation.
      
      In the JobVerbTable, the same allow bits as for set-speed are used,
      because set-speed can be considered an existing change command.
      
      Signed-off-by: default avatarFiona Ebner <f.ebner@proxmox.com>
      Reviewed-by: default avatarVladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
      Message-ID: <20231031135431.393137-2-f.ebner@proxmox.com>
      Reviewed-by: default avatarKevin Wolf <kwolf@redhat.com>
      Reviewed-by: default avatarEric Blake <eblake@redhat.com>
      Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
      61a3a5a7
    • Stefan Hajnoczi's avatar
      virtio-blk: remove batch notification BH · 073458da
      Stefan Hajnoczi authored
      
      There is a batching mechanism for virtio-blk Used Buffer Notifications
      that is no longer needed because the previous commit added batching to
      virtio_notify_irqfd().
      
      Note that this mechanism was rarely used in practice because it is only
      enabled when EVENT_IDX is not negotiated by the driver. Modern drivers
      enable EVENT_IDX.
      
      Reviewed-by: default avatarEric Blake <eblake@redhat.com>
      Signed-off-by: default avatarStefan Hajnoczi <stefanha@redhat.com>
      Message-ID: <20230913200045.1024233-5-stefanha@redhat.com>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Reviewed-by: default avatarKevin Wolf <kwolf@redhat.com>
      Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
      073458da
    • Stefan Hajnoczi's avatar
      virtio: use defer_call() in virtio_irqfd_notify() · 84d61e5f
      Stefan Hajnoczi authored
      virtio-blk and virtio-scsi invoke virtio_irqfd_notify() to send Used
      Buffer Notifications from an IOThread. This involves an eventfd
      write(2) syscall. Calling this repeatedly when completing multiple I/O
      requests in a row is wasteful.
      
      Use the defer_call() API to batch together virtio_irqfd_notify() calls
      made during thread pool (aio=threads), Linux AIO (aio=native), and
      io_uring (aio=io_uring) completion processing.
      
      Behavior is unchanged for emulated devices that do not use
      defer_call_begin()/defer_call_end() since defer_call() immediately
      invokes the callback when called outside a
      defer_call_begin()/defer_call_end() region.
      
      fio rw=randread bs=4k iodepth=64 numjobs=8 IOPS increases by ~9% with a
      single IOThread and 8 vCPUs. iodepth=1 decreases by ~1% but this could
      be noise. Detailed performance data and configuration specifics are
      available here:
      https://gitlab.com/stefanha/virt-playbooks/-/tree/blk_io_plug-irqfd
      
      
      
      This duplicates the BH that virtio-blk uses for batching. The next
      commit will remove it.
      
      Reviewed-by: default avatarEric Blake <eblake@redhat.com>
      Signed-off-by: default avatarStefan Hajnoczi <stefanha@redhat.com>
      Message-ID: <20230913200045.1024233-4-stefanha@redhat.com>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Reviewed-by: default avatarKevin Wolf <kwolf@redhat.com>
      Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
      84d61e5f
    • Stefan Hajnoczi's avatar
      util/defer-call: move defer_call() to util/ · 433fcea4
      Stefan Hajnoczi authored
      
      The networking subsystem may wish to use defer_call(), so move the code
      to util/ where it can be reused.
      
      As a reminder of what defer_call() does:
      
      This API defers a function call within a defer_call_begin()/defer_call_end()
      section, allowing multiple calls to batch up. This is a performance
      optimization that is used in the block layer to submit several I/O requests
      at once instead of individually:
      
        defer_call_begin(); <-- start of section
        ...
        defer_call(my_func, my_obj); <-- deferred my_func(my_obj) call
        defer_call(my_func, my_obj); <-- another
        defer_call(my_func, my_obj); <-- another
        ...
        defer_call_end(); <-- end of section, my_func(my_obj) is called once
      
      Suggested-by: default avatarIlya Maximets <i.maximets@ovn.org>
      Reviewed-by: default avatarPhilippe Mathieu-Daudé <philmd@linaro.org>
      Signed-off-by: default avatarStefan Hajnoczi <stefanha@redhat.com>
      Message-ID: <20230913200045.1024233-3-stefanha@redhat.com>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Reviewed-by: default avatarKevin Wolf <kwolf@redhat.com>
      Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
      433fcea4
    • Stefan Hajnoczi's avatar
      block: rename blk_io_plug_call() API to defer_call() · ccee48aa
      Stefan Hajnoczi authored
      
      Prepare to move the blk_io_plug_call() API out of the block layer so
      that other subsystems call use this deferred call mechanism. Rename it
      to defer_call() but leave the code in block/plug.c.
      
      The next commit will move the code out of the block layer.
      
      Suggested-by: default avatarIlya Maximets <i.maximets@ovn.org>
      Reviewed-by: default avatarPhilippe Mathieu-Daudé <philmd@linaro.org>
      Reviewed-by: default avatarPaul Durrant <paul@xen.org>
      Signed-off-by: default avatarStefan Hajnoczi <stefanha@redhat.com>
      Message-ID: <20230913200045.1024233-2-stefanha@redhat.com>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Reviewed-by: default avatarKevin Wolf <kwolf@redhat.com>
      Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
      ccee48aa
    • Cong Liu's avatar
      contrib/plugins: Close file descriptor on error return · 7f452762
      Cong Liu authored
      
      This patch closes the file descriptor fd on error return to avoid
      resource leak.
      
      Fixes: ec7ee95d ("contrib/plugins: fix coverity warning in lockstep")
      Signed-off-by: default avatarCong Liu <liucong2@kylinos.cn>
      Message-Id: <20231018025225.1640122-1-liucong2@kylinos.cn>
      Signed-off-by: default avatarAlex Bennée <alex.bennee@linaro.org>
      Message-Id: <20231029145033.592566-20-alex.bennee@linaro.org>
      7f452762
    • Akihiko Odaki's avatar
      plugins: Remove an extra parameter · 946bf79e
      Akihiko Odaki authored
      
      copy_call() has an unused parameter so remove it.
      
      Signed-off-by: default avatarAkihiko Odaki <akihiko.odaki@daynix.com>
      Message-Id: <20231019101030.128431-7-akihiko.odaki@daynix.com>
      Reviewed-by: default avatarRichard Henderson <richard.henderson@linaro.org>
      Message-Id: <20231029145033.592566-19-alex.bennee@linaro.org>
      Signed-off-by: default avatarAlex Bennée <alex.bennee@linaro.org>
      946bf79e
    • Matheus Tavares Bernardino's avatar
      semihosting: fix memleak at semihosting_arg_fallback · 2eb71a0c
      Matheus Tavares Bernardino authored
      
      We duplicate "cmd" as strtok may modify its argument, but we forgot
      to free it later. Furthermore, add_semihosting_arg doesn't take
      responsibility for this memory either (it strdup's the argument).
      
      Signed-off-by: default avatarMatheus Tavares Bernardino <quic_mathbern@quicinc.com>
      Reviewed-by: default avatarPhilippe Mathieu-Daudé <philmd@linaro.org>
      Message-Id: <03d81c56bfc3d08224e4106efca5949d8894cfa5.1697801632.git.quic_mathbern@quicinc.com>
      Reviewed-by: default avatarRichard Henderson <richard.henderson@linaro.org>
      Signed-off-by: default avatarAlex Bennée <alex.bennee@linaro.org>
      Message-Id: <20231029145033.592566-18-alex.bennee@linaro.org>
      2eb71a0c
Loading