[dm-devel] [PATCH] dm-thin: don't send discards to shared blocks

Joe Thornber thornber at redhat.com
Wed Jul 18 12:15:22 UTC 2012


Ack, but ...

On Mon, Jul 16, 2012 at 06:39:33PM -0400, Mikulas Patocka wrote:
> --- linux-3.5-rc6-fast.orig/drivers/md/dm-thin.c	2012-07-16 21:47:46.000000000 +0200
> +++ linux-3.5-rc6-fast/drivers/md/dm-thin.c	2012-07-17 00:35:25.000000000 +0200
> @@ -1259,7 +1259,10 @@ static void process_discard(struct thin_
>  
>  			cell_release_singleton(cell, bio);
>  			cell_release_singleton(cell2, bio);
> -			remap_and_issue(tc, bio, lookup_result.block);
> +			if ((!lookup_result.shared) & pool->pf.discard_passdown)

... I'd rather a logical && there.

- Joe




More information about the dm-devel mailing list