From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796311004; b=brBQOXMPRog6EG+RfTHWddkSFUmN3TpLyw1XmvaGBCUDWRGboIskH3pZrQ1+ijG0jko8 v08RHaHz0Tlh8boppeGXcs7M63pZM8V5Amm9jGgNSTi66NED7C9wjt8vDStGLUlfOmXkA yoFDBEl0vS75ylVkWFNSd0wAenHKJu4djAWR44umSbP+J22NXuHsIba4Tvbp9ilVIlhdb /VGtfNZlvX68I8ikVx3B0wAZw/8kZHmgMqOIg5b+cRQZeaJnr8nygRpinQ7y45hgRbqx9 vb8Bz1aBXncdwX3vbxPlraSa34/ygCSsH5j5GzxYPxGZq6ESn92kkXI8Us1F+M3FSGw== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796311004; h=Received:DKIM-Signature:Message-ID:From:Subject:Reply-To:To: In-Reply-To:References:Content-Type:Content-Transfer-Encoding:Date; bh=BzLWJmQQc11I7Eb1JM3DImTnfolO6YSKh0IR/N6w4rU=; b=szLn7+y1CwgEYzDaEIR3H8F40JIOLgUCdcNE9Naa7da1glbOZo0D+SDRzN8TFngDWcQW ZtXLztEI1JjygNA5QLw86FX2/TUMGoIW7SOxpVSCrDd3XGHj2sca6APTU52Ymq9IgSl4v P1CFmBTQFqsjYcl1ZaYIg2wB2fm2sOLOuCUfjpUbUkjq/sh4jxFb/3ixcRCuwjJQnRJ9C 2ExTM0ZLcR8uKXH1UB0tdmzJi8IxpR5yy/QlBm+PXz+MMUiyGVs2KuGEwb3+Z/4mTLDGa A1l03AE2g/DoNJY+3aY58AmYTYkiqjE9adsCikTb4EAn0tnWLiZg1OQfiegaTU9MbiQ== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b="cyFfUV/d"; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 471F5606A32C for ; Thu, 3 Dec 2026 15:16:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=cyFfUV/d Received: by smtp.kernel.org (Postfix) with ESMTPSA id CFDCB1F00893; Thu, 3 Dec 2026 15:16:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796311003; bh=BzLWJmQQc11I7Eb1JM3DImTnfolO6YSKh0IR/N6w4rU=; h=From:Subject:Reply-To:To:In-Reply-To:References:Date; b=cyFfUV/dU/Jf3StVRifaHbeElP1ChAvB+oy4sgMg04tTnx73lUn+NT2H7lC/Odl33 HcANTU75Rx/Rb0iDmkBUb/lirmeDB7NZGhOEReFKu+76w9iaL+yxlAD5J6Mvr3Zbv1 5bAiPHZBklaTBd77yoDX9isQg3J8zWlY1EuTCIpQ5whR2DJcSF0bao+sGXciX1tu5U sxZjArbWY1iZM06HdSGN72Pt65ggpFf1zkQtBNl0XDtH2m3FuWe5fVvMDMzfK/ZJc6 lAWYlEYukjfYNzqls/QHYuDQuLD3Q5oRGMU0Nlqmd49kBKaYDJA4xPcpL5UVBAH4kV samxDneQb+DWQ== Message-ID: From: sashiko-bot@kernel.org Subject: Re: [PATCH v3 1/2] x86/PCI: Work around AMD erratum #1146 on Family 17h root ports Reply-To: sashiko-reviews@lists.linux.dev To: "Anthony Pighin" , linux-pci@vger.kernel.org In-Reply-To: <20261203145647.707695-2-anthony.pighin@nokia.com> References: <20261203145647.707695-1-anthony.pighin@nokia.com> <20261203145647.707695-2-anthony.pighin@nokia.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Date: Thu, 03 Dec 2026 15:16:43 +0000 X-Mailing-List: linux-pci@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list Thank you for your contribution! Sashiko AI review found 1 potential issue to consider: - [Low] x86/PCI: blind write and resume log spam in quirk_amd_dpc_rp_pio_syserror() -- commit 190fbd0bc3523b02566ddeae4186a65e382ced19 Author: Anthony Pighin x86/PCI: Work around AMD erratum #1146 on Family 17h root ports This commit adds a PCI quirk for AMD Family 17h root ports (device ID 0x145= 3) that writes 0x00070707 to PCI_EXP_DPC_RP_PIO_SYSERROR at enumeration and on early resume to work around AMD erratum #1146. Link: https://docs.amd.com/v/u/en-US/55449-PUB-1.21 > diff --git a/arch/x86/pci/fixup.c b/arch/x86/pci/fixup.c > index 795d81c7a4de4..d8ea0e5292aee 100644 > --- a/arch/x86/pci/fixup.c > +++ b/arch/x86/pci/fixup.c > @@ -1180,3 +1180,27 @@ static void quirk_tuxeo_rp_d3(struct pci_dev *pdev) [ ... ] > + pci_write_config_dword(dev, dpc + PCI_EXP_DPC_RP_PIO_SYSERROR, 0x000707= 07); > + pci_info(dev, "AMD erratum #1146: disable DPC RP PIO System Error escal= ation\n"); > +} > +DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_AMD, 0x1453, quirk_amd_dpc_rp_pio= _syserror); > +DECLARE_PCI_FIXUP_RESUME_EARLY(PCI_VENDOR_ID_AMD, 0x1453, quirk_amd_dpc_= rp_pio_syserror); [Severity: Low] Should quirk_amd_dpc_rp_pio_syserror() read PCI_EXP_DPC_RP_PIO_SYSERROR before writing it? The unconditional 32-bit write clears upper reserved bits [31:19] (RsvdP) instead of updating only bits [18:0]. Because DECLARE_PCI_FIXUP_RESUME_EAR= LY runs on every runtime PM and system resume, pci_info() also spams dmesg per root port even when the register already has the expected value. Reading the register first, returning early when bits [18:0] are already 0x00070707, and doing a read-modify-write on bits [18:0] (or using pci_info_once()) would preserve the reserved bits and avoid repeated resume logging. --=20 Sashiko AI review =C2=B7 https://sashiko.dev/#/patchset/20261203145647.7076= 95-1-anthony.pighin@nokia.com?part=3D1