Re: [Qemu-devel] [sheepdog] [PATCH] sheepdog: implement .bdrv_co_is_allocated

2013-04-22 Thread Liu Yuan
On 04/22/2013 02:01 PM, MORITA Kazutaka wrote: > It looks better to use BDRV_SECTOR_SIZE . I'd suggest preparing > another patch to replace all the SECTOR_SIZE with BDRV_SECTOR_SIZE. > Okay >> > + end = start + (nb_sectors * SECTOR_SIZE) / >> > SD_DATA_OBJ_SIZE; > Using 'start

Re: [Qemu-devel] [sheepdog] [PATCH] sheepdog: implement .bdrv_co_is_allocated

2013-04-21 Thread MORITA Kazutaka
At Thu, 18 Apr 2013 19:48:52 +0800, Liu Yuan wrote: > > +static coroutine_fn int > +sd_co_is_allocated(BlockDriverState *bs, int64_t sector_num, int nb_sectors, > + int *pnum) > +{ > +BDRVSheepdogState *s = bs->opaque; > +SheepdogInode *inode = &s->inode; > +unsigned