qemu-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-commits] [qemu/qemu] e66e66: qemu-storage-daemon: Fix typo in vhos


From: Peter Maydell
Subject: [Qemu-commits] [qemu/qemu] e66e66: qemu-storage-daemon: Fix typo in vhost-user-blk help
Date: Wed, 02 Feb 2022 01:05:56 -0800

  Branch: refs/heads/master
  Home:   https://github.com/qemu/qemu
  Commit: e66e665f15736f5ee1fbd8087926cb0f1e52f61a
      
https://github.com/qemu/qemu/commit/e66e665f15736f5ee1fbd8087926cb0f1e52f61a
  Author: Kevin Wolf <kwolf@redhat.com>
  Date:   2022-02-01 (Tue, 01 Feb 2022)

  Changed paths:
    M storage-daemon/qemu-storage-daemon.c

  Log Message:
  -----------
  qemu-storage-daemon: Fix typo in vhost-user-blk help

The syntax of the fd passing case misses the "addr.type=" key. Add it.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Message-Id: <20220125151514.49035-1-kwolf@redhat.com>
Reviewed-by: Hanna Reitz <hreitz@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>


  Commit: c0829cb1fd5e0b35abfcf9fc3f04502c1ed5d7b6
      
https://github.com/qemu/qemu/commit/c0829cb1fd5e0b35abfcf9fc3f04502c1ed5d7b6
  Author: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
  Date:   2022-02-01 (Tue, 01 Feb 2022)

  Changed paths:
    M block.c

  Log Message:
  -----------
  block: bdrv_set_backing_hd(): use drained section

Graph modifications should be done in drained section. stream_prepare()
handler of block stream job call bdrv_set_backing_hd() without using
drained section and it's theoretically possible that some IO request
will interleave with graph modification and will use outdated pointers
to removed block nodes.

Some other callers use bdrv_set_backing_hd() not caring about drained
sections too. So it seems good to make a drained section exactly in
bdrv_set_backing_hd().

Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Message-Id: <20220124173741.2984056-1-vsementsov@virtuozzo.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>


  Commit: 520d8b40e898158bc9a2b416d1cbdb44d2260bc7
      
https://github.com/qemu/qemu/commit/520d8b40e898158bc9a2b416d1cbdb44d2260bc7
  Author: Kevin Wolf <kwolf@redhat.com>
  Date:   2022-02-01 (Tue, 01 Feb 2022)

  Changed paths:
    M block/export/vhost-user-blk-server.c
    M include/qemu/vhost-user-server.h
    M util/vhost-user-server.c

  Log Message:
  -----------
  block/export: Fix vhost-user-blk shutdown with requests in flight

The vhost-user-blk export runs requests asynchronously in their own
coroutine. When the vhost connection goes away and we want to stop the
vhost-user server, we need to wait for these coroutines to stop before
we can unmap the shared memory. Otherwise, they would still access the
unmapped memory and crash.

This introduces a refcount to VuServer which is increased when spawning
a new request coroutine and decreased before the coroutine exits. The
memory is only unmapped when the refcount reaches zero.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Message-Id: <20220125151435.48792-1-kwolf@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>


  Commit: ac50419460cc45a66214e6d1c3e9d0d670522f8a
      
https://github.com/qemu/qemu/commit/ac50419460cc45a66214e6d1c3e9d0d670522f8a
  Author: Philippe Mathieu-Daudé <f4bug@amsat.org>
  Date:   2022-02-01 (Tue, 01 Feb 2022)

  Changed paths:
    M block/export/fuse.c

  Log Message:
  -----------
  block/export/fuse: Rearrange if-else-if ladder in fuse_fallocate()

In order to safely maintain a mixture of #ifdef'ry with if-else-if
ladder, rearrange the last statement (!mode) first. Since it is
mutually exclusive with the other conditions, checking it first
doesn't make any logical difference, but allows to add #ifdef'ry
around in a more cleanly way.

Suggested-by: Kevin Wolf <kwolf@redhat.com>
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-Id: <20220201112655.344373-2-f4bug@amsat.org>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>


  Commit: 3c9c70347b8e636c08035f39288f8cdd2e68bbda
      
https://github.com/qemu/qemu/commit/3c9c70347b8e636c08035f39288f8cdd2e68bbda
  Author: Philippe Mathieu-Daudé <f4bug@amsat.org>
  Date:   2022-02-01 (Tue, 01 Feb 2022)

  Changed paths:
    M block/export/fuse.c

  Log Message:
  -----------
  block/export/fuse: Fix build failure on FreeBSD

When building on FreeBSD we get:

  [816/6851] Compiling C object libblockdev.fa.p/block_export_fuse.c.o
  ../block/export/fuse.c:628:16: error: use of undeclared identifier 
