qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH V19 6/8] add debug event for add-cow


From: Stefan Hajnoczi
Subject: Re: [Qemu-devel] [PATCH V19 6/8] add debug event for add-cow
Date: Wed, 5 Jun 2013 15:35:05 +0200
User-agent: Mutt/1.5.21 (2010-09-15)

On Thu, May 30, 2013 at 06:00:23PM +0800, Dongxu Wang wrote:
> diff --git a/block/block-cache.c b/block/block-cache.c
> index f5d75d1..454269c 100644
> --- a/block/block-cache.c
> +++ b/block/block-cache.c
> @@ -125,7 +125,7 @@ static int block_cache_entry_flush(BlockDriverState *bs, 
> BlockCache *c, int i)
>      } else if (c->table_type == BLOCK_TABLE_L2) {
>          BLKDBG_EVENT(bs->file, BLKDBG_L2_UPDATE);
>      } else if (c->table_type == BLOCK_TABLE_BITMAP) {
> -        BLKDBG_EVENT(bs->file, BLKDBG_COW_WRITE);
> +        BLKDBG_EVENT(bs->file, BLKDBG_ADDCOW_WRITE);
>      }
>  
>      ret = bdrv_pwrite(bs->file, c->entries[i].offset,
> @@ -260,7 +260,7 @@ static int block_cache_do_get(BlockDriverState *bs, 
> BlockCache *c,
>          if (c->table_type == BLOCK_TABLE_L2) {
>              BLKDBG_EVENT(bs->file, BLKDBG_L2_LOAD);
>          } else if (c->table_type == BLOCK_TABLE_BITMAP) {
> -            BLKDBG_EVENT(bs->file, BLKDBG_COW_READ);
> +            BLKDBG_EVENT(bs->file, BLKDBG_ADDCOW_READ);
>          }
>  
>          ret = bdrv_pread(bs->file, offset, c->entries[i].table,

These patches are in the wrong order.  The previous patch should not use
the incorrect BLKDBG_COW_READ/BLKDBG_COW_WRITE values.

Put the blkdebug.c and block.h changes from this patch before the
previous patch so block-cache.c can use
BLKDBG_ADDCOW_READ/BLKDBG_ADDCOW_WRITE from the start.



reply via email to

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