Received: by 2002:ab2:6857:0:b0:1ef:ffd0:ce49 with SMTP id l23csp2489570lqp; Sun, 24 Mar 2024 23:16:03 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXntQAbQMTwmcWuiTfbbPbjmIAdSI9Autth+jPW0a2OTyhqYMJ8sgidbN4nbvNSBNNAIEjYv10x9hylhLoObAAR8cshZAzTDNgRktpg6A== X-Google-Smtp-Source: AGHT+IG5WB6GuGwgRa8CLMptAg11iLjaqbj8gYI5Ay22a04b5ZzVgbSWFcQaOYM6Ym4dbsLbJc4j X-Received: by 2002:a05:6512:3b90:b0:515:b02b:ce81 with SMTP id g16-20020a0565123b9000b00515b02bce81mr308188lfv.30.1711347363410; Sun, 24 Mar 2024 23:16:03 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1711347363; cv=pass; d=google.com; s=arc-20160816; b=IFc/Yj7KNY+3HP1bdUA2AVuodcPiMlc/NUpJGEN4j/oJidox/wLjkvChizEndpHOo6 tg0plOm44e2uVkQarpVD8bzie8GCVgp43sGMyjCaqhZSO7tf2/ahGM/BXJTq0AAJUe+q VYB7HQdBDZhqVXYsg4mWSEKunff1zNH2FMq5+KIwOLPL6kmyu2rfFraCbPjnkCrX1Wp6 ORXVYHmNmxKaDrtDrCrO12Ok3PMBM8fFXDt+8mmWng2uQ+UtDCbQOjFsYvSzcK8tM6lz SFX8GSv9c+3Kw31gYWIUgvUzBC4EviKuS+cZc2YyW0iIh75bs2axx5Q7sDLHxIvZZOHI u49g== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=Sqdn5ma4gO+/WgXmJ8Z3IRYRsp/p0N9pP0DttkGE74A=; fh=PuXfdepGU2Y/fEiRkHzdQ2wynxN5rxRjTVsYXSJ3LrU=; b=St4/AqlVvKx8lkH9yymluxa0oS5W91sudYzmpEXIh7Gp8xeVgeTxrFTCmxkH0OyAsM gRGNPVa7ValP7ZaBRDA734qSrMYxqU46aifxQDWxkJMTY3EPTJrOtqZqj3W0mli/FnH2 YXCTb5tKYntvJ0W3AVY5yl0iz4NcEg6UhiEefbUMwIwQNne+tjFlebiI+j1jKODDUYVX 0M31X1UbFX/ImY7S30LeBqBmt/sj1Ls8yqpQz1sQp63Ec1asWHZ/gy2UeLcjcSxV6fv8 4ldCXrmIQKnnqFGNwXFs1KYPnRrSSyIo3ZcxuVWh7EdorbonpFcJGk6TUJBsReI/7viz g5wQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=M1gQUpZ4; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-114544-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-114544-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id i23-20020a17090639d700b00a470bb80184si2185994eje.962.2024.03.24.23.16.03 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 24 Mar 2024 23:16:03 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-114544-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=M1gQUpZ4; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-114544-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-114544-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 06A541F2B7D9 for ; Mon, 25 Mar 2024 06:16:03 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 48BC4184111; Sun, 24 Mar 2024 23:51:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="M1gQUpZ4" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 B0FE122C640; Sun, 24 Mar 2024 23:16:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711322176; cv=none; b=u8D7xds/Kqwur3PYRaP7nSyPNHnxpa5ThA5Lj5Ow/TYErr4QL3zt8FE98uYuLMRjCw7tbw2z5x721cVZgWG4+Kqtod/cPr9i0nGkaqoMKsOpQaTZ8I++AHXhYRk3KIArlXCpYWCsI28+IAZGFUnOC4SYz4dIp4qExmjQ/nTEUDY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711322176; c=relaxed/simple; bh=46kJzhy80nj07sywNc6/IBShEzaZS6Mpfoy6P4z2SL0=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=k5Yod7I0w3RfwpjvSwFNmDxeORIdGriQ5oqjQ2lsdIr9Y0hXBbF1ibPLpmPLii/LJGob+bQMzWDN0gFS1yT4I+Qdlt9MHfU6KKFnd3hGAx8ZEQjJp/oE/XHGRNN9ZehP+iBJpTxr8JMrUqOZBEP+dpBzTcykFMao6xSBdHjxsxM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=M1gQUpZ4; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id EFB2AC43399; Sun, 24 Mar 2024 23:16:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1711322175; bh=46kJzhy80nj07sywNc6/IBShEzaZS6Mpfoy6P4z2SL0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=M1gQUpZ4Rsa1ih1JbEi8n6yaRw5vjdBR/WuCllyR5gfxaeMFTTlon7OyQ5ZOlsmyu wfH1bdIehHlcFgCySoi9UErNQzXiTVkn44PG++PVsmkk2DPIyIaABWxQEs8XR2SQF+ ziGT0rdVOQCIfMgm2A1U4Wm86Lyz//xTzd+mtvhILb4IpZW5p+C0HLwx+mZQXQARj8 NDPirHS9XUeqtuqAeVvynWIAUASPQdh3TsHYT92dzCzXQuhRFq0TNx0T0Yt7GFBkf9 JE0g83Z7Ri91F6p5d2YuramofPnpOswFNrkgTeUyz4spCTtblFAphry/qSagSt022R IIzi9ZC/jvVvg== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: =?UTF-8?q?Ilpo=20J=C3=A4rvinen?= , Bjorn Helgaas , Sasha Levin Subject: [PATCH 6.1 254/451] PCI/DPC: Print all TLP Prefixes, not just the first Date: Sun, 24 Mar 2024 19:08:50 -0400 Message-ID: <20240324231207.1351418-255-sashal@kernel.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240324231207.1351418-1-sashal@kernel.org> References: <20240324231207.1351418-1-sashal@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit From: Ilpo Järvinen [ Upstream commit 6568d82512b0a64809acff3d7a747362fa4288c8 ] The TLP Prefix Log Register consists of multiple DWORDs (PCIe r6.1 sec 7.9.14.13) but the loop in dpc_process_rp_pio_error() keeps reading from the first DWORD, so we print only the first PIO TLP Prefix (duplicated several times), and we never print the second, third, etc., Prefixes. Add the iteration count based offset calculation into the config read. Fixes: f20c4ea49ec4 ("PCI/DPC: Add eDPC support") Link: https://lore.kernel.org/r/20240118110815.3867-1-ilpo.jarvinen@linux.intel.com Signed-off-by: Ilpo Järvinen [bhelgaas: add user-visible details to commit log] Signed-off-by: Bjorn Helgaas Signed-off-by: Sasha Levin --- drivers/pci/pcie/dpc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/pci/pcie/dpc.c b/drivers/pci/pcie/dpc.c index a5d7c69b764e0..08800282825e1 100644 --- a/drivers/pci/pcie/dpc.c +++ b/drivers/pci/pcie/dpc.c @@ -231,7 +231,7 @@ static void dpc_process_rp_pio_error(struct pci_dev *pdev) for (i = 0; i < pdev->dpc_rp_log_size - 5; i++) { pci_read_config_dword(pdev, - cap + PCI_EXP_DPC_RP_PIO_TLPPREFIX_LOG, &prefix); + cap + PCI_EXP_DPC_RP_PIO_TLPPREFIX_LOG + i * 4, &prefix); pci_err(pdev, "TLP Prefix Header: dw%d, %#010x\n", i, prefix); } clear_status: -- 2.43.0