From: Kevin Wolf <kwolf@redhat.com>
To: qemu-devel@nongnu.org
Cc: kwolf@redhat.com
Subject: [Qemu-devel] [PATCH 0/7] blkdebug
Date: Mon, 22 Mar 2010 11:00:17 +0100 [thread overview]
Message-ID: <1269252024-5271-1-git-send-email-kwolf@redhat.com> (raw)
This patch series introduces a new block driver which acts as a protocol and
whose purpose it is to fail requests. To be more precise, I want it to fail in
configurable places, so that qemu-iotests can be extended with tests for the
error paths (for example for the case when something with metadata writes goes
wrong deep in qcow2).
It works like this (I think this is self-explanatory):
$ cat /tmp/blkdebug.cfg
[inject-error]
event = "l1_update"
errno = "5"
immediately = "on"
$ qemu-io blkdebug:/tmp/blkdebug.cfg:/tmp/empty.qcow2
qemu-io> read 0 4k
read 4096/4096 bytes at offset 0
4 KiB, 1 ops; 0.0000 sec (195.312 MiB/sec and 50000.0000 ops/sec)
qemu-io> write 0 4k
write failed: Input/output error
Changes in comparison to the RFC:
- Had to rebase qemu-config changes
- Code cleanup (including resolving TODOs and FIXMEs)
- More events all over qcow2
- No debug messages on stderr any more
Kevin Wolf (7):
qemu-config: qemu_read_config_file() reads the normal config file
qemu-config: Make qemu_config_parse more generic
blkdebug: Basic request passthrough
blkdebug: Inject errors
Make qemu-config available for tools
blkdebug: Add events and rules
qcow2: Trigger blkdebug events
Makefile.objs | 6 +-
block.c | 12 ++
block.h | 53 ++++++
block/blkdebug.c | 474 ++++++++++++++++++++++++++++++++++++++++++++++++
block/qcow2-cluster.c | 15 ++
block/qcow2-refcount.c | 18 ++
block/qcow2.c | 6 +
block_int.h | 2 +
hw/qdev-properties.c | 19 ++-
hw/qdev.h | 1 -
qemu-config.c | 48 +++---
qemu-config.h | 4 +-
qemu-tool.c | 4 +
vl.c | 38 ++---
14 files changed, 647 insertions(+), 53 deletions(-)
create mode 100644 block/blkdebug.c
next reply other threads:[~2010-03-22 10:01 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-22 10:00 Kevin Wolf [this message]
2010-03-22 10:00 ` [Qemu-devel] [PATCH 1/7] qemu-config: qemu_read_config_file() reads the normal config file Kevin Wolf
2010-03-22 10:00 ` [Qemu-devel] [PATCH 2/7] qemu-config: Make qemu_config_parse more generic Kevin Wolf
2010-03-22 10:00 ` [Qemu-devel] [PATCH 3/7] blkdebug: Basic request passthrough Kevin Wolf
2010-03-22 10:00 ` [Qemu-devel] [PATCH 4/7] blkdebug: Inject errors Kevin Wolf
2010-03-22 10:00 ` [Qemu-devel] [PATCH 5/7] Make qemu-config available for tools Kevin Wolf
2010-03-22 10:00 ` [Qemu-devel] [PATCH 6/7] blkdebug: Add events and rules Kevin Wolf
2010-03-22 10:00 ` [Qemu-devel] [PATCH 7/7] qcow2: Trigger blkdebug events Kevin Wolf
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1269252024-5271-1-git-send-email-kwolf@redhat.com \
--to=kwolf@redhat.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).