]> git.proxmox.com Git - mirror_qemu.git/commit
blkdebug: Implement suspend/resume of AIO requests
authorKevin Wolf <kwolf@redhat.com>
Thu, 6 Dec 2012 13:32:57 +0000 (14:32 +0100)
committerKevin Wolf <kwolf@redhat.com>
Wed, 12 Dec 2012 11:33:48 +0000 (12:33 +0100)
commit3c90c65d7adab49a41952ee14e1d65f81355e408
tree932fd9a9e32c5f26fcf19ca8aa5fbecd60cd780e
parent9e35542b0fc3871caac15ccd57548b99df2c94b7
blkdebug: Implement suspend/resume of AIO requests

This allows more systematic AIO testing. The patch adds three new
operations to blkdebug:

 * Setting a "breakpoint" on a blkdebug event. The next request that
   triggers this breakpoint is suspended and is tagged with a name.
   The breakpoint is removed after a request has triggered it.

 * A suspended request (identified by it's tag) can be resumed

 * It's possible to check whether a suspended request with a given
   tag exists. This can be used for waiting for an event.

Ideally, we would instead tag requests right when they are created and
set breakpoints for individual requests. However, at this point the
block layer doesn't allow this easily, and breakpoints that trigger for
any request already allow a lot of useful testing.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
block/blkdebug.c