qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v2] block: per caller dirty bitmap


From: Paolo Bonzini
Subject: Re: [Qemu-devel] [PATCH v2] block: per caller dirty bitmap
Date: Mon, 04 Nov 2013 11:55:47 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130923 Thunderbird/17.0.9

Il 04/11/2013 11:47, Fam Zheng ha scritto:
>>>
>>> -void bdrv_set_dirty_tracking(BlockDriverState *bs, int granularity);
>>> -int bdrv_get_dirty(BlockDriverState *bs, int64_t sector);
>>> +typedef struct BdrvDirtyBitmap BdrvDirtyBitmap;
>>> +BdrvDirtyBitmap *bdrv_create_dirty_bitmap(BlockDriverState *bs, int
>>> granularity);
>>> +void bdrv_release_dirty_bitmap(BlockDriverState *bs, BdrvDirtyBitmap
>>> *bitmap);
>>> +int bdrv_get_dirty(BlockDriverState *bs, BdrvDirtyBitmap *bitmap,
>>> int64_t sector);
>>>   void bdrv_set_dirty(BlockDriverState *bs, int64_t cur_sector, int
>>> nr_sectors);
>>>   void bdrv_reset_dirty(BlockDriverState *bs, int64_t cur_sector, int
>>> nr_sectors);
>>> -void bdrv_dirty_iter_init(BlockDriverState *bs, struct HBitmapIter
>>> *hbi);
>>> -int64_t bdrv_get_dirty_count(BlockDriverState *bs);
>>> +void bdrv_dirty_iter_init(BlockDriverState *bs,
>>> +                          BdrvDirtyBitmap *bitmap, struct
>>> HBitmapIter *hbi);
>>> +int64_t bdrv_get_dirty_count(BlockDriverState *bs, BdrvDirtyBitmap
>>> *bitmap);
>>>     void bdrv_enable_copy_on_read(BlockDriverState *bs);
>>>   void bdrv_disable_copy_on_read(BlockDriverState *bs);
>> You do not really need the BDS argument to the functions, do you?  (Or
>> do you have other plans?)
> 
> I just wanted to keep the pattern of those bdrv_* family, no other plans
> for it.

Kevin, Stefan, any second opinions?

Paolo



reply via email to

[Prev in Thread] Current Thread [Next in Thread]