[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-block] [PULL 32/76] m25p80: add missing blk_attach_dev_nofail
From: |
Kevin Wolf |
Subject: |
[Qemu-block] [PULL 32/76] m25p80: add missing blk_attach_dev_nofail |
Date: |
Tue, 28 Apr 2015 17:00:14 +0200 |
From: Paolo Bonzini <address@hidden>
Of the block devices that poked into -drive options via drive_get_next,
m25p80 was the only one who also did not attach itself to the BlockBackend.
Since sd does it, and all other devices go through a "drive" property,
with this change all block backends attached to the guest will have a
non-NULL result for blk_get_attached_dev().
Signed-off-by: Paolo Bonzini <address@hidden>
Reviewed-by: Peter Crosthwaite <address@hidden>
Message-id: address@hidden
Signed-off-by: Stefan Hajnoczi <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>
---
hw/block/m25p80.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/hw/block/m25p80.c b/hw/block/m25p80.c
index afe243b..728e384 100644
--- a/hw/block/m25p80.c
+++ b/hw/block/m25p80.c
@@ -629,6 +629,7 @@ static int m25p80_init(SSISlave *ss)
if (dinfo) {
DB_PRINT_L(0, "Binding to IF_MTD drive\n");
s->blk = blk_by_legacy_dinfo(dinfo);
+ blk_attach_dev_nofail(s->blk, s);
/* FIXME: Move to late init */
if (blk_read(s->blk, 0, s->storage,
--
1.8.3.1
- [Qemu-block] [PULL 21/76] thread-pool: clean up thread_pool_completion_bh(), (continued)
- [Qemu-block] [PULL 21/76] thread-pool: clean up thread_pool_completion_bh(), Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 22/76] scripts: add 'qemu coroutine' command to qemu-gdb.py, Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 25/76] MAINTAINERS: Add Fam Zheng as Null block driver maintainer, Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 24/76] block/null: Support reopen, Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 23/76] block/null: Latency simulation by adding new option "latency-ns", Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 26/76] blockjob: Allow nested pause, Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 27/76] block: Pause block jobs in bdrv_drain_all, Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 28/76] qemu-iotests: Test that "stop" doesn't drain block jobs, Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 31/76] virtio_blk: comment fix, Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 29/76] blockjob: Update function name in comments, Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 32/76] m25p80: add missing blk_attach_dev_nofail,
Kevin Wolf <=
- [Qemu-block] [PULL 30/76] block: avoid unnecessary bottom halves, Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 33/76] m25p80: fix s->blk usage before assignment, Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 34/76] block: document block-stream in qmp-commands.hx, Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 35/76] block: add bdrv_get_device_or_node_name(), Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 36/76] block: use bdrv_get_device_or_node_name() in error messages, Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 37/76] block: add 'node-name' field to BLOCK_IMAGE_CORRUPTED, Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 38/76] Revert "hmp: fix crash in 'info block -n -v'", Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 39/76] qmp: fill in the image field in BlockDeviceInfo, Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 40/76] block/iscsi: do not forget to logout from target, Kevin Wolf, 2015/04/28
- [Qemu-block] [PULL 41/76] block/iscsi: change all iscsilun properties from uint8_t to bool, Kevin Wolf, 2015/04/28