Message ID | 20240228-cxl-cper3-v1-0-6aa3f1343c6c@intel.com |
---|---|
Headers |
Return-Path: <linux-kernel+bounces-86211-ouuuleilei=gmail.com@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7301:2097:b0:108:e6aa:91d0 with SMTP id gs23csp223126dyb; Wed, 28 Feb 2024 23:14:07 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCVJQPtcKvSdtNEvCqAWwYXGL79Is69CmUeBgfb89JfcWsJJy1IXdYIk+l2oypDmZVVLX32jTpEigsVUum0Yxmgdx9h6Hg== X-Google-Smtp-Source: AGHT+IEdWRzEVQdwfhhZ/o87bBhGaL5NQIGHdeK5R9m67IyZe04HzGt3++b2bSwCviX2j6/TZ8jo X-Received: by 2002:aa7:c997:0:b0:565:ebf2:a257 with SMTP id c23-20020aa7c997000000b00565ebf2a257mr851844edt.19.1709190847770; Wed, 28 Feb 2024 23:14:07 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709190847; cv=pass; d=google.com; s=arc-20160816; b=M8B/4qDCIbSCNbNTBZX9h0Po9/UEFsb4C/wN/sQt/aqoTsMLZZMNDPPdeuxDFbNoMj 8LaObElLSfqM+GsTKdm8Fgw25TMzslGDhnt6La6INLYHZ1MnL4S9UEGX2TlE+EtbIVtk ayZOmqfrwbGEvJO4Dmgq9MZ9oKQPLgGY99Vwp9dQSDoXenw/JHvd9naiSrDjHLFvYQau Kw/kvN32nRBCYym/yVdi6l8El9gw5J+Tfa0vBcRDBeG9Ikdx+FHQUtPOAYoT4SRzvxiv wKLDlFzYu5HfaAK7TmlznNRgMdEfurVNvMcC5vqxkqyvQ+wkcaxwhGIp4QjeFakXAlTc BIMQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:from :dkim-signature; bh=Mo9KTZ9yaIyNkPbqpennImhCqzSRu257uyU1tdZYNTM=; fh=uQZK3caUunkA150NhQpGeu+YE9BAq7zXlZhM52qw1TY=; b=tEkAmkOyqaGp/Ny3qzRcpwTxaMG3tDZ5VWR5uuiajug5ZdR89wD1hsEnD/RPxENhoH b7mbeuC3rBToUOBO0y9wveW+Gx8/cSwykL1yMjDrQsoUiYCAKow/GCbovQHhgAcQBHkE B/nFhL/VxVfsY7GnQAF8HBOnJ0Z/xoStCIkmL0zdNWbfTms2YVKkaSDB5FQdws6yfvat e+e96MzSSkTOzIokxApEqiDZiD0H15LHZdoxNz0hgnCcTMpf5Eh8MWBL80WcWwMd3gQL KYDv5NyluFHxuxhB+yhm4ze6H9rNAQjGuQbMkUMu5IxT5CWosmGVMWm4+WGqmW7YQpf4 Bhxg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=UiXLkR9C; arc=pass (i=1 spf=pass spfdomain=intel.com dkim=pass dkdomain=intel.com dmarc=pass fromdomain=intel.com); spf=pass (google.com: domain of linux-kernel+bounces-86211-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-86211-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id r15-20020aa7c14f000000b005660d817b8csi322915edp.188.2024.02.28.23.14.07 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Feb 2024 23:14:07 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-86211-ouuuleilei=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=@intel.com header.s=Intel header.b=UiXLkR9C; arc=pass (i=1 spf=pass spfdomain=intel.com dkim=pass dkdomain=intel.com dmarc=pass fromdomain=intel.com); spf=pass (google.com: domain of linux-kernel+bounces-86211-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-86211-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com 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 66D921F246EE for <ouuuleilei@gmail.com>; Thu, 29 Feb 2024 07:14:07 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D1E1E47F51; Thu, 29 Feb 2024 07:13:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="UiXLkR9C" Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.20]) (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 CB854446B4; Thu, 29 Feb 2024 07:13:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.175.65.20 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709190805; cv=none; b=Hd/dMr62089ajA/tZEfDC6xHXnsutdUWcw9JB2mu/aiI1HGUneuXdiV9DVx7ZdJ0XBJVVbgA/B3m1fIOn5761T/adcv2TTmpwXwXG5NF7o2mh9GewlwpeKjRgQvbXIGgMrVzSGuh7gCOgP5LagG8WFyiiF1IqC0adc4jWk7ZLk0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709190805; c=relaxed/simple; bh=G2TxGFUdAAXJKdIfxQBleGyn2fBf9uj4lSj2hBlEcmE=; h=From:Subject:Date:Message-Id:MIME-Version:Content-Type:To:Cc; b=ummvUjBVgKEGZID0/BLDaVrPqkoAjbxbrRZZ/S7K63D+5+qQJUgeLHsh4zTZUpBRgsizkt36VEvkmTgPfIM9IdnkWOvtkHzo3a/il8DC2+pyG2h5jD6ZsRXbQ0+wXeMfbHsbAAPMhndgvI3Wsamg+sXY8lYdqleAbXtYO6KZhTQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=intel.com; spf=pass smtp.mailfrom=intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=UiXLkR9C; arc=none smtp.client-ip=198.175.65.20 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=intel.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=intel.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1709190803; x=1740726803; h=from:subject:date:message-id:mime-version: content-transfer-encoding:to:cc; bh=G2TxGFUdAAXJKdIfxQBleGyn2fBf9uj4lSj2hBlEcmE=; b=UiXLkR9Cp4hO1eXJyqVSuXXFP1C0yilwDUhquHfzLVlas54+ScZF/j5l 9ts2XZcgDIdWZzz5xdYIOs/JF4GIQxlVb9y25EAuc7WQ83QiQTz57cmL2 NWk2aN+81tnemZfaUSMxbiUjntXDnNZi55V7OQPgLg+KJuJoSzxLhrFT9 gSzYRoP6LpyuJvqPF7cHZ2ndbjI808qsPJnoKs49nYx931k2ZXaneNOOh hetnYpvuOmRhgufF8LMPZyck4KsPzwgXjuoKOaWxNap/j/T9Imx0EwRA5 LZE+33TFOlMrbUy9TClGtbFUFDziNW6ykovZUTU7a1c8B6mkvRK4tCebM A==; X-IronPort-AV: E=McAfee;i="6600,9927,10998"; a="3519845" X-IronPort-AV: E=Sophos;i="6.06,192,1705392000"; d="scan'208";a="3519845" Received: from orviesa008.jf.intel.com ([10.64.159.148]) by orvoesa112.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Feb 2024 23:13:22 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.06,192,1705392000"; d="scan'208";a="8283933" Received: from iweiny-desk3.amr.corp.intel.com (HELO localhost) ([10.213.166.213]) by orviesa008-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Feb 2024 23:13:21 -0800 From: Ira Weiny <ira.weiny@intel.com> Subject: [PATCH 0/4] efi/cxl-cper: Report CXL CPER events through tracing Date: Wed, 28 Feb 2024 23:13:15 -0800 Message-Id: <20240228-cxl-cper3-v1-0-6aa3f1343c6c@intel.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: <linux-kernel.vger.kernel.org> List-Subscribe: <mailto:linux-kernel+subscribe@vger.kernel.org> List-Unsubscribe: <mailto:linux-kernel+unsubscribe@vger.kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-B4-Tracking: v=1; b=H4sIAIsu4GUC/6tWKk4tykwtVrJSqFYqSi3LLM7MzwNyDHUUlJIzE vPSU3UzU4B8JSMDIxMDIyMD3eSKHN3kgtQiY11jg1RTUyNzyzRLYzMloPqCotS0zAqwWdGxtbU AOfAb71sAAAA= To: Dan Williams <dan.j.williams@intel.com>, Jonathan Cameron <jonathan.cameron@huawei.com>, Smita Koralahalli <Smita.KoralahalliChannabasappa@amd.com>, Shiju Jose <shiju.jose@huawei.com> Cc: Dan Carpenter <dan.carpenter@linaro.org>, Yazen Ghannam <yazen.ghannam@amd.com>, Davidlohr Bueso <dave@stgolabs.net>, Dave Jiang <dave.jiang@intel.com>, Alison Schofield <alison.schofield@intel.com>, Vishal Verma <vishal.l.verma@intel.com>, Ard Biesheuvel <ardb@kernel.org>, linux-efi@vger.kernel.org, linux-kernel@vger.kernel.org, linux-cxl@vger.kernel.org, Ira Weiny <ira.weiny@intel.com>, "Rafael J. Wysocki" <rafael@kernel.org>, Tony Luck <tony.luck@intel.com>, Borislav Petkov <bp@alien8.de> X-Mailer: b4 0.13-dev-2d940 X-Developer-Signature: v=1; a=ed25519-sha256; t=1709190800; l=2474; i=ira.weiny@intel.com; s=20221222; h=from:subject:message-id; bh=G2TxGFUdAAXJKdIfxQBleGyn2fBf9uj4lSj2hBlEcmE=; b=XjOlXZKAEwpqnuJEnFKvUjGnxXZSncPqvFrkssW+feQFDHoP54pVx2E9WtzvCDJALiGBFE8fl DhElZ3pqyWGAepI8DDWySgAgDpUCNjPWul3jVRxN5I8o2xhN5ZsGVsf X-Developer-Key: i=ira.weiny@intel.com; a=ed25519; pk=brwqReAJklzu/xZ9FpSsMPSQ/qkSalbg6scP3w809Ec= X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1792216502156119047 X-GMAIL-MSGID: 1792216502156119047 |
Series |
efi/cxl-cper: Report CXL CPER events through tracing
|
|
Message
Ira Weiny
Feb. 29, 2024, 7:13 a.m. UTC
CXL Component Events, as defined by EFI 2.10 Section N.2.14, wrap a
mostly CXL event payload in an EFI Common Platform Error Record (CPER)
record. If a device is configured for firmware first CXL event records
are not sent directly to the host.
The CXL sub-system uniquely has DPA to HPA translation information. It
also already has event decoding/tracing. Such translations are very
useful for users to determine which system issues may correspond to
specific hardware events.
The restructuring of the event data structures in 6.8 made sharing the
data between CPER/event logs more efficient. Now re-wire the sending of
CPER records to the CXL sub-system.
In addition provide a default RAS event should the CXL module not be
loaded [ie callback not registered].
Series status/background
========================
Smita and Jonathan have been a great help with this series. Once again
thank you.
Unfortunately, with all the churn surrounding the bug which Dan
Carpenter found the maintainers were force to revert this work.
Therefore, this is a whole new series based on what is in 6.8.
Testing
=======
I've hacked up a quick debugfs patch to facilitate easier testing.[1]
With this I have verified that the bug Dan Carpenter found is fixed.
However, the tp_printk bug Jonathan found remains. The taking of the
device lock in the callback is required and the tp_printk issue is
unlikely to be fixed. Fortunately, tp_printk is not widely used so it
is anticipated this will not be an issue.
No other locking issues were found with this test and locking debug
turned on.
[1] https://github.com/weiny2/linux-kernel/commit/6c540a23cb1194d67a9dcfefb702774a99afc3b1
Signed-off-by: Ira Weiny <ira.weiny@intel.com>
---
Ira Weiny (4):
cxl/event: Add missing include files
acpi/ghes: Process CXL Component Events
cxl/pci: Register for and process CPER events
ras/events: Trace CXL CPER events even without the CXL stack loaded
drivers/acpi/apei/ghes.c | 130 ++++++++++++++++++++++++++++++++++++++++++++++
drivers/cxl/pci.c | 69 +++++++++++++++++++++++-
include/linux/cxl-event.h | 21 ++++++++
include/ras/ras_event.h | 90 ++++++++++++++++++++++++++++++++
4 files changed, 309 insertions(+), 1 deletion(-)
---
base-commit: daeacfa75d08954e1a5b71c36a8fbfcdd0b3fec9
change-id: 20240220-cxl-cper3-30e55279f936
Best regards,