1. 31 8月, 2017 31 次提交
  2. 25 8月, 2017 1 次提交
  3. 24 8月, 2017 2 次提交
    • P
      Merge remote-tracking branch 'remotes/ericb/tags/pull-nbd-2017-08-23' into staging · 1eed3399
      Peter Maydell 提交于
      nbd patches for 2017-08-23
      
      - Fam Zheng: 0/4 block: Fix non-shared storage migration
      - Stefan Hajnoczi: qemu-iotests: add 194 non-shared storage migration test
      - Stefan Hajnoczi: nbd-client: avoid spurious qio_channel_yield() re-entry
      
      # gpg: Signature made Wed 23 Aug 2017 17:22:53 BST
      # gpg:                using RSA key 0xA7A16B4A2527436A
      # gpg: Good signature from "Eric Blake <eblake@redhat.com>"
      # gpg:                 aka "Eric Blake (Free Software Programmer) <ebb9@byu.net>"
      # gpg:                 aka "[jpeg image of size 6874]"
      # Primary key fingerprint: 71C2 CC22 B1C4 6029 27D2  F3AA A7A1 6B4A 2527 436A
      
      * remotes/ericb/tags/pull-nbd-2017-08-23:
        nbd-client: avoid spurious qio_channel_yield() re-entry
        qemu-iotests: add 194 non-shared storage migration test
        block: Update open_flags after ->inactivate() callback
        mirror: Mark target BB as "force allow inactivate"
        block-backend: Allow more "can inactivate" cases
        block-backend: Refactor inactivate check
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      1eed3399
    • S
      nbd-client: avoid spurious qio_channel_yield() re-entry · 40f4a218
      Stefan Hajnoczi 提交于
      The following scenario leads to an assertion failure in
      qio_channel_yield():
      
      1. Request coroutine calls qio_channel_yield() successfully when sending
         would block on the socket.  It is now yielded.
      2. nbd_read_reply_entry() calls nbd_recv_coroutines_enter_all() because
         nbd_receive_reply() failed.
      3. Request coroutine is entered and returns from qio_channel_yield().
         Note that the socket fd handler has not fired yet so
         ioc->write_coroutine is still set.
      4. Request coroutine attempts to send the request body with nbd_rwv()
         but the socket would still block.  qio_channel_yield() is called
         again and assert(!ioc->write_coroutine) is hit.
      
      The problem is that nbd_read_reply_entry() does not distinguish between
      request coroutines that are waiting to receive a reply and those that
      are not.
      
      This patch adds a per-request bool receiving flag so
      nbd_read_reply_entry() can avoid spurious aio_wake() calls.
      Reported-by: NDr. David Alan Gilbert <dgilbert@redhat.com>
      Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
      Message-Id: <20170822125113.5025-1-stefanha@redhat.com>
      Reviewed-by: NVladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
      Tested-by: NEric Blake <eblake@redhat.com>
      Reviewed-by: NPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: NEric Blake <eblake@redhat.com>
      40f4a218
  4. 23 8月, 2017 6 次提交