diff options
author | Markus Armbruster <armbru@redhat.com> | 2010-06-02 18:55:17 +0200 |
---|---|---|
committer | Kevin Wolf <kwolf@redhat.com> | 2010-06-15 09:41:59 +0200 |
commit | abd7f68d081ef5adb425f659c7449149987bf89e (patch) | |
tree | 0bb8f33deaa33cc945b69ef7ba549b07babacb06 /hw | |
parent | 2063392ae5d00a9ea13039f971e2b9e61bd68dbc (diff) |
block: Move error actions from DriveInfo to BlockDriverState
That's where they belong semantically (block device host part), even
though the actions are actually executed by guest device code.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'hw')
-rw-r--r-- | hw/ide/core.c | 2 | ||||
-rw-r--r-- | hw/scsi-disk.c | 2 | ||||
-rw-r--r-- | hw/virtio-blk.c | 3 |
3 files changed, 3 insertions, 4 deletions
diff --git a/hw/ide/core.c b/hw/ide/core.c index 045d18db2b..0b3b7c2e69 100644 --- a/hw/ide/core.c +++ b/hw/ide/core.c @@ -481,7 +481,7 @@ void ide_dma_error(IDEState *s) static int ide_handle_rw_error(IDEState *s, int error, int op) { int is_read = (op & BM_STATUS_RETRY_READ); - BlockInterfaceErrorAction action = drive_get_on_error(s->bs, is_read); + BlockErrorAction action = bdrv_get_on_error(s->bs, is_read); if (action == BLOCK_ERR_IGNORE) { bdrv_mon_event(s->bs, BDRV_ACTION_IGNORE, is_read); diff --git a/hw/scsi-disk.c b/hw/scsi-disk.c index a9bf7d261a..2b3898435c 100644 --- a/hw/scsi-disk.c +++ b/hw/scsi-disk.c @@ -182,7 +182,7 @@ static void scsi_read_data(SCSIDevice *d, uint32_t tag) static int scsi_handle_write_error(SCSIDiskReq *r, int error) { SCSIDiskState *s = DO_UPCAST(SCSIDiskState, qdev, r->req.dev); - BlockInterfaceErrorAction action = drive_get_on_error(s->bs, 0); + BlockErrorAction action = bdrv_get_on_error(s->bs, 0); if (action == BLOCK_ERR_IGNORE) { bdrv_mon_event(s->bs, BDRV_ACTION_IGNORE, 0); diff --git a/hw/virtio-blk.c b/hw/virtio-blk.c index 4cc94f60e5..75878ebe3c 100644 --- a/hw/virtio-blk.c +++ b/hw/virtio-blk.c @@ -58,8 +58,7 @@ static void virtio_blk_req_complete(VirtIOBlockReq *req, int status) static int virtio_blk_handle_rw_error(VirtIOBlockReq *req, int error, int is_read) { - BlockInterfaceErrorAction action = - drive_get_on_error(req->dev->bs, is_read); + BlockErrorAction action = bdrv_get_on_error(req->dev->bs, is_read); VirtIOBlock *s = req->dev; if (action == BLOCK_ERR_IGNORE) { |