Received: by 2002:a05:6a11:4021:0:0:0:0 with SMTP id ky33csp1377118pxb; Sun, 19 Sep 2021 15:46:04 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwvGqt5LMlgtXPPtbRYe9IlQTqp4z+DKg4CNt1f6u9WM5P9SOPFKrsH/s6Oc7BsxrBZZ4vO X-Received: by 2002:a6b:c3ce:: with SMTP id t197mr16226461iof.159.1632091564631; Sun, 19 Sep 2021 15:46:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1632091564; cv=none; d=google.com; s=arc-20160816; b=d7tLoZ8MsK6Zir/aSfhYupXo/rKHpQkFKhxyq0d8/8XBLnIMNggx12MdezAF6e3XMv +6fKFN99ftMUhHBvUoUFn1m8F0XjrkjEKn8eLqDkEj9CTv2hwwYZOKdkhkyrQT9sTla6 Kwh58M4lw35CgtUdbP7Fw5SO3EMg16ecyR4iiTFoXvg7sIKI0+hIwMBvM5m8EUgqgiIW nslQZlo1JH1o1JZuAn61oHkWUbbu2l4AvR6gqbdDaPyBkWxrLTCUFWJ5QO2EhWj9uGMp eOFAY5O/DCIZKk5cTY7EpC9VLCvoeY3sUwNsuWhvfnoag+fSfgcKlPQZ9vk31V0xjHu1 BcqA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=G9A/ZW/hYr0iV04kgVzIKko+q+g2fbtqUk/FZXyEAQM=; b=aP4txjwjF6eiRrrJE/SZpFCP2SojdKCJBwoWKD7OP2pi323aVw436k2mLCpME0MKfz 7LOsf/0ekqAIeXAb1ArlVKM1D4lrV53x7P1uMxTdZgGfUlmSJrMPNndCYW05ux43xcKS 5YhDLDxXhzFUyDVE9BuA9WPWrEr5VgbErM1vBkWSNTemtWk1lBP1Lh9L7SqDZFrop+QY X+wdDLiACQgMZtQ/Dd2ulz5o9MIQFySNF3cgpuCTVZdQftBuwL5D4V7w8hNRBZPmmoLm gJDmwOTvO7eOJ1jBQd6JxirywHjW6WmRa8tyqV/1w0t6WLWSF1NQoxuuHHJzzBYOre4q AGng== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b="M/kWPRcg"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id s24si11631774jan.84.2021.09.19.15.45.36; Sun, 19 Sep 2021 15:46:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b="M/kWPRcg"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234052AbhISQwt (ORCPT + 99 others); Sun, 19 Sep 2021 12:52:49 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:32914 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231449AbhISQws (ORCPT ); Sun, 19 Sep 2021 12:52:48 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1632070282; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=G9A/ZW/hYr0iV04kgVzIKko+q+g2fbtqUk/FZXyEAQM=; b=M/kWPRcgI2nPkaSD6YKvuBHIsK7UwlHeYGwjvPTD0UouJylMX3xdJAK+nvaLlJNb5DILXR uioQL+yiPPquknz6R9hFbqXrBRaFo106oICifJy6nlR6XTZrBo70dT1rbgllOBQtdAw/hU IKjDup70BQE+6WcSfPYeqsV/9IFO3e4= Received: from mail-ed1-f69.google.com (mail-ed1-f69.google.com [209.85.208.69]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-294-rhlz5vU0NdSdMhkCviwjfQ-1; Sun, 19 Sep 2021 12:51:21 -0400 X-MC-Unique: rhlz5vU0NdSdMhkCviwjfQ-1 Received: by mail-ed1-f69.google.com with SMTP id b7-20020a50e787000000b003d59cb1a923so12690703edn.5 for ; Sun, 19 Sep 2021 09:51:21 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=G9A/ZW/hYr0iV04kgVzIKko+q+g2fbtqUk/FZXyEAQM=; b=NRtS8coYyV6AxHNWlXzZOdM2Q9jTHCfJ5uuheXfAucCRhQ8OGAorrnq1c2ZJUxBVX+ icQGx9Ri84Nx7QBEp/OV9MsXVdyPPCwnKPJA6XxrrzllC2U0B/WpX5kLVdc9XQ6/0vI/ rk0h6iLnwPk+j1UvDu6iBYv9pOTjFCTABKvSNfLm6l+aE1/kpo2Jh3hGFn+U8xlJhD1x GOCuMvuBScblKPWmeYnHwXe/j4Lheb9yHdvs3GWsgm9UcZ9FjPLgiSaumVPRDpR0+Zrs r7+IiAqWcntPpaSAmXiqmwvhmh3nEWWRJtlYlyMtr44dqVI1zS26jwMGTPKMLlP6E6Se 3LYA== X-Gm-Message-State: AOAM531Cu41/0ebHbtSqp5LulpSlZ0zEcJRHLa15j0ebFasPwOvxiSeJ SzhoVxvJArvYM++lOe0VCaf2PJdEYi6sq/53F4ZvaBiposIvUzVUYyx5cq6E6KmxbHKx/8f8Zlp oLZGFfr0qRnjdLiHerq8LoJ7x1shYWd18yehqinB0ZxR8yd3XIBU2SbPNtivlzDxJpdjEW8jGxR XG X-Received: by 2002:a17:906:544f:: with SMTP id d15mr24857559ejp.520.1632070280219; Sun, 19 Sep 2021 09:51:20 -0700 (PDT) X-Received: by 2002:a17:906:544f:: with SMTP id d15mr24857543ejp.520.1632070280004; Sun, 19 Sep 2021 09:51:20 -0700 (PDT) Received: from x1.localdomain (2001-1c00-0c1e-bf00-1054-9d19-e0f0-8214.cable.dynamic.v6.ziggo.nl. [2001:1c00:c1e:bf00:1054:9d19:e0f0:8214]) by smtp.gmail.com with ESMTPSA id h8sm5277277ejj.22.2021.09.19.09.51.19 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 19 Sep 2021 09:51:19 -0700 (PDT) Subject: Re: [PATCH v5] libata: Add ATA_HORKAGE_NO_NCQ_ON_AMD for Samsung 860 and 870 SSD. To: Tor Vic , "Martin K. Petersen" Cc: Kate Hsuan , Jens Axboe , Damien Le Moal , linux-ide@vger.kernel.org, linux-kernel@vger.kernel.org References: <20210901151643.13562-1-hpa@redhat.com> <3e26e7a5-0d99-b993-d5ce-aa517e1bf1bb@redhat.com> <238d0841-0f03-928f-5441-89d5c9dcf9b9@redhat.com> <967d7639-fc31-a209-8c21-ea8ab3718de6@redhat.com> <66b4c377-1b17-1972-847e-207620cc9364@mailbox.org> From: Hans de Goede Message-ID: <361d702e-44c4-625f-5b6b-121a4dc07105@redhat.com> Date: Sun, 19 Sep 2021 18:51:18 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 In-Reply-To: <66b4c377-1b17-1972-847e-207620cc9364@mailbox.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, On 9/19/21 6:27 PM, Tor Vic wrote: > > > On 19.09.21 15:27, Hans de Goede wrote: >> Hi Tor, >> >> On 9/19/21 4:24 PM, Tor Vic wrote: >>> Hi, >>> >>> I saw that v2 (?) of this patch has made it into stable, which >>> is quite reasonable given the number of bug reports. >>> Are there any plans to "enhance" this patch once sufficient data >>> on controller support/drive combinations has been collected? >> >> ATM there are no plans to limit these quirks, we have bug >> reports of queued trims being an issue over all usual chip-vendors >> of sata controllers (including more recent AMD models). >> >> Note that unless you have immediate "discard" enabled as an option >> on all layers of your storage stack (dmcrypt, device-mapper/raid, >> filesystem) then this change will not impact you at all. > > Is that the "discard" mount option? > I added this to one of the partitions residing on my 860 Evo, > reverted the patch, and it still seems to work just fine. > >   $ mount | grep sdb > > >   /dev/sdb1 on /mnt/vbox type ext4 (rw,nosuid,nodev,noatime,discard) > > Is there another place where discard has to be enabled? No since you do not seem to be using dmcrypt/raid/lvm that should do the trick. Except that it sounds like this is a partition carrying vm images. Those never delete storage, they only grow, to effectively trim you need to either punch holes in files, or remove files. Discard only comes in to play when used diskspace becomes unused. To test preferably remove several large files at once while also generating a whole bunch of other diskio (e.g. compile the kernel while also deleting several large files from the same disk, with discard enable). But even if that works for you, that is 1 report that this works in some cases, vs many that it does not work; and also note that you had to manually enable this, it was not enabled before. So this really is going to impact the performance of very few users, while looking at the amount of bugreports about hangs / disk-corruption the problem of having queued-trim support enabled is much much bigger, so I see very little reason to re-enable this even if it happens to work in your case. > Or is there a way to check that discard is effectively enabled? There probably is, but I don't know where / how to check this. Regards, Hans