Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752016AbbGMQdN (ORCPT ); Mon, 13 Jul 2015 12:33:13 -0400 Received: from youngberry.canonical.com ([91.189.89.112]:52042 "EHLO youngberry.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751140AbbGMQdM (ORCPT ); Mon, 13 Jul 2015 12:33:12 -0400 Message-ID: <55A3E843.9080209@canonical.com> Date: Mon, 13 Jul 2015 12:33:07 -0400 From: Joseph Salisbury User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: Milan Broz CC: Mike Snitzer , "Martin K. Petersen" , linux-kernel@vger.kernel.org, JBottomley@Parallels.com, Kernel Team , jgarzik@redhat.com Subject: Re: [PATCH] dm-crypt: never use write same (was Re: [v3.7 Regression] [SCSI] sd: Implement support for WRITE SAME) References: <50CB8C74.3090102@canonical.com> <50D0C971.1000907@canonical.com> <20121219195801.GA14456@redhat.com> <50D22766.9090107@redhat.com> <50D22C7F.2020201@redhat.com> <50D23DA3.9060104@canonical.com> In-Reply-To: <50D23DA3.9060104@canonical.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1854 Lines: 61 On 12/19/2012 05:20 PM, Joseph Salisbury wrote: > 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 >> >> --- 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) >> > Great work, Milan. Your patch fixes the bug, stops the panic and > allows dm-crypt to function properly. > > Will you be requesting this in v3.8 ? > > Thanks again, > > Joe > Hi Milan, The Ubuntu kernel has been carrying this patch since the discussion[0] we were having about the bug. I don't see that patch was ever included in mainline. Do you happen to know if this patch is still needed or was the bug we were seeing fixed in some other way? Thanks, Joe [0] https://lists.ubuntu.com/archives/kernel-team/2012-December/023524.html -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/