'FALLOC_FL_KEEP_SIZE'
      if (mode & FALLOC_FL_KEEP_SIZE) {
                 ^
  ../block/export/fuse.c:651:16: error: use of undeclared identifier 
'FALLOC_FL_PUNCH_HOLE'
      if (mode & FALLOC_FL_PUNCH_HOLE) {
                 ^
  ../block/export/fuse.c:652:22: error: use of undeclared identifier 
'FALLOC_FL_KEEP_SIZE'
          if (!(mode & FALLOC_FL_KEEP_SIZE)) {
                       ^
  3 errors generated.
  FAILED: libblockdev.fa.p/block_export_fuse.c.o

Meson indeed reported FALLOC_FL_PUNCH_HOLE is not available:

  C compiler for the host machine: cc (clang 10.0.1 "FreeBSD clang version 
10.0.1")
  Checking for function "fallocate" : NO
  Checking for function "posix_fallocate" : YES
  Header <linux/falloc.h> has symbol "FALLOC_FL_PUNCH_HOLE" : NO
  Header <linux/falloc.h> has symbol "FALLOC_FL_ZERO_RANGE" : NO
  ...

Similarly to commit 304332039 ("block/export/fuse.c: fix musl build"),
guard the code requiring FALLOC_FL_KEEP_SIZE / FALLOC_FL_PUNCH_HOLE
definitions under CONFIG_FALLOCATE_PUNCH_HOLE #ifdef'ry.

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-Id: <20220201112655.344373-3-f4bug@amsat.org>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>


  Commit: ef6ec0d7793bec9e529fd967c25c8300ef6b3cd2
      
https://github.com/qemu/qemu/commit/ef6ec0d7793bec9e529fd967c25c8300ef6b3cd2
  Author: Emanuele Giuseppe Esposito <eesposit@redhat.com>
  Date:   2022-02-01 (Tue, 01 Feb 2022)

  Changed paths:
    M include/block/block.h

  Log Message:
  -----------
  block.h: remove outdated comment

The comment "disk I/O throttling" doesn't make any sense at all
any more. It was added in commit 0563e191516 to describe
bdrv_io_limits_enable()/disable(), which were removed in commit
97148076, so the comment is just a forgotten leftover.

Suggested-by: Kevin Wolf <kwolf@redhat.com>
Signed-off-by: Emanuele Giuseppe Esposito <eesposit@redhat.com>
Message-Id: <20220131125615.74612-1-eesposit@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>


  Commit: cb90ec3a3646a3bdb0b2a157db226db25d470442
      
https://github.com/qemu/qemu/commit/cb90ec3a3646a3bdb0b2a157db226db25d470442
  Author: Hanna Reitz <hreitz@redhat.com>
  Date:   2022-02-01 (Tue, 01 Feb 2022)

  Changed paths:
    M docs/tools/qemu-storage-daemon.rst
    M storage-daemon/qemu-storage-daemon.c

  Log Message:
  -----------
  qsd: Document fuse's allow-other option

We did not add documentation to the storage daemon's man page for fuse's
allow-other option when it was introduced, so do that now.

Fixes: 8fc54f9428b9763f800 ("export/fuse: Add allow-other option")
Signed-off-by: Hanna Reitz <hreitz@redhat.com>
Message-Id: <20220131103124.20325-1-hreitz@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>


  Commit: 111fbd74f67575c158d9be5363825aab8be50a0a
      
https://github.com/qemu/qemu/commit/111fbd74f67575c158d9be5363825aab8be50a0a
  Author: Hanna Reitz <hreitz@redhat.com>
  Date:   2022-02-01 (Tue, 01 Feb 2022)

  Changed paths:
    M docs/tools/qemu-img.rst
    M qemu-img-cmds.hx

  Log Message:
  -----------
  qemu-img: Unify [-b [-F]] documentation

qemu-img convert documents the backing file and backing format options
as follows:
    [-B backing_file [-F backing_fmt]]
whereas qemu-img create has this:
    [-b backing_file] [-F backing_fmt]

That is, for convert, we document that -F cannot be given without -B,
while for create, way say that they are independent.

Indeed, it is technically possible to give -F without -b, because it is
left to the block driver to decide whether this is an error or not, so
sometimes it is:

$ qemu-img create -f qed -F qed test.qed 64M
Formatting 'test.qed', fmt=qed size=67108864 backing_fmt=qed [...]

And sometimes it is not:

$ qemu-img create -f qcow2 -F qcow2 test.qcow2 64M
Formatting 'test.qcow2', fmt=qcow2 cluster_size=65536 [...]
qemu-img: test.qcow2: Backing format cannot be used without backing file

Generally, it does not make much sense, though, and users should only
give -F with -b, so document it that way, as we have already done for
qemu-img convert (commit 1899bf47375ad40555dcdff12ba49b4b8b82df38).

Reported-by: Tingting Mao <timao@redhat.com>
Signed-off-by: Hanna Reitz <hreitz@redhat.com>
Message-Id: <20220131135908.32393-1-hreitz@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>


  Commit: 9e302f64bb407a9bb097b626da97228c2654cfee
      
https://github.com/qemu/qemu/commit/9e302f64bb407a9bb097b626da97228c2654cfee
  Author: Peter Lieven <pl@kamp.de>
  Date:   2022-02-01 (Tue, 01 Feb 2022)

  Changed paths:
    M block/rbd.c

  Log Message:
  -----------
  block/rbd: fix handling of holes in .bdrv_co_block_status

the assumption that we can't hit a hole if we do not diff against a snapshot 
was wrong.

We can see a hole in an image if we diff against base if there exists an older 
snapshot
of the image and we have discarded blocks in the image where the snapshot has 
data.

Fix this by simply handling a hole like an unallocated area. There are no 
callbacks
for unallocated areas so just bail out if we hit a hole.

Fixes: 0347a8fd4c3faaedf119be04c197804be40a384b
Suggested-by: Ilya Dryomov <idryomov@gmail.com>
Cc: qemu-stable@nongnu.org
Signed-off-by: Peter Lieven <pl@kamp.de>
Message-Id: <20220113144426.4036493-2-pl@kamp.de>
Reviewed-by: Ilya Dryomov <idryomov@gmail.com>
Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>


  Commit: fc176116cdea816ceb8dd969080b2b95f58edbc0
      
https://github.com/qemu/qemu/commit/fc176116cdea816ceb8dd969080b2b95f58edbc0
  Author: Peter Lieven <pl@kamp.de>
  Date:   2022-02-01 (Tue, 01 Feb 2022)

  Changed paths:
    M block/rbd.c

  Log Message:
  -----------
  block/rbd: workaround for ceph issue #53784

librbd had a bug until early 2022 that affected all versions of ceph that
supported fast-diff. This bug results in reporting of incorrect offsets
if the offset parameter to rbd_diff_iterate2 is not object aligned.

This patch works around this bug for pre Quincy versions of librbd.

Fixes: 0347a8fd4c3faaedf119be04c197804be40a384b
Cc: qemu-stable@nongnu.org
Signed-off-by: Peter Lieven <pl@kamp.de>
Message-Id: <20220113144426.4036493-3-pl@kamp.de>
Reviewed-by: Ilya Dryomov <idryomov@gmail.com>
Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>
Tested-by: Stefano Garzarella <sgarzare@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>


  Commit: 47cc1a3655135b89fa75c2824fbddd29df874612
      
https://github.com/qemu/qemu/commit/47cc1a3655135b89fa75c2824fbddd29df874612
  Author: Peter Maydell <peter.maydell@linaro.org>
  Date:   2022-02-01 (Tue, 01 Feb 2022)

  Changed paths:
    M block.c
    M block/export/fuse.c
    M block/export/vhost-user-blk-server.c
    M block/rbd.c
    M docs/tools/qemu-img.rst
    M docs/tools/qemu-storage-daemon.rst
    M include/qemu/vhost-user-server.h
    M qemu-img-cmds.hx
    M storage-daemon/qemu-storage-daemon.c
    M util/vhost-user-server.c

  Log Message:
  -----------
  Merge remote-tracking branch 'remotes/kwolf-gitlab/tags/for-upstream' into 
staging

Block layer patches

- rbd: fix handling of holes in .bdrv_co_block_status
- Fix potential crash in bdrv_set_backing_hd()
- vhost-user-blk export: Fix shutdown with requests in flight
- FUSE export: Fix build failure on FreeBSD
- Documentation improvements

# gpg: Signature made Tue 01 Feb 2022 15:14:24 GMT
# 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

* remotes/kwolf-gitlab/tags/for-upstream:
  block/rbd: workaround for ceph issue #53784
  block/rbd: fix handling of holes in .bdrv_co_block_status
  qemu-img: Unify [-b [-F]] documentation
  qsd: Document fuse's allow-other option
  block.h: remove outdated comment
  block/export/fuse: Fix build failure on FreeBSD
  block/export/fuse: Rearrange if-else-if ladder in fuse_fallocate()
  block/export: Fix vhost-user-blk shutdown with requests in flight
  block: bdrv_set_backing_hd(): use drained section
  qemu-storage-daemon: Fix typo in vhost-user-blk help

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>


Compare: https://github.com/qemu/qemu/compare/3bbe296c1c7a...47cc1a365513



reply via email to

[Prev in Thread] Current Thread [Next in Thread]