1. 13 12月, 2014 4 次提交
  2. 20 10月, 2014 2 次提交
  3. 22 9月, 2014 2 次提交
  4. 29 8月, 2014 1 次提交
    • S
      linux-aio: avoid deadlock in nested aio_poll() calls · 2cdff7f6
      Stefan Hajnoczi 提交于
      If two Linux AIO request completions are fetched in the same
      io_getevents() call, QEMU will deadlock if request A's callback waits
      for request B to complete using an aio_poll() loop.  This was reported
      to happen with the mirror blockjob.
      
      This patch moves completion processing into a BH and makes it resumable.
      Nested event loops can resume completion processing so that request B
      will complete and the deadlock will not occur.
      
      Cc: Kevin Wolf <kwolf@redhat.com>
      Cc: Paolo Bonzini <pbonzini@redhat.com>
      Cc: Ming Lei <ming.lei@canonical.com>
      Cc: Marcin Gibuła <m.gibula@beyond.pl>
      Reported-by: NMarcin Gibuła <m.gibula@beyond.pl>
      Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
      Tested-by: NMarcin Gibuła <m.gibula@beyond.pl>
      2cdff7f6
  5. 15 7月, 2014 1 次提交
  6. 07 7月, 2014 1 次提交
  7. 04 6月, 2014 2 次提交
  8. 19 8月, 2013 2 次提交
  9. 19 12月, 2012 2 次提交
  10. 15 11月, 2012 1 次提交
  11. 31 10月, 2012 2 次提交
  12. 30 10月, 2012 2 次提交
  13. 12 6月, 2012 1 次提交
    • M
      consolidate qemu_iovec_memset{,_skip}() into single function and use existing iov_memset() · 3d9b4925
      Michael Tokarev 提交于
      This patch combines two functions into one, and replaces
      the implementation with already existing iov_memset() from
      iov.c.
      
      The new prototype of qemu_iovec_memset():
        size_t qemu_iovec_memset(qiov, size_t offset, int fillc, size_t bytes)
      It is different from former qemu_iovec_memset_skip(), and
      I want to make other functions to be consistent with it
      too: first how much to skip, second what, and 3rd how many
      of it.  It also returns actual number of bytes filled in,
      which may be less than the requested `bytes' if qiov is
      smaller than offset+bytes, in the same way iov_memset()
      does.
      
      While at it, use utility function iov_memset() from
      iov.h in posix-aio-compat.c, where qiov was used.
      Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
      3d9b4925
  14. 19 4月, 2012 1 次提交
  15. 05 4月, 2012 1 次提交
  16. 15 12月, 2011 1 次提交
  17. 14 10月, 2011 1 次提交
    • K
      linux-aio: Allow reads beyond the end of growable images · b161e2e4
      Kevin Wolf 提交于
      This is the linux-aio version of commits 22afa7b5 (raw-posix, synchronous) and
      ba1d1afd (posix-aio-compat). Reads now produce zeros after the end of file
      instead of failing or resulting in short reads, making linux-aio compatible
      with the behaviour of synchronous raw-posix requests and posix-aio-compat.
      
      The problem can be reproduced like this:
      
      dd if=/dev/zero of=/tmp/test.raw bs=1 count=1234
      ./qemu-io -k -n -g -c 'read -p 1024 512' /tmp/test.raw
      
      Previously, the result of this was 'read failed: Invalid argument', now the
      read completes successfully.
      Signed-off-by: NKevin Wolf <kwolf@redhat.com>
      Reviewed-by: NStefan Hajnoczi <stefanha@linux.vnet.ibm.com>
      b161e2e4
  18. 11 10月, 2011 1 次提交
  19. 20 9月, 2011 1 次提交
  20. 06 9月, 2011 1 次提交
  21. 21 8月, 2011 1 次提交
  22. 02 8月, 2011 1 次提交
    • K
      async: Remove AsyncContext · 384acbf4
      Kevin Wolf 提交于
      The purpose of AsyncContexts was to protect qcow and qcow2 against reentrancy
      during an emulated bdrv_read/write (which includes a qemu_aio_wait() call and
      can run AIO callbacks of different requests if it weren't for AsyncContexts).
      
      Now both qcow and qcow2 are protected by CoMutexes and AsyncContexts can be
      removed.
      Signed-off-by: NKevin Wolf <kwolf@redhat.com>
      384acbf4
  23. 23 4月, 2010 1 次提交
  24. 28 10月, 2009 2 次提交
  25. 28 8月, 2009 1 次提交
    • C
      raw-posix: add Linux native AIO support · 5c6c3a6c
      Christoph Hellwig 提交于
      Now that do have a nicer interface to work against we can add Linux native
      AIO support.  It's an extremly thing layer just setting up an iocb for
      the io_submit system call in the submission path, and registering an
      eventfd with the qemu poll handler to do complete the iocbs directly
      from there.
      
      This started out based on Anthony's earlier AIO patch, but after
      estimated 42,000 rewrites and just as many build system changes
      there's not much left of it.
      
      To enable native kernel aio use the aio=native sub-command on the
      drive command line.  I have also added an option to qemu-io to
      test the aio support without needing a guest.
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      5c6c3a6c