lkml.org 
[lkml]   [2012]   [Dec]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] dm-crypt: never use write same (was Re: [v3.7 Regression] [SCSI] sd: Implement support for WRITE SAME)
On 12/19/2012 04:07 PM, Milan Broz wrote:
> Does this help?
>
> dm-crypt: never use write same
>
> Ciphertext device is not compatible with WRITE SAME,
> disable it for all dmcrypt devices.
>
> Signed-off-by: Milan Broz <mbroz@redhat.com>
>
> --- a/drivers/md/dm-crypt.c
> +++ b/drivers/md/dm-crypt.c
> @@ -1844,6 +1844,12 @@ static int crypt_iterate_devices(struct dm_target *ti,
> return fn(ti, cc->dev, cc->start, ti->len, data);
> }
>
> +static void crypt_io_hints(struct dm_target *ti,
> + struct queue_limits *limits)
> +{
> + limits->max_write_same_sectors = 0;
> +}
> +
> static struct target_type crypt_target = {
> .name = "crypt",
> .version = {1, 11, 0},
> @@ -1858,6 +1864,7 @@ static struct target_type crypt_target = {
> .message = crypt_message,
> .merge = crypt_merge,
> .iterate_devices = crypt_iterate_devices,
> + .io_hints = crypt_io_hints,
> };
>
> static int __init dm_crypt_init(void)
>
I'll give it a spin right now. Thanks for the quick work!


\
 
 \ /
  Last update: 2012-12-19 22:21    [W:0.144 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site