qemu-commits
[Top][All Lists]
Advanced

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

[Qemu-commits] [qemu/qemu] f871ab: block: Drain source node in bdrv_repl


From: Peter Maydell
Subject: [Qemu-commits] [qemu/qemu] f871ab: block: Drain source node in bdrv_replace_node()
Date: Tue, 04 Jun 2019 10:00:14 -0700

  Branch: refs/heads/master
  Home:   https://github.com/qemu/qemu
  Commit: f871abd60f4b67547e62c57c9bec19420052be39
      
https://github.com/qemu/qemu/commit/f871abd60f4b67547e62c57c9bec19420052be39
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M block.c

  Log Message:
  -----------
  block: Drain source node in bdrv_replace_node()

Instead of just asserting that no requests are in flight in
bdrv_replace_node(), which is a requirement that most callers ignore, we
can just drain the source node right there. This fixes at least starting
a commit job while I/O is active on the backing chain, but probably
other callers, too.

Having requests in flight on the target node isn't a problem because the
target just gets new parents, but the call path of running requests
isn't modified. So we can just drop this assertion without a replacement.

Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1711643
Signed-off-by: Kevin Wolf <address@hidden>
Reviewed-by: Max Reitz <address@hidden>


  Commit: ac6fb43eae1f5029b51e0a3d975fe2111cc8b976
      
https://github.com/qemu/qemu/commit/ac6fb43eae1f5029b51e0a3d975fe2111cc8b976
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    A tests/qemu-iotests/255
    A tests/qemu-iotests/255.out
    M tests/qemu-iotests/group
    M tests/qemu-iotests/iotests.py

  Log Message:
  -----------
  iotests: Test commit job start with concurrent I/O

This tests that concurrent requests are correctly drained before making
graph modifications instead of running into assertions in
bdrv_replace_node().

Signed-off-by: Kevin Wolf <address@hidden>
Reviewed-by: Max Reitz <address@hidden>


  Commit: 4da26f138db06c9c6d7199d42bd3c2be552cb956
      
https://github.com/qemu/qemu/commit/4da26f138db06c9c6d7199d42bd3c2be552cb956
  Author: John Snow <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M blockdev.c

  Log Message:
  -----------
  blockdev: fix missed target unref for drive-backup

If the bitmap can't be used for whatever reason, we skip putting down
the reference. Fix that.

In practice, this means that if you attempt to gracefully exit QEMU
after a backup command being rejected, bdrv_close_all will fail and
tell you some unpleasant things via assert().

Reported-by: aihua liang <address@hidden>
Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1703916
Signed-off-by: John Snow <address@hidden>
Reviewed-by: Kevin Wolf <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 52f2b8961409be834abaee5189bff2cc9e372851
      
https://github.com/qemu/qemu/commit/52f2b8961409be834abaee5189bff2cc9e372851
  Author: Vladimir Sementsov-Ogievskiy <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    A tests/perf/block/qcow2/convert-blockstatus

  Log Message:
  -----------
  tests/perf: Test lseek influence on qcow2 block-status

Block layer may recursively check block_status in file child of qcow2,
if qcow2 driver returned DATA. There are several test cases to check
influence of lseek on block_status performance. To see real difference
run on tmpfs.

Tests originally created by Kevin, I just refactored and put them
together into one executable file with simple output.

Signed-off-by: Vladimir Sementsov-Ogievskiy <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 69f47505ee66afaa513305de0c1895a224e52c45
      
https://github.com/qemu/qemu/commit/69f47505ee66afaa513305de0c1895a224e52c45
  Author: Vladimir Sementsov-Ogievskiy <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M block/io.c
    M block/qcow2-refcount.c
    M block/qcow2.c
    M block/qcow2.h
    M include/block/block.h
    M tests/qemu-iotests/102
    M tests/qemu-iotests/102.out
    M tests/qemu-iotests/141.out
    M tests/qemu-iotests/144.out

  Log Message:
  -----------
  block: avoid recursive block_status call if possible

drv_co_block_status digs bs->file for additional, more accurate search
for hole inside region, reported as DATA by bs since 5daa74a6ebc.

