mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-02 07:13:54 -06:00
blockdev: Keep track of monitor-owned BDS
As a side effect, we can now make x-blockdev-del's check whether a BDS is actually owned by the monitor explicit. Signed-off-by: Max Reitz <mreitz@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
This commit is contained in:
parent
2c1d04e002
commit
9c4218e957
4 changed files with 37 additions and 1 deletions
|
@ -445,6 +445,8 @@ struct BlockDriverState {
|
|||
QTAILQ_ENTRY(BlockDriverState) device_list;
|
||||
/* element of the list of all BlockDriverStates (all_bdrv_states) */
|
||||
QTAILQ_ENTRY(BlockDriverState) bs_list;
|
||||
/* element of the list of monitor-owned BDS */
|
||||
QTAILQ_ENTRY(BlockDriverState) monitor_list;
|
||||
QLIST_HEAD(, BdrvDirtyBitmap) dirty_bitmaps;
|
||||
int refcnt;
|
||||
|
||||
|
@ -707,4 +709,6 @@ bool bdrv_requests_pending(BlockDriverState *bs);
|
|||
void bdrv_clear_dirty_bitmap(BdrvDirtyBitmap *bitmap, HBitmap **out);
|
||||
void bdrv_undo_clear_dirty_bitmap(BdrvDirtyBitmap *bitmap, HBitmap *in);
|
||||
|
||||
void blockdev_close_all_bdrv_states(void);
|
||||
|
||||
#endif /* BLOCK_INT_H */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue