Received: by 2002:a05:6a11:4021:0:0:0:0 with SMTP id ky33csp1909625pxb; Thu, 16 Sep 2021 19:57:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzInQEfu3VmzA5iRj8vkJDRBxgJP0I3t64r8GvTWz0arNxtMqqOxUfkgsSRQV+UDINXI6xn X-Received: by 2002:a05:6402:336:: with SMTP id q22mr10182861edw.53.1631847443414; Thu, 16 Sep 2021 19:57:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631847443; cv=none; d=google.com; s=arc-20160816; b=iRUOijfVTbqrxuiWpHNjjOpKxYfAJ5cTrSmgKjZ3SxJj+3ULX8hWQtPOvS9Kzcg+L4 tprdXnB/4kEK8E8BqInspLmfd+I3nmhO/Xi4LM9ghjSYw7Ztx8exFZut2rJgO3+O5DF/ nqAYTiN6ev0zw7YrV0GK3fIIzqozhXBVsnjEPliIAkOz6OxrTuj6o48YbZucrmYMY1S5 yumaqu/58Nu+vCWdbACWSUsVWTkDmnR8Y6E3EZnalwTkOCau1lOi07W204SyKYFfOqNf H5GVtjYHhYsq75k1SNocDk4i+jlqZQihMZPeTf9xi81n3EHehKNzar4uYn4Onyu6MUDT 6gZw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=hrQTtqYdRDswLRChgCmaBGnY4lQQO2n3G4p4uPFxwB0=; b=CkLxwOCTySIUO4MMxV29qyysG2b+RRSEX1nWRmkaAeUliAfKdUrtG/5htCfnKxYkd1 X34+4RWBCK/ga3kzl4n3XLneVTwc8Tov9v+x+sWJSYQoJxeAvXKGDMo1sdF6gMoIb93a dSbK5rdhqPtPPzmOGlKeH6AI4tPMMkSyO9UCFQBhzzX81KuqQYYKu9y13aXIKmcS6uYz LbLFXFIYYFce6TTEWv/sPf+GoXomq+sSjb9+HRIUHsB0tWQJ4qMFupkvT6UflB990cyp tNpR9YLI60q5INxMYruEbWRnjKGQtTa37Zf36rlYHl/bwU/AziJ6Gn5wqkim0Ew1e6Te Htog== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=lcHtcPL5; 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=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id eo22si5327018ejc.690.2021.09.16.19.56.59; Thu, 16 Sep 2021 19:57:23 -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=@linuxfoundation.org header.s=korg header.b=lcHtcPL5; 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=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1352126AbhIPRUj (ORCPT + 99 others); Thu, 16 Sep 2021 13:20:39 -0400 Received: from mail.kernel.org ([198.145.29.99]:40900 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244112AbhIPRNO (ORCPT ); Thu, 16 Sep 2021 13:13:14 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 93AA461425; Thu, 16 Sep 2021 16:38:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1631810320; bh=2WoSXoG2EqbWWaKQO8rHAhKmc2XqnwYnzZvb8UsbPcw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=lcHtcPL50b3aWR59ohoqo9RXSpzACW8qcbDR2frre4sQUQR4zBWcP9fx+cLl6lSr8 sWhQcFYo2awROHT01Hp594YbatbYD67lrY+qkiZgcGCrBiqVu/0Fk+IIRIRhSur7UA fKnfpg9bOMShafVSOD05gy2tVjxtnLOnFxSaalw4= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, =?UTF-8?q?R=C3=B6tti?= , =?UTF-8?q?Marek=20Beh=C3=BAn?= , Bjorn Helgaas , =?UTF-8?q?Krzysztof=20Wilczy=C5=84ski?= , =?UTF-8?q?Pali=20Roh=C3=A1r?= Subject: [PATCH 5.14 065/432] PCI: Restrict ASMedia ASM1062 SATA Max Payload Size Supported Date: Thu, 16 Sep 2021 17:56:54 +0200 Message-Id: <20210916155812.992970884@linuxfoundation.org> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20210916155810.813340753@linuxfoundation.org> References: <20210916155810.813340753@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Marek Behún commit b12d93e9958e028856cbcb061b6e64728ca07755 upstream. The ASMedia ASM1062 SATA controller advertises Max_Payload_Size_Supported of 512, but in fact it cannot handle incoming TLPs with payload size of 512. We discovered this issue on PCIe controllers capable of MPS = 512 (Aardvark and DesignWare), where the issue presents itself as an External Abort. Bjorn Helgaas says: Probably ASM1062 reports a Malformed TLP error when it receives a data payload of 512 bytes, and Aardvark, DesignWare, etc convert this to an arm64 External Abort. [1] To avoid this problem, limit the ASM1062 Max Payload Size Supported to 256 bytes, so we set the Max Payload Size of devices that may send TLPs to the ASM1062 to 256 or less. [1] https://lore.kernel.org/linux-pci/20210601170907.GA1949035@bjorn-Precision-5520/ BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=212695 Link: https://lore.kernel.org/r/20210624171418.27194-2-kabel@kernel.org Reported-by: Rötti Signed-off-by: Marek Behún Signed-off-by: Bjorn Helgaas Reviewed-by: Krzysztof Wilczyński Reviewed-by: Pali Rohár Cc: stable@vger.kernel.org Signed-off-by: Greg Kroah-Hartman --- drivers/pci/quirks.c | 1 + 1 file changed, 1 insertion(+) --- a/drivers/pci/quirks.c +++ b/drivers/pci/quirks.c @@ -3241,6 +3241,7 @@ DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_SO PCI_DEVICE_ID_SOLARFLARE_SFC4000A_1, fixup_mpss_256); DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_SOLARFLARE, PCI_DEVICE_ID_SOLARFLARE_SFC4000B, fixup_mpss_256); +DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_ASMEDIA, 0x0612, fixup_mpss_256); /* * Intel 5000 and 5100 Memory controllers have an erratum with read completion