This accuracy is not free: assume we have qcow2 disk. Actually, qcow2
knows, where are holes and where is data. But every block_status
request calls lseek additionally. Assume a big disk, full of
data, in any iterative copying block job (or img convert) we'll call
lseek(HOLE) on every iteration, and each of these lseeks will have to
iterate through all metadata up to the end of file. It's obviously
ineffective behavior. And for many scenarios we don't need this lseek
at all.

However, lseek is needed when we have metadata-preallocated image.

So, let's detect metadata-preallocation case and don't dig qcow2's
protocol file in other cases.

The idea is to compare allocation size in POV of filesystem with
allocations size in POV of Qcow2 (by refcounts). If allocation in fs is
significantly lower, consider it as metadata-preallocation case.

102 iotest changed, as our detector can't detect shrinked file as
metadata-preallocation, which don't seem to be wrong, as with metadata
preallocation we always have valid file length.

Two other iotests have a slight change in their QMP output sequence:
Active 'block-commit' returns earlier because the job coroutine yields
earlier on a blocking operation. This operation is loading the refcount
blocks in qcow2_detect_metadata_preallocation().

Suggested-by: Denis V. Lunev <address@hidden>
Signed-off-by: Vladimir Sementsov-Ogievskiy <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 5cb2737e925042e6c7cd3fb0b01313950b03cddf
      
https://github.com/qemu/qemu/commit/5cb2737e925042e6c7cd3fb0b01313950b03cddf
  Author: Max Reitz <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M block/io.c

  Log Message:
  -----------
  block/io: Delay decrementing the quiesce_counter

When ending a drained section, bdrv_do_drained_end() currently first
decrements the quiesce_counter, and only then actually ends the drain.

The bdrv_drain_invoke(bs, false) call may cause graph changes.  Say the
graph change involves replacing an existing BB's ("blk") BDS
(blk_bs(blk)) by @bs.  Let us introducing the following values:
- bs_oqc = old_quiesce_counter
  (so bs->quiesce_counter == bs_oqc - 1)
- obs_qc = blk_bs(blk)->quiesce_counter (before bdrv_drain_invoke())

Let us assume there is no blk_pread_unthrottled() involved, so
blk->quiesce_counter == obs_qc (before bdrv_drain_invoke()).

Now replacing blk_bs(blk) by @bs will reduce blk->quiesce_counter by
obs_qc (making it 0) and increase it by bs_oqc-1 (making it bs_oqc-1).

bdrv_drain_invoke() returns and we invoke bdrv_parent_drained_end().
This will decrement blk->quiesce_counter by one, so it would be -1 --
were there not an assertion against that in blk_root_drained_end().

We therefore have to keep the quiesce_counter up at least until
bdrv_drain_invoke() returns, so that bdrv_parent_drained_end() does the
right thing for the parents @bs got during bdrv_drain_invoke().

But let us delay it even further, namely until bdrv_parent_drained_end()
returns, because then it mirrors bdrv_do_drained_begin(): There, we
first increment the quiesce_counter, then begin draining the parents,
and then call bdrv_drain_invoke().  It makes sense to let
bdrv_do_drained_end() unravel this exactly in reverse.

Signed-off-by: Max Reitz <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 74f27eadeae799c44d51ba53ffc94807be2b5834
      
https://github.com/qemu/qemu/commit/74f27eadeae799c44d51ba53ffc94807be2b5834
  Author: Max Reitz <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M tests/qemu-iotests/255
    M tests/qemu-iotests/255.out

  Log Message:
  -----------
  iotests: Test cancelling a job and closing the VM

