]> git.proxmox.com Git - mirror_qemu.git/commit - block.c
blkdebug: Add events and rules
authorKevin Wolf <kwolf@redhat.com>
Mon, 15 Mar 2010 16:27:00 +0000 (17:27 +0100)
committerKevin Wolf <kwolf@redhat.com>
Fri, 23 Apr 2010 14:08:46 +0000 (16:08 +0200)
commit8b9b0cc2fd1b866c0ce6c7f7385d840aad8b4c2c
tree9c3d6512caa4ffd0366ca6fe6231042b3e89e943
parent25920d6ad61b078a69b6ba401d4d6cd46ce83804
blkdebug: Add events and rules

Block drivers can trigger a blkdebug event whenever they reach a place where it
could be useful to inject an error for testing/debugging purposes.

Rules are read from a blkdebug config file and describe which action is taken
when an event is triggered. For now this is only injecting an error (with a few
options) or changing the state (which is an integer). Rules can be declared to
be active only in a specific state; this way later rules can distiguish on
which path we came to trigger their event.

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