Received: by 2002:a05:6a10:1d13:0:0:0:0 with SMTP id pp19csp734979pxb; Thu, 2 Sep 2021 13:57:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxHkAp3v20H3QIz4Ac6s0XqazXHx/2bUTbbceSyzUR7Pre24tSjuluJavSdOpwxZqCi1gF/ X-Received: by 2002:a17:906:659:: with SMTP id t25mr127263ejb.372.1630616240252; Thu, 02 Sep 2021 13:57:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1630616240; cv=none; d=google.com; s=arc-20160816; b=s/Zz+SNbDoNNFjKGtPCvD0w4oyY9gRfEo91Bhvu83ZxZmerCK6K1J4TKfekAucOri5 UX9lPATUTnb/qV0nbBgEKOjxf28zr1B5gu1uem5IcD6wE96GxizrxMLRBq/rrzrRzkiB VpFl6LsZ+CLpJN54MEBXytSn7WP+SxCVneJMEbCsWAcMdIukLyK8Lln5vMYJJ7+xEg9r VXEd2pzKKyh6LbTzNsjFyUzGmqdPAKv1poHvDa0mVvmQk6yh/dWVVLdoEtyMtQKq9Hnf HJdNtn5riAbdfJYbHGNjsK5z238w73ZtYtmOOSqV+pth7xwIW70ScfN8CvNzVFiZHDLq 7d5A== 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:references:cc :to:from:subject:dkim-signature; bh=KQbxtwjvWQKASY6WHAu3BsyqnKPCj4Pmu1yx7Mqm3gc=; b=GwhW/cLHvPh6IkOG91MCAZJuQXpagVc+iPPlzMLDmGJGvn4HW+fX4pzodQ9Uutt8qs ulEJOY64bBJ1WUrz9TbTCgbetaGJbCRCBTxlTnm5Nnr8Urv2JqniQQgCJAf4NRNjj5gr tthOexsFalTrkbCixFkVK9t2rmFVw/0Gupinn8JeUECjTiGiezMYUn9NsqJu29gWjuac BNw18jPlaulob8vPQkCCc61Zapvljx4spWinhLAS7goRgw+rPkkXrbjI+B0VzcmuAnox pdmN336pKnYMRF5WATf10sBJefywwCTOPYEJzRkv4Ht8o9qRdjjz/q4LOWrBNh27sx8U ckTg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=ENUpYlX4; 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 h10si3351745edk.552.2021.09.02.13.56.57; Thu, 02 Sep 2021 13:57:20 -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=ENUpYlX4; 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 S1345524AbhIBUvI (ORCPT + 99 others); Thu, 2 Sep 2021 16:51:08 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:23962 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345215AbhIBUvH (ORCPT ); Thu, 2 Sep 2021 16:51:07 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1630615808; 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=KQbxtwjvWQKASY6WHAu3BsyqnKPCj4Pmu1yx7Mqm3gc=; b=ENUpYlX4i3W+fyRYnie1Gycuzdc4tPKiTq0ao/Q2C12xLXxm3H+aPYrmgaREkkS4M4dxLe IljmPb5saeiYxFqnXGhHKNKx6NoRkCATYTlQT+3IHRiZMOxAPQw5n6sA1dYvwagWMfyu9H PPh/lWZ3gKTzEVWVTZ7wmR7a5mwgOXo= 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-474-6_S8YQHiNtOiniDj8RHJbA-1; Thu, 02 Sep 2021 16:50:07 -0400 X-MC-Unique: 6_S8YQHiNtOiniDj8RHJbA-1 Received: by mail-ed1-f69.google.com with SMTP id x4-20020a50d9c4000000b003bed5199871so1626383edj.14 for ; Thu, 02 Sep 2021 13:50:06 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:from:to:cc:references:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=KQbxtwjvWQKASY6WHAu3BsyqnKPCj4Pmu1yx7Mqm3gc=; b=l3jkhblfy9BkYsoBYgjeBIvrHySQW/VbGQVLTM2XQguXtLoGqr66xXigygweLuJoyh 25HO+AD/2UnSTjQYg8nnv/mkdzGt741n9XAuboNm5kFHcfqrgmVz7Iy/3n89DHhT1YaI GTRrfaCfKtzHJbxGj4J8B311bF7fGT8KsMIXGdmp24s655NaKSwUIMpOqSl+akj19jvh s6mUKXfF93Ev1uL2Zn9ibAzcBjONPMaN5Wo/w99PcbUXyuNIseDS0xEucemVgd3nwbAK tLo674d69rXwFEtsBsgslQ7sTCmAMx55b5SttgbJeMOdZqYlMh5vX9VvxuOqgVMklgqJ 98rA== X-Gm-Message-State: AOAM533xUeBOlzzniJgmewTQeSe+46qJtItY0FJsLaoHoW1xlg/hqjEd NnR/eSiiAtbn/sQHajPw0rbVmpVdCrkCJm0k3e9O9UaDCRljtcZuvSUMwyXMqUnFgD5bCHpua+5 ZbT+g0k5pr8BFyp3Md/iPOPtx0iQ+ojFuRAgfNAKAwGYPPMN05+lto7zik7vOZHM9EipWsq7CIy 7q X-Received: by 2002:aa7:dc56:: with SMTP id g22mr246027edu.187.1630615805779; Thu, 02 Sep 2021 13:50:05 -0700 (PDT) X-Received: by 2002:aa7:dc56:: with SMTP id g22mr246004edu.187.1630615805542; Thu, 02 Sep 2021 13:50:05 -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 d22sm1716441ejk.5.2021.09.02.13.50.05 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 02 Sep 2021 13:50:05 -0700 (PDT) Subject: Re: [PATCH v5] libata: Add ATA_HORKAGE_NO_NCQ_ON_AMD for Samsung 860 and 870 SSD. From: Hans de Goede To: "Martin K. Petersen" Cc: Kate Hsuan , Jens Axboe , Damien Le Moal , Tor Vic , 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> Message-ID: Date: Thu, 2 Sep 2021 22:50:04 +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: <238d0841-0f03-928f-5441-89d5c9dcf9b9@redhat.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Again, On 9/2/21 10:46 PM, Hans de Goede wrote: > Hi, > > On 9/2/21 9:01 PM, Martin K. Petersen wrote: >> >> Hans, >> >>> So it looks like we actually need to disable NCQ for Samsung 860/870 >>> devices when the SATA controller has a vendor-id of PCI_VENDOR_ID_ATI >>> rather then AMD. >> >> That's another great data point! >> >> I wonder if there actually is a Samsung problem (given that these drives >> work fine on other controllers). Or if it is just the queued trim >> handling that's broken on 1002:4391 controllers from ATI. >> >> When I originally experimented with queued trim I had systems I could >> not get to work. But queued trim worked fine when the same drives were >> connected to more modern chipsets (note that this was "did not work at >> all" as opposed to "randomly corrupting data"). >> >> Do we have any evidence at all of queued trim working with non-Samsung >> drives on these controllers? Not sure how many modern SATA drives >> actually implement this feature. Maybe the reason we see Samsung drives >> in the bug reports is due to a combination of popularity and the fact >> that these drives actually implement queued trim support. > > The Samsung 860 / 870 series causing issues when queued trim support > is enabled are quite wide-spread, covering many different controller > models from all well known controller vendors (Intel, Asmedia, Marvell > and AMD). So disabling queued-trim support definitely is the right > thing to do (and we should have done so a long time ago, I am to > blame for this not being done sooner). > > As for your theory that it is really a problem with the controller > and not the the SSDs, I honestly do not know, but I doubt it, > there are no such reports with any other vendor's SSD or newer > Samsung models, so this seems unlikely. I just realized that all newer Samsung models are non SATA... Still I cponsider it likely that some of the other vendors also implement queued trim support and there are no reports of issues with the other vendors' SSDs. Regards, Hans