From patchwork Mon Dec 18 03:04:27 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: LeoLiu-oc X-Patchwork-Id: 18205 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:24d3:b0:fb:cd0c:d3e with SMTP id r19csp999344dyi; Sun, 17 Dec 2023 19:05:31 -0800 (PST) X-Google-Smtp-Source: AGHT+IFEfpWBAoGc7MoUl6aw3IEQC/5kJGkVdda+LUsdV9SjpBTMiGhUbYxlL4QkTdJ7NhaYvhhc X-Received: by 2002:a05:6808:e85:b0:3b8:b063:6bbc with SMTP id k5-20020a0568080e8500b003b8b0636bbcmr17939020oil.107.1702868731523; Sun, 17 Dec 2023 19:05:31 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702868731; cv=none; d=google.com; s=arc-20160816; b=ZyFHtB6z+2EXD/ArPgt8ovzw4rmG2tP7wOYmGzOTVoFkHkwf7fx1C/V41lBp7HC7XH AnKEuA0ZLYzduywJHzGjz9k5xlvvGpMojtRtal8xcIboPc+nLFQQoc5bbgpHhULYUjP4 FOBhLYJ47oiNDOMGlKhynu3195VD83FMzkJLHrpAVNLjpKo7XSDgBYXRzY3jjMSshzpO Z20OzMyMPIgTdP799cEAuwXKxlLOpyZaIY8hKUQs5WmEa8x3ptRQoj56mRVR5R+KKDtj iJujpOLXEaVXEJr4yKOg4O7ymUoNsGbXm54y+uhnWHqRBreETlA+j7bgJ0vgCBcssaJJ COkg== ARC-Message-Signature: i=1; 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; bh=T/jwV97rMBvvMaI82mZu8lcOJa37tJyQsvjqvI09v3A=; fh=m78OHke778HCKRWBAKUmJlH7wnphMgZrmsNcQ/ZbGbw=; b=cHuJ5GcxAXxPgFCVnsbWY8TCIj9QNrC2RbhnYVqHMO6W1mBNSprR/5qE408mUV9d/y pi5svVB0WArqEzMCWgNWea6YV6BFt6lw8M3crNPzYVSys9ZK3AP17EzP1y5crgltwrHU ElJ3UQvKkbXTRb8t3AfEXkb670p1P3U9KEf6LTwbp9BBa8i26hWN/c2euPmy62gQ+XZv 7BtHAGbz31Zr9VbeKTpVa+L8FvRe5U0X8rOsvp0wNhaQttSdkIOGnSasMyytMZsQi1dM OHrYgKlITfmG+2CBtnK42AzeB5faMLluLwOFd6k0S2oOBtocDmyjtKiNzWnP8yxzCmld UzeA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel+bounces-2958-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-2958-ouuuleilei=gmail.com@vger.kernel.org" Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id f17-20020a635551000000b005bd39be60b3si16453638pgm.390.2023.12.17.19.05.31 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 17 Dec 2023 19:05:31 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-2958-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel+bounces-2958-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-2958-ouuuleilei=gmail.com@vger.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 sv.mirrors.kernel.org (Postfix) with ESMTPS id 46ED1281D47 for ; Mon, 18 Dec 2023 03:05:31 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 2B2376AB0; Mon, 18 Dec 2023 03:04:50 +0000 (UTC) X-Original-To: linux-kernel@vger.kernel.org Received: from mx2.zhaoxin.com (mx2.zhaoxin.com [203.110.167.99]) (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 CFC4228FA for ; Mon, 18 Dec 2023 03:04:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=zhaoxin.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=zhaoxin.com X-ASG-Debug-ID: 1702868675-1eb14e538d375e0001-xx1T2L Received: from ZXSHMBX3.zhaoxin.com (ZXSHMBX3.zhaoxin.com [10.28.252.165]) by mx2.zhaoxin.com with ESMTP id l2Uw6D7LSDFlAqTa (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NO); Mon, 18 Dec 2023 11:04:35 +0800 (CST) X-Barracuda-Envelope-From: LeoLiu-oc@zhaoxin.com X-Barracuda-RBL-Trusted-Forwarder: 10.28.252.165 Received: from ZXBJMBX03.zhaoxin.com (10.29.252.7) by ZXSHMBX3.zhaoxin.com (10.28.252.165) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.27; Mon, 18 Dec 2023 11:04:35 +0800 Received: from xin.lan (10.32.64.1) by ZXBJMBX03.zhaoxin.com (10.29.252.7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.27; Mon, 18 Dec 2023 11:04:32 +0800 X-Barracuda-RBL-Trusted-Forwarder: 10.28.252.165 From: LeoLiu-oc X-Barracuda-RBL-Trusted-Forwarder: 10.29.252.7 To: , , , , , , , , , , CC: , , , , LeoLiuoc Subject: [PATCH v2 0/3] Parse the HEST PCIe AER and set to relevant registers Date: Mon, 18 Dec 2023 11:04:27 +0800 X-ASG-Orig-Subj: [PATCH v2 0/3] Parse the HEST PCIe AER and set to relevant registers Message-ID: <20231218030430.783495-1-LeoLiu-oc@zhaoxin.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231115091612.580685-1-LeoLiu-oc@zhaoxin.com> References: <20231115091612.580685-1-LeoLiu-oc@zhaoxin.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-ClientProxiedBy: zxbjmbx1.zhaoxin.com (10.29.252.163) To ZXBJMBX03.zhaoxin.com (10.29.252.7) X-Barracuda-Connect: ZXSHMBX3.zhaoxin.com[10.28.252.165] X-Barracuda-Start-Time: 1702868675 X-Barracuda-Encrypted: ECDHE-RSA-AES128-GCM-SHA256 X-Barracuda-URL: https://10.28.252.36:4443/cgi-mod/mark.cgi X-Virus-Scanned: by bsmtpd at zhaoxin.com X-Barracuda-Scan-Msg-Size: 1278 X-Barracuda-BRTS-Status: 0 X-Barracuda-Bayes: INNOCENT GLOBAL 0.0000 1.0000 -2.0210 X-Barracuda-Spam-Score: -2.02 X-Barracuda-Spam-Status: No, SCORE=-2.02 using global scores of TAG_LEVEL=1000.0 QUARANTINE_LEVEL=1000.0 KILL_LEVEL=9.0 tests= X-Barracuda-Spam-Report: Code version 3.2, rules version 3.2.3.118228 Rule breakdown below pts rule name description ---- ---------------------- -------------------------------------------------- X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1782620975896486378 X-GMAIL-MSGID: 1785587283349649951 From: LeoLiuoc According to the Section 18.3.2.4, 18.3.2.5 and 18.3.2.6 in ACPI SPEC r6.5, the register value form HEST PCI Express AER Structure should be written to relevant PCIe Device's AER Capabilities.So the purpose of the patch set is to extract register value from HEST PCI Express AER structures and program them into PCIe Device's AER registers. Refer to the ACPI SPEC r6.5 for the more detailed description. This patch is an effective supplement to _HPP/_HPX method when the Firmware does not support the _HPP/_HPX method and can be specially configured for the AER register of the specific device. --- v1->v2: - Move the definition of structure "hest_parse_aer_info" to file apei.h. LeoLiuoc (3): ACPI/APEI: Add hest_parse_pcie_aer() PCI: Add AER bits #defines for PCIe to PCI/PCI-X Bridge PCI/ACPI: Add pci_acpi_program_hest_aer_params() drivers/acpi/apei/hest.c | 69 +++++++++++++++++++++++- drivers/pci/pci-acpi.c | 98 +++++++++++++++++++++++++++++++++++ drivers/pci/pci.h | 9 ++++ drivers/pci/probe.c | 1 + include/acpi/apei.h | 17 ++++++ include/uapi/linux/pci_regs.h | 3 ++ 6 files changed, 195 insertions(+), 2 deletions(-)