From patchwork Fri Jun 28 11:45:29 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jan Kiszka X-Patchwork-Id: 13715985 X-Patchwork-Delegate: kw@linux.com Received: from EUR05-AM6-obe.outbound.protection.outlook.com (mail-am6eur05on2084.outbound.protection.outlook.com [40.107.22.84]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 68E126F307; Fri, 28 Jun 2024 11:45:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.22.84 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719575140; cv=fail; b=R/fHV0Dzy1V3PeJym0XL/2tGQR03DXc1m1R/l9ay1Ds9TRH9WgbpRWvNFE/oet1dO0H9gyunhDHW76qgEBqGGF0tuM4Qmx8v7K+2btFYfCJ6nuYLZAir+rTQwQOTd3KrLBiBQdN5Pj7GxvDc9m9rj7eJv9jJDbb3BzX2j3jhbSY= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719575140; c=relaxed/simple; bh=6/bsnCY3nXYKuVIWq5PrGd/WZRrWILkyVJVTqlaqJWw=; h=Message-ID:Date:From:Subject:To:Cc:Content-Type:MIME-Version; b=YA8t6BnbQCPa+8Yd7hIH3r0uESFmEOxHLdeJRkTrRXJ2/1Lkh8V6hBmb4y+o6Z4UOhvnzRj0DQW2cgo0IHnzN2q1OaIMS1XVAMX/ZuERS8KzsmYpZPhQiyPZ/Z0tRdHh26uwRc5IJQipcX+EbUXW+NYGMrZ8saOwUAa7TkFJtuk= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=siemens.com; spf=pass smtp.mailfrom=siemens.com; dkim=pass (2048-bit key) header.d=siemens.com header.i=@siemens.com header.b=aYbO6/4C; arc=fail smtp.client-ip=40.107.22.84 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=siemens.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=siemens.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=siemens.com header.i=@siemens.com header.b="aYbO6/4C" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=CQQhNm59MESczFbX0Gs2Qrq3lNXW5Qxydj6Eh0C+2DZVVxP3SUyKfEu7ueGnlCeTDFB93/jPyo2Q1JOfwbcacIMgPegMBaCxLQY/JmjP4AxxKd2E+lyUfQBz3Ptf5owi6KH6+i+WqvqjLkCXrYbIjwz0X9iNRD0ptjSVRjO/1gtIZgDO1Sq1ds4KnN7/KS5OzNzXvnsCat1JRuIDrKQYjsCMFyqwQeaG/zEUDtmtr4QKuaeGN8YsBuVwMb86W4X9NnsixzIC26skIj8ltWJoLSOVuK7g8hRVax98QnMa9GigC326GO5iIxHLHFNQwMyEex51fs8v0UusuUMiPEvzeA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=sNLOt8SKLbCnXLra5TV1pXRGlAofI4V5vJbsGXmmd4Q=; b=JepSJaT53XmWXx6fcV4RFtmrpJNSNqh+7W90EiPWC418M5QkXnKmHZIKXw+NYtABqTuFXMDhUmouR3LU7JezHffbdWh2jPhdtgmTEBQ1DfOj8V9+2iwHes14behZmDsh4FXq621cnBGjxoUoYWwrVwEpnskskqyWMlTrvVdiflUF0N4MVum93x+KrE00jpjpk9kmq86OizJA4z9oUkw7UYryssOy1aeto/7O1cQPf4eLBfvcL+/haIYBTQ8zZY6iw4iRYfjMOeBOtFDaCFGMMTXDr737hu8fn701uPe7X1RaVMWgwossiMHFUgrlJbeqLiYCbmSWuVkQA6HWt5kqQQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=siemens.com; dmarc=pass action=none header.from=siemens.com; dkim=pass header.d=siemens.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=siemens.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=sNLOt8SKLbCnXLra5TV1pXRGlAofI4V5vJbsGXmmd4Q=; b=aYbO6/4CKUpoy3zy4dZb0iFPh9IFVvy0LcJgJcmdiJq8LlCQBdHh1OAyeYiStPHVqGnVWD8z2qGKgDZTIvvUB9uh+4vBaoSOvLSsZCl5npcgfiYA8hn/OJtiOESXaRI30ZcuzSzFbR7NadYtSkRXqSJhBrSZuQpSwOFpgOJFbNq9g+Yt2+j06DKD9hQsNrE613e2m40c6bGnXwCGurzD5reN49Uvl1f9Ozp0ZvW2TwPLPQL8EirX8vSnEhN6xvvQuwmbepN836EidKBwtc5KG5t4TSOetx2yglLQgBnpgCZruCmJ4wwhuLF+XMkSeteku1LFd/XSKUlFSeLqg6QA3A== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=siemens.com; Received: from AS4PR10MB6181.EURPRD10.PROD.OUTLOOK.COM (2603:10a6:20b:588::19) by PAXPR10MB5784.EURPRD10.PROD.OUTLOOK.COM (2603:10a6:102:24a::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7698.30; Fri, 28 Jun 2024 11:45:33 +0000 Received: from AS4PR10MB6181.EURPRD10.PROD.OUTLOOK.COM ([fe80::8fe1:7e71:cf4a:7408]) by AS4PR10MB6181.EURPRD10.PROD.OUTLOOK.COM ([fe80::8fe1:7e71:cf4a:7408%4]) with mapi id 15.20.7719.022; Fri, 28 Jun 2024 11:45:33 +0000 Message-ID: <16e1fcae-1ea7-46be-b157-096e05661b15@siemens.com> Date: Fri, 28 Jun 2024 13:45:29 +0200 User-Agent: Mozilla Thunderbird From: Jan Kiszka Subject: [PATCH v5] PCI: keystone: Add workaround for Errata #i2037 (AM65x SR 1.0) Content-Language: en-US To: Lorenzo Pieralisi , =?utf-8?q?Krzysztof_Wilczy?= =?utf-8?q?=C5=84ski?= , Rob Herring , Bjorn Helgaas , Kishon Vijay Abraham I Cc: Siddharth Vadapalli , Vignesh Raghavendra , Nishanth Menon , "linux-pci@vger.kernel.org" , Linux Kernel Mailing List , linux-arm-kernel Autocrypt: addr=jan.kiszka@siemens.com; keydata= xsFNBGZY+hkBEACkdtFD81AUVtTVX+UEiUFs7ZQPQsdFpzVmr6R3D059f+lzr4Mlg6KKAcNZ uNUqthIkgLGWzKugodvkcCK8Wbyw+1vxcl4Lw56WezLsOTfu7oi7Z0vp1XkrLcM0tofTbClW xMA964mgUlBT2m/J/ybZd945D0wU57k/smGzDAxkpJgHBrYE/iJWcu46jkGZaLjK4xcMoBWB I6hW9Njxx3Ek0fpLO3876bszc8KjcHOulKreK+ezyJ01Hvbx85s68XWN6N2ulLGtk7E/sXlb 79hylHy5QuU9mZdsRjjRGJb0H9Buzfuz0XrcwOTMJq7e7fbN0QakjivAXsmXim+s5dlKlZjr L3ILWte4ah7cGgqc06nFb5jOhnGnZwnKJlpuod3pc/BFaFGtVHvyoRgxJ9tmDZnjzMfu8YrA +MVv6muwbHnEAeh/f8e9O+oeouqTBzgcaWTq81IyS56/UD6U5GHet9Pz1MB15nnzVcyZXIoC roIhgCUkcl+5m2Z9G56bkiUcFq0IcACzjcRPWvwA09ZbRHXAK/ao/+vPAIMnU6OTx3ejsbHn oh6VpHD3tucIt+xA4/l3LlkZMt5FZjFdkZUuAVU6kBAwElNBCYcrrLYZBRkSGPGDGYZmXAW/ VkNUVTJkRg6MGIeqZmpeoaV2xaIGHBSTDX8+b0c0hT/Bgzjv8QARAQABzSNKYW4gS2lzemth IDxqYW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CCHkym0zz5Y3vxaYtbXG2wTrqJ 8WpkWIE8STUhQa9AkezgucXN7r6uSrzW8IQXxBInZwFIyBgM0f/fzyNqzThFT15QMrYUqhhW ZffO4PeNJOUYfXdH13A6rbU0y6xE7Okuoa01EqNi9yqyLA8gPgg/DhOpGtK8KokCsdYsTbk= X-ClientProxiedBy: FR4P281CA0368.DEUP281.PROD.OUTLOOK.COM (2603:10a6:d10:f8::15) To AS4PR10MB6181.EURPRD10.PROD.OUTLOOK.COM (2603:10a6:20b:588::19) Precedence: bulk X-Mailing-List: linux-pci@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AS4PR10MB6181:EE_|PAXPR10MB5784:EE_ X-MS-Office365-Filtering-Correlation-Id: 8e85067f-7c2e-494b-28cc-08dc9767d15d X-MS-Exchange-AtpMessageProperties: SA X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|366016|376014|7416014|1800799024; X-Microsoft-Antispam-Message-Info: =?utf-8?q?M+VIXbvpoC4E2x+9X986Hk9mgifiz/y?= =?utf-8?q?49JI0NAcv+nwk74s/Ofi+dNwESFLVGjH484izqJFgNvGXwYlSIgEzz2miJ65HjlVA?= =?utf-8?q?ecO5oZOoJkFDCvxIfxX0wTPXR2JTunjzob+nGa4AcKKhgu+Foj4hy96Trp6wHbQ3E?= =?utf-8?q?v9aRmMV/NtHENh26uojzfmCdX1JOAZrpWXRZctwiEsg9fXgcFzZuYJEew+1a6W0gY?= =?utf-8?q?CRTSFAzKIT3qMIBYbxzsNIg1CywNAPwPWDEnW5mCAxSa79FVpprzz3G1tthMEz2uj?= =?utf-8?q?/eLNdau76boHwwIXkVuk+HbSLA5ZCduBIpzyHoWOrb/Mzx8lrnrTkGoAWXCZm1tXV?= =?utf-8?q?h29Ze9HQetRqD2aTxXQKr9flfDgkvHeiUSP7zXZ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D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:AS4PR10MB6181.EURPRD10.PROD.OUTLOOK.COM;PTR:;CAT:NONE;SFS:(13230040)(366016)(376014)(7416014)(1800799024);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?DxcmWA9uuul96JHAKJ7Sx12UqAot?= =?utf-8?q?R/vg1CQgNd+cu0BwWBSpHIPSDpRcj/IV0aVK8TlnJLXL+hgKEHZb/ni6N1a1ckGAM?= =?utf-8?q?OkuDvb8a+xqQP971j/ge0aYeUmN33Ag2pcsYpK3lpQ3y+sPovnDi60qaIgIrs6kr9?= =?utf-8?q?givsXU2US580bhhDzlO8J3aX6htcVGBAhro3DdIffWgo2oU6+UINsEelYgu/cpB96?= =?utf-8?q?yYAXisG/nCxuIg4FzouWUqUc1qIzI0KYjoUISnKggO8h9Mpi40gF9nzIWzwHg1+1Q?= =?utf-8?q?+kBBdNcf399R3PFF+jLnLZWPWpyfjAATbkoDSFFPRWEVQa73FoG2gMTyzyWVo17J2?= =?utf-8?q?44cphmQfbO2xOccOvUeA02qWWoMeapMptUvJ14hqqOYUsA8rNOfEYIKWh9h+lSYbH?= =?utf-8?q?6PMXyI4wLLVs2iZ8lS+6Qvhe//sVuubYYh2acfhyt7ULhFd36Px5maxqQTDYoTJ/s?= =?utf-8?q?arY6lAYhLWYGQheYQL9L6rW8ATcLm2pyJa0UQUkJS/HE4WXWVLuR291TWdNU1aWuX?= =?utf-8?q?kT6xDIpwzp0Veb/xETcIKk2B92I8YNzm5GrhsnK6kCP/6+PqjAE0z0zWjvF/EYgl5?= =?utf-8?q?NE+Ddh1tmlQXonj5gAj/shdAzgPcbW7eDKMfTzCY1570MqhE47rLNI6RD6iuYcvUz?= =?utf-8?q?Bxz5A9fX6liHfcljFNhLPsykLtLpVqd9sdZorr8wz+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atorOrg: siemens.com X-MS-Exchange-CrossTenant-Network-Message-Id: 8e85067f-7c2e-494b-28cc-08dc9767d15d X-MS-Exchange-CrossTenant-AuthSource: AS4PR10MB6181.EURPRD10.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 28 Jun 2024 11:45:33.0819 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 38ae3bcd-9579-4fd4-adda-b42e1495d55a X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: vSu+YOeezSAQMJD022z84gxlBymlnfuSfNYyRK/KekLM+iZzXhrMu1wsM/3H3Up3vvrPN2ptfxZpisDHXp2NAQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: PAXPR10MB5784 From: Kishon Vijay Abraham I Errata #i2037 in AM65x/DRA80xM Processors Silicon Revision 1.0 (SPRZ452D_July 2018_Revised December 2019 [1]) mentions when an inbound PCIe TLP spans more than two internal AXI 128-byte bursts, the bus may corrupt the packet payload and the corrupt data may cause associated applications or the processor to hang. The workaround for Errata #i2037 is to limit the maximum read request size and maximum payload size to 128 bytes. Add workaround for Errata #i2037 here. The errata and workaround is applicable only to AM65x SR 1.0 and later versions of the silicon will have this fixed. [1] -> https://www.ti.com/lit/er/sprz452i/sprz452i.pdf Signed-off-by: Kishon Vijay Abraham I Signed-off-by: Achal Verma Signed-off-by: Vignesh Raghavendra Signed-off-by: Jan Kiszka Reviewed-by: Siddharth Vadapalli --- Original patch: Link: https://lore.kernel.org/linux-pci/20210325090026.8843-7-kishon@ti.com/ --- drivers/pci/controller/dwc/pci-keystone.c | 44 ++++++++++++++++++++++- 1 file changed, 43 insertions(+), 1 deletion(-) diff --git a/drivers/pci/controller/dwc/pci-keystone.c b/drivers/pci/controller/dwc/pci-keystone.c index d3a7d14ee685..25e365c0c5c7 100644 --- a/drivers/pci/controller/dwc/pci-keystone.c +++ b/drivers/pci/controller/dwc/pci-keystone.c @@ -34,6 +34,11 @@ #define PCIE_DEVICEID_SHIFT 16 /* Application registers */ +#define PID 0x000 +#define RTL GENMASK(15, 11) +#define RTL_SHIFT 11 +#define AM6_PCI_PG1_RTL_VER 0x15 + #define CMD_STATUS 0x004 #define LTSSM_EN_VAL BIT(0) #define OB_XLAT_EN_VAL BIT(1) @@ -104,6 +109,8 @@ #define to_keystone_pcie(x) dev_get_drvdata((x)->dev) +#define PCI_DEVICE_ID_TI_AM654X 0xb00c + struct ks_pcie_of_data { enum dw_pcie_device_mode mode; const struct dw_pcie_host_ops *host_ops; @@ -525,7 +532,11 @@ static int ks_pcie_start_link(struct dw_pcie *pci) static void ks_pcie_quirk(struct pci_dev *dev) { struct pci_bus *bus = dev->bus; + struct keystone_pcie *ks_pcie; + struct device *bridge_dev; struct pci_dev *bridge; + u32 val; + static const struct pci_device_id rc_pci_devids[] = { { PCI_DEVICE(PCI_VENDOR_ID_TI, PCIE_RC_K2HK), .class = PCI_CLASS_BRIDGE_PCI_NORMAL, .class_mask = ~0, }, @@ -537,6 +548,11 @@ static void ks_pcie_quirk(struct pci_dev *dev) .class = PCI_CLASS_BRIDGE_PCI_NORMAL, .class_mask = ~0, }, { 0, }, }; + static const struct pci_device_id am6_pci_devids[] = { + { PCI_DEVICE(PCI_VENDOR_ID_TI, PCI_DEVICE_ID_TI_AM654X), + .class = PCI_CLASS_BRIDGE_PCI << 8, .class_mask = ~0, }, + { 0, }, + }; if (pci_is_root_bus(bus)) bridge = dev; @@ -558,10 +574,36 @@ static void ks_pcie_quirk(struct pci_dev *dev) */ if (pci_match_id(rc_pci_devids, bridge)) { if (pcie_get_readrq(dev) > 256) { - dev_info(&dev->dev, "limiting MRRS to 256\n"); + dev_info(&dev->dev, "limiting MRRS to 256 bytes\n"); pcie_set_readrq(dev, 256); } } + + /* + * Memory transactions fail with PCI controller in AM654 PG1.0 + * when MRRS is set to more than 128 bytes. Force the MRRS to + * 128 bytes in all downstream devices. + */ + if (pci_match_id(am6_pci_devids, bridge)) { + bridge_dev = pci_get_host_bridge_device(dev); + if (!bridge_dev && !bridge_dev->parent) + return; + + ks_pcie = dev_get_drvdata(bridge_dev->parent); + if (!ks_pcie) + return; + + val = ks_pcie_app_readl(ks_pcie, PID); + val &= RTL; + val >>= RTL_SHIFT; + if (val != AM6_PCI_PG1_RTL_VER) + return; + + if (pcie_get_readrq(dev) > 128) { + dev_info(&dev->dev, "limiting MRRS to 128 bytes\n"); + pcie_set_readrq(dev, 128); + } + } } DECLARE_PCI_FIXUP_ENABLE(PCI_ANY_ID, PCI_ANY_ID, ks_pcie_quirk);