This patch adds a test where we cancel a throttled mirror job and
immediately close the VM before it can be cancelled.  Doing so will
invoke bdrv_drain_all() while the mirror job tries to drain the
throttled node.  When bdrv_drain_all_end() tries to lift its drain on
the throttle node, the job will exit and replace the current root node
of the BB drive0 (which is the job's filter node) by the throttle node.
Before the previous patch, this replacement did not increase drive0's
quiesce_counter by a sufficient amount, so when
bdrv_parent_drained_end() (invoked by bdrv_do_drained_end(), invoked by
bdrv_drain_all_end()) tried to end the drain on all of the throttle
node's parents, it decreased drive0's quiesce_counter below 0 -- which
fails an assertion.

Signed-off-by: Max Reitz <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 2b02fd81ded2f8fefbdacee431fc9fb006f92bc6
      
https://github.com/qemu/qemu/commit/2b02fd81ded2f8fefbdacee431fc9fb006f92bc6
  Author: Julia Suvorova <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M block/linux-aio.c
    M include/block/raw-aio.h

  Log Message:
  -----------
  block/linux-aio: Drop unused BlockAIOCB submission method

Callback-based laio_submit() and laio_cancel() were left after
rewriting Linux AIO backend to coroutines in hope that they would be
used in other code that could bypass coroutines. They can be safely
removed because they have not been used since that time.

Signed-off-by: Julia Suvorova <address@hidden>
Reviewed-by: Stefan Hajnoczi <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 3036a626e9efad8ee5dc178b149184cf87bd06b0
      
https://github.com/qemu/qemu/commit/3036a626e9efad8ee5dc178b149184cf87bd06b0
  Author: Kenneth Heitke <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M hw/block/nvme.c
    M hw/block/nvme.h
    M hw/block/trace-events
    M include/block/nvme.h

  Log Message:
  -----------
  nvme: add Get/Set Feature Timestamp support

Signed-off-by: Kenneth Heitke <address@hidden>
Reviewed-by: Klaus Birkelund Jensen <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 087ba459a222cb022ce79110eebef190b8ec854a
      
https://github.com/qemu/qemu/commit/087ba459a222cb022ce79110eebef190b8ec854a
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M tests/test-block-iothread.c

  Log Message:
  -----------
  test-block-iothread: Check filter node in test_propagate_mirror

Just make the test cover the AioContext of the filter node as well.

Signed-off-by: Kevin Wolf <address@hidden>
Reviewed-by: Eric Blake <address@hidden>


  Commit: 45e92a9011bff4f6660dae1e011083c5790d121b
      
https://github.com/qemu/qemu/commit/45e92a9011bff4f6660dae1e011083c5790d121b
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M nbd/server.c
    M tests/qemu-iotests/240
    M tests/qemu-iotests/240.out

  Log Message:
  -----------
  nbd-server: Call blk_set_allow_aio_context_change()

The NBD server uses an AioContext notifier, so it can tolerate that its
BlockBackend is switched to a different AioContext. Before we start
actually calling bdrv_try_set_aio_context(), which checks for
consistency, outside of test cases, we need to make sure that the NBD
server actually allows this.

Signed-off-by: Kevin Wolf <address@hidden>
Reviewed-by: Eric Blake <address@hidden>


  Commit: 97896a4887a0a29c3314c5f0e9a82e269a6401fc
      
https://github.com/qemu/qemu/commit/97896a4887a0a29c3314c5f0e9a82e269a6401fc
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M block/block-backend.c
    M hw/block/dataplane/virtio-blk.c
    M hw/block/dataplane/xen-block.c
    M hw/scsi/virtio-scsi.c
    M include/sysemu/block-backend.h
    M tests/test-bdrv-drain.c
    M tests/test-block-iothread.c

  Log Message:
  -----------
  block: Add Error to blk_set_aio_context()

Add an Error parameter to blk_set_aio_context() and use
bdrv_child_try_set_aio_context() internally to check whether all
involved nodes can actually support the AioContext switch.

Signed-off-by: Kevin Wolf <address@hidden>


  Commit: d861ab3acf8dcf817e0c2335979b258847b69564
      
https://github.com/qemu/qemu/commit/d861ab3acf8dcf817e0c2335979b258847b69564
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M block.c
    M block/backup.c
    M block/block-backend.c
    M block/commit.c
    M block/crypto.c
    M block/mirror.c
    M block/parallels.c
    M block/qcow.c
    M block/qcow2.c
    M block/qed.c
    M block/sheepdog.c
    M block/vdi.c
    M block/vhdx.c
    M block/vmdk.c
    M block/vpc.c
    M blockdev.c
    M blockjob.c
    M hmp.c
    M hw/block/fdc.c
    M hw/block/xen-block.c
    M hw/core/qdev-properties-system.c
    M hw/ide/qdev.c
    M hw/scsi/scsi-disk.c
    M include/sysemu/block-backend.h
    M migration/block.c
    M nbd/server.c
    M qemu-img.c
    M tests/test-bdrv-drain.c
    M tests/test-bdrv-graph-mod.c
    M tests/test-block-backend.c
    M tests/test-block-iothread.c
    M tests/test-blockjob.c
    M tests/test-throttle.c

  Log Message:
  -----------
  block: Add BlockBackend.ctx

This adds a new parameter to blk_new() which requires its callers to
declare from which AioContext this BlockBackend is going to be used (or
the locks of which AioContext need to be taken anyway).

The given context is only stored and kept up to date when changing
AioContexts. Actually applying the stored AioContext to the root node
is saved for another commit.

Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 307a5f60ebe0506a5b90f323fdcabb4333405484
      
https://github.com/qemu/qemu/commit/307a5f60ebe0506a5b90f323fdcabb4333405484
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M hw/core/qdev-properties-system.c
    M include/hw/block/block.h
    M include/hw/qdev-properties.h

  Log Message:
  -----------
  block: Add qdev_prop_drive_iothread property type

Some qdev block devices have support for iothreads and take care of the
AioContext they are running in, but most devices don't know about any of
this. For the latter category, the qdev drive property must make sure
that their BlockBackend is in the main AioContext.

Unfortunately, while the current code just does the same thing for
devices that do support iothreads, this is not correct and it would show
as soon as we actually try to keep a consistent AioContext assignment
across all nodes and users of a block graph subtree: If a node is
already in a non-default AioContext because of one of its users,
attaching a new device should still be possible if that device can work
in the same AioContext. Switching the node back to the main context
first and only then into the device AioContext causes failure (because
the existing user wouldn't allow the switch to the main context).

So devices that support iothreads need a different kind of drive
property that leaves the node in its current AioContext, but by using
this type, the device promises to check later that it can work with this
context.

This patch adds the qdev infrastructure that allows devices to signal
that they handle iothreads and qdev should leave the AioContext alone.

Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 4f71fb436a6fbec7a7b2360cdba741deeb24be67
      
https://github.com/qemu/qemu/commit/4f71fb436a6fbec7a7b2360cdba741deeb24be67
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M hw/scsi/scsi-disk.c
    M hw/scsi/virtio-scsi.c
    M include/hw/scsi/scsi.h
    M tests/qemu-iotests/240.out

  Log Message:
  -----------
  scsi-disk: Use qdev_prop_drive_iothread

This makes use of qdev_prop_drive_iothread for scsi-disk so that the
disk can be attached to a node that is already in the target AioContext.
We need to check that the HBA actually supports iothreads, otherwise
scsi-disk must make sure that the node is already in the main
AioContext.

This changes the error message for conflicting iothread settings.
Previously, virtio-scsi produced the error message, now it comes from
blk_set_aio_context(). Update a test case accordingly.

Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 132ada80c4a6fea7b67e8bb0a5fd299994d927c6
      
https://github.com/qemu/qemu/commit/132ada80c4a6fea7b67e8bb0a5fd299994d927c6
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M block.c
    M block/block-backend.c
    M blockjob.c
    M include/block/block_int.h
    M tests/test-bdrv-drain.c

  Log Message:
  -----------
  block: Adjust AioContexts when attaching nodes

So far, we only made sure that updating the AioContext of a node
affected the whole subtree. However, if a node is newly attached to a
new parent, we also need to make sure that both the subtree of the node
and the parent are in the same AioContext. This tries to move the new
child node to the parent AioContext and returns an error if this isn't
possible.

BlockBackends now actually apply their AioContext to their root node.

Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 48946d7d64818c349e3e183838f99d8ce32a9b86
      
https://github.com/qemu/qemu/commit/48946d7d64818c349e3e183838f99d8ce32a9b86
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M tests/test-block-iothread.c

  Log Message:
  -----------
  test-block-iothread: Test adding parent to iothread node

Opening a new parent node for a node that has already been moved into a
different AioContext must cause the new parent to move into the same
context.

Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 2e9cdab3000530fdd03df7f0a5d124eaa0ae942f
      
https://github.com/qemu/qemu/commit/2e9cdab3000530fdd03df7f0a5d124eaa0ae942f
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M tests/test-block-iothread.c

  Log Message:
  -----------
  test-block-iothread: BlockBackend AioContext across root node change

Test that BlockBackends preserve their assigned AioContext even when the
root node goes away. Inserting a new root node will move it to the right
AioContext.

Signed-off-by: Kevin Wolf <address@hidden>


  Commit: ad943dcb226a083a0c433ae73737c4834f8cfe74
      
https://github.com/qemu/qemu/commit/ad943dcb226a083a0c433ae73737c4834f8cfe74
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M block.c
    M tests/test-bdrv-drain.c
    M tests/test-block-iothread.c

  Log Message:
  -----------
  block: Move node without parents to main AioContext

A node should only be in a non-default AioContext if a user is attached
to it that requires this. When the last parent of a node is gone, it can
move back to the main AioContext.

Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 8ed7d42fb528d380bb0fda1e91aa1770a1b05cf6
      
https://github.com/qemu/qemu/commit/8ed7d42fb528d380bb0fda1e91aa1770a1b05cf6
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M blockdev.c

  Log Message:
  -----------
  blockdev: Use bdrv_try_set_aio_context() for monitor commands

Monitor commands can handle errors, so they can easily be converted to
using the safer bdrv_try_set_aio_context() function.

Signed-off-by: Kevin Wolf <address@hidden>


  Commit: d0ee0204f400956ab429278f1b459d9af969c4a2
      
https://github.com/qemu/qemu/commit/d0ee0204f400956ab429278f1b459d9af969c4a2
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M block.c
    M block/commit.c
    M block/mirror.c

  Log Message:
  -----------
  block: Remove wrong bdrv_set_aio_context() calls

The mirror and commit block jobs use bdrv_set_aio_context() to move
their filter node into the right AioContext before hooking it up in the
graph. Similarly, bdrv_open_backing_file() explicitly moves the backing
file node into the right AioContext first.

This isn't necessary any more, they get automatically moved into the
right context now when attaching them.

However, in the case of bdrv_open_backing_file() with a node reference,
it's actually not only unnecessary, but even wrong: The unchecked
bdrv_set_aio_context() changes the AioContext of the child node even if
other parents require it to retain the old context. So this is not only
a simplification, but a bug fix, too.

Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1684342
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: edbe36ad0f2fa8876b59bc77991ef00c969247a9
      
https://github.com/qemu/qemu/commit/edbe36ad0f2fa8876b59bc77991ef00c969247a9
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M tests/libqtest.c
    M tests/libqtest.h
    M tests/virtio-scsi-test.c

  Log Message:
  -----------
  virtio-scsi-test: Test attaching new overlay with iothreads

This tests that blockdev-add can correctly add a qcow2 overlay to an
image used by a virtio-scsi disk in an iothread. The interesting point
here is whether the newly added node gets correctly moved into the
iothread AioContext.

If it isn't, we get an assertion failure in virtio-scsi while processing
the next request:

    virtio_scsi_ctx_check: Assertion `blk_get_aio_context(d->conf.blk) == 
s->ctx' failed.

Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 6c8705351ee5b3f2ede8337fc93de320b3d4add6
      
https://github.com/qemu/qemu/commit/6c8705351ee5b3f2ede8337fc93de320b3d4add6
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M tests/qemu-iotests/051
    M tests/qemu-iotests/051.out
    M tests/qemu-iotests/051.pc.out

  Log Message:
  -----------
  iotests: Attach new devices to node in non-default iothread

This tests that devices refuse to be attached to a node that has already
been moved to a different iothread if they can't be or aren't configured
to work in the same iothread.

Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 26bf15e441d9d0aa7715bac28ef6a3f25a034df3
      
https://github.com/qemu/qemu/commit/26bf15e441d9d0aa7715bac28ef6a3f25a034df3
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M tests/test-bdrv-drain.c

  Log Message:
  -----------
  test-bdrv-drain: Use bdrv_try_set_aio_context()

No reason to use the unchecked version in tests, even more so when these
are the last callers of bdrv_set_aio_context() outside of block.c.

Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 42a65f02f9b380bd8074882d5844d4ea033389cc
      
https://github.com/qemu/qemu/commit/42a65f02f9b380bd8074882d5844d4ea033389cc
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M block.c
    M docs/devel/multiple-iothreads.txt
    M include/block/block.h

  Log Message:
  -----------
  block: Remove bdrv_set_aio_context()

All callers of bdrv_set_aio_context() are eliminated now, they have
moved to bdrv_try_set_aio_context() and related safe functions. Remove
bdrv_set_aio_context().

With this, we can now know that the .set_aio_ctx callback must be
present in bdrv_set_aio_context_ignore() because
bdrv_can_set_aio_context() would have returned false previously, so
instead of checking the condition, we can assert it.

Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 1477b6c803491cd1146a8858bf5cf8159913054d
      
https://github.com/qemu/qemu/commit/1477b6c803491cd1146a8858bf5cf8159913054d
  Author: Vladimir Sementsov-Ogievskiy <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M block/qcow2-refcount.c
    M block/trace-events

  Log Message:
  -----------
  block/qcow2-refcount: add trace-point to qcow2_process_discards

Let's at least trace ignored failure.

Signed-off-by: Vladimir Sementsov-Ogievskiy <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: d93e57268892d555d7c71ec30b25276b0d8132b6
      
https://github.com/qemu/qemu/commit/d93e57268892d555d7c71ec30b25276b0d8132b6
  Author: Vladimir Sementsov-Ogievskiy <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M block/io.c
    M include/block/block.h

  Log Message:
  -----------
  block/io: bdrv_pdiscard: support int64_t bytes parameter

This fixes at least one overflow in qcow2_process_discards, which
passes 64bit region length to bdrv_pdiscard where bytes (or sectors in
the past) parameter is int since its introduction in 0b919fae.

Signed-off-by: Vladimir Sementsov-Ogievskiy <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 3dd3e248eb65e58979b5fa3cb1855c758c4fbe61
      
https://github.com/qemu/qemu/commit/3dd3e248eb65e58979b5fa3cb1855c758c4fbe61
  Author: Vladimir Sementsov-Ogievskiy <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    A tests/qemu-iotests/250
    A tests/qemu-iotests/250.out
    M tests/qemu-iotests/group

  Log Message:
  -----------
  iotests: test big qcow2 shrink

This test checks bug in qcow2_process_discards, fixed by previous
commit.

Signed-off-by: Vladimir Sementsov-Ogievskiy <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 11ba81c3cde0bc070cced6e8ef2835fab4fe90c8
      
https://github.com/qemu/qemu/commit/11ba81c3cde0bc070cced6e8ef2835fab4fe90c8
  Author: Kevin Wolf <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M tests/qemu-iotests/check

  Log Message:
  -----------
  iotests: Fix duplicated diff output on failure

Commit 70ff5b07 wanted to move the diff between actual and reference
output to the end after printing the test result line. It really only
copied it, though, so the diff is now displayed twice. Remove the old
one.

Fixes: 70ff5b07fcdd378180ad2d5cc0b0d5e67e7ef325
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 47fbad45d47af8af784bb12a5719489edcd89b4c
      
https://github.com/qemu/qemu/commit/47fbad45d47af8af784bb12a5719489edcd89b4c
  Author: Peter Maydell <address@hidden>
  Date:   2019-06-04 (Tue, 04 Jun 2019)

  Changed paths:
    M block.c
    M block/backup.c
    M block/block-backend.c
    M block/commit.c
    M block/crypto.c
    M block/io.c
    M block/linux-aio.c
    M block/mirror.c
    M block/parallels.c
    M block/qcow.c
    M block/qcow2-refcount.c
    M block/qcow2.c
    M block/qcow2.h
    M block/qed.c
    M block/sheepdog.c
    M block/trace-events
    M block/vdi.c
    M block/vhdx.c
    M block/vmdk.c
    M block/vpc.c
    M blockdev.c
    M blockjob.c
    M docs/devel/multiple-iothreads.txt
    M hmp.c
    M hw/block/dataplane/virtio-blk.c
    M hw/block/dataplane/xen-block.c
    M hw/block/fdc.c
    M hw/block/nvme.c
    M hw/block/nvme.h
    M hw/block/trace-events
    M hw/block/xen-block.c
    M hw/core/qdev-properties-system.c
    M hw/ide/qdev.c
    M hw/scsi/scsi-disk.c
    M hw/scsi/virtio-scsi.c
    M include/block/block.h
    M include/block/block_int.h
    M include/block/nvme.h
    M include/block/raw-aio.h
    M include/hw/block/block.h
    M include/hw/qdev-properties.h
    M include/hw/scsi/scsi.h
    M include/sysemu/block-backend.h
    M migration/block.c
    M nbd/server.c
    M qemu-img.c
    M tests/libqtest.c
    M tests/libqtest.h
    A tests/perf/block/qcow2/convert-blockstatus
    M tests/qemu-iotests/051
    M tests/qemu-iotests/051.out
    M tests/qemu-iotests/051.pc.out
    M tests/qemu-iotests/102
    M tests/qemu-iotests/102.out
    M tests/qemu-iotests/141.out
    M tests/qemu-iotests/144.out
    M tests/qemu-iotests/240
    M tests/qemu-iotests/240.out
    A tests/qemu-iotests/250
    A tests/qemu-iotests/250.out
    A tests/qemu-iotests/255
    A tests/qemu-iotests/255.out
    M tests/qemu-iotests/check
    M tests/qemu-iotests/group
    M tests/qemu-iotests/iotests.py
    M tests/test-bdrv-drain.c
    M tests/test-bdrv-graph-mod.c
    M tests/test-block-backend.c
    M tests/test-block-iothread.c
    M tests/test-blockjob.c
    M tests/test-throttle.c
    M tests/virtio-scsi-test.c

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

Block layer patches:

- block: AioContext management, part 2
- Avoid recursive block_status call (i.e. lseek() calls) if possible
- linux-aio: Drop unused BlockAIOCB submission method
- nvme: add Get/Set Feature Timestamp support
- Fix crash on commit job start with active I/O on base node
- Fix crash in bdrv_drained_end
- Fix integer overflow in qcow2 discard

# gpg: Signature made Tue 04 Jun 2019 16:20:02 BST
# gpg:                using RSA key 7F09B272C88F2FD6
# gpg: Good signature from "Kevin Wolf <address@hidden>" [full]
# Primary key fingerprint: DC3D EB15 9A9A F95D 3D74  56FE 7F09 B272 C88F 2FD6

* remotes/kevin/tags/for-upstream: (29 commits)
  iotests: Fix duplicated diff output on failure
  iotests: test big qcow2 shrink
  block/io: bdrv_pdiscard: support int64_t bytes parameter
  block/qcow2-refcount: add trace-point to qcow2_process_discards
  block: Remove bdrv_set_aio_context()
  test-bdrv-drain: Use bdrv_try_set_aio_context()
  iotests: Attach new devices to node in non-default iothread
  virtio-scsi-test: Test attaching new overlay with iothreads
  block: Remove wrong bdrv_set_aio_context() calls
  blockdev: Use bdrv_try_set_aio_context() for monitor commands
  block: Move node without parents to main AioContext
  test-block-iothread: BlockBackend AioContext across root node change
  test-block-iothread: Test adding parent to iothread node
  block: Adjust AioContexts when attaching nodes
  scsi-disk: Use qdev_prop_drive_iothread
  block: Add qdev_prop_drive_iothread property type
  block: Add BlockBackend.ctx
  block: Add Error to blk_set_aio_context()
  nbd-server: Call blk_set_allow_aio_context_change()
  test-block-iothread: Check filter node in test_propagate_mirror
  ...

Signed-off-by: Peter Maydell <address@hidden>


Compare: https://github.com/qemu/qemu/compare/e2a58ff493a2...47fbad45d47a



reply via email to

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