From patchwork Thu Dec 5 21:18:45 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Zaid Alali X-Patchwork-Id: 13896024 Received: from CH4PR04CU002.outbound.protection.outlook.com (mail-northcentralusazon11023133.outbound.protection.outlook.com [40.107.201.133]) (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 E1032192D69; Thu, 5 Dec 2024 21:19:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.201.133 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1733433550; cv=fail; b=OVVieCFHsFay11ThxBySz17F2gk/HlMdOlDWP8dgbOeDxAlgyB9rC8rAcIpgdWACvXg9yXhChTvag2UnszexAkp41HfQ9vMdKmW2H5QEjJ8mIQyXTCtfKmhMqOxNRUvo2mrkSjXNvkU1yQoJWo6AyTuz5qe1cNOTxXpsD+pLFcQ= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1733433550; c=relaxed/simple; bh=/IgTeWnF9/eV9kgO+Sv/RAVYg5bYskO8wcY2CliZFcY=; h=From:To:Subject:Date:Message-Id:Content-Type:MIME-Version; b=nroEPjJC19HClhqmXpSrjoHlid6/pb4ugKTBcogcfQujgn8nsxaiGPMFeliwYxKhVh7SV9Mvvb3a9dPjndgAHWRf1S5MvWGTs0+5e7VhwA3Ej/iAgalximW7pIshEapKJlraMc90+bD3F91P8EDc9rdCAbZ4UpnrdkryD8DEkAs= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=os.amperecomputing.com; spf=pass smtp.mailfrom=os.amperecomputing.com; dkim=pass (1024-bit key) header.d=os.amperecomputing.com header.i=@os.amperecomputing.com header.b=sTKry3Vf; arc=fail smtp.client-ip=40.107.201.133 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=os.amperecomputing.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=os.amperecomputing.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=os.amperecomputing.com header.i=@os.amperecomputing.com header.b="sTKry3Vf" ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=RAyKC2ElbS34fE9AC0Xw3xLTM4/GIEPU+BxuQrutkmXZu4t5QYKDvZK9A2thjUjApyvcZP+SPQdGRZ6VZrSaEymTLxwjhpcBlsDEzGuivHpIfLE3G+iwY6DofbfaIOGuzHIp47DDrllXJllnVPSeT+aNcA88F+KGuxPXLrLFt0wFSVWBSZ8+jsclD/as087yKfkxkZ80+0amgR4vY02+9OT2AuO2lMIxMKZHP5ZChl0jag81b/S3TutcnnTsncxP2qJ9H8t9LHEGbqCTbVN+Doh+Gi7KVS1n9e0tHAmqq41Vvt2USPkFMFEcaOykkDdIucB9Ib727tl4UitU2JAE0w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=lHUcyBHeEBt5BYInYGJF/hN9D8Hc3tYYVVKaaIbVYj0=; b=EUdTnBhg03e3BGtxunM30ZGA5CEFW0aaJvkuDAaFpCCkB8W/m5Vbo3W52nGqWzEPlpdYO1nMobMwMNRMUm0ssKvZBLHnmkzWjgAFezEVK44pMCDk747ZyP+VDavGy5EOlZx9a81299699o3zLp4vERyH3otVAxs8pjYkV28Gn3sBY9K1KxdH3fdIgnRO8XuCT1DRAlkVxPN7kG09pbUa5GJcf/ovgKhjelnMNU2gHXVNUuc1mpeyJsRk8YzyGmfw+DemAK/5ic7iWLz/n+5iAk4wTbJ7SgSGGaHuzy/b+UpVA4xvIu0Y8VVhfJFzaGEqI7KZTfwA/SpcQzqEh1j6Xw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=os.amperecomputing.com; dmarc=pass action=none header.from=os.amperecomputing.com; dkim=pass header.d=os.amperecomputing.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=os.amperecomputing.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=lHUcyBHeEBt5BYInYGJF/hN9D8Hc3tYYVVKaaIbVYj0=; b=sTKry3VfPcXpIOStFhZFy0DT/kvipnv7g4cfNSPbZPgtJtV0D16vEmzxlrr0aHIjULBXK6sAhYhdsmfIyNa6bcMypOG6laQeoC+BX+tD1ZF37yiBfnz7+NBSqYJKo7hMx0zLLTKQrPF/HloHkoO8oD123YmY9Cyz4iU/XSSbP9c= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=os.amperecomputing.com; Received: from SN7PR01MB7903.prod.exchangelabs.com (2603:10b6:806:34f::17) by DS0PR01MB8004.prod.exchangelabs.com (2603:10b6:8:145::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8230.9; Thu, 5 Dec 2024 21:19:05 +0000 Received: from SN7PR01MB7903.prod.exchangelabs.com ([fe80::cf45:9855:a64e:382f]) by SN7PR01MB7903.prod.exchangelabs.com ([fe80::cf45:9855:a64e:382f%3]) with mapi id 15.20.8251.007; Thu, 5 Dec 2024 21:19:05 +0000 From: Zaid Alali To: rafael@kernel.org, lenb@kernel.org, james.morse@arm.com, tony.luck@intel.com, bp@alien8.de, robert.moore@intel.com, dan.j.williams@intel.com, zaidal@os.amperecomputing.com, Jonathan.Cameron@huawei.com, Benjamin.Cheatham@amd.com, Avadhut.Naik@amd.com, viro@zeniv.linux.org.uk, arnd@arndb.de, ira.weiny@intel.com, dave.jiang@intel.com, sthanneeru.opensrc@micron.com, linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org, acpica-devel@lists.linux.dev Subject: [PATCH v2 0/9] Enable EINJv2 support Date: Thu, 5 Dec 2024 13:18:45 -0800 Message-Id: <20241205211854.43215-1-zaidal@os.amperecomputing.com> X-Mailer: git-send-email 2.34.1 X-ClientProxiedBy: MW4PR04CA0126.namprd04.prod.outlook.com (2603:10b6:303:84::11) To SN7PR01MB7903.prod.exchangelabs.com (2603:10b6:806:34f::17) Precedence: bulk X-Mailing-List: linux-acpi@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SN7PR01MB7903:EE_|DS0PR01MB8004:EE_ X-MS-Office365-Filtering-Correlation-Id: bccf9298-0e91-4894-0a9c-08dd15727289 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|366016|52116014|376014|1800799024|7416014|38350700014|921020; X-Microsoft-Antispam-Message-Info: DOLMtYoU5mXuW9DhN+ddyE6oGNNlzC/ygNGCxIyDmyEm9SFVlLwlB6Jw1mo/6eWRpMcbokyzFbCbPqC+JmS608NIW9+751rnodqwe9lauBxFc2KReA/db9VSZBrIAW3HltJToCcwV48aNo0f7sFtSQ6+iRJuUIlgfzPIKfH11N/lSzxczlWNH3qJn9QOxima7t4YXxAGVdqcnSjxij0OeDyIgL9nvFAibrWRweGo+Ku5q1ABCFeVJPuKyd0wN798QNkamu0L+WJvEl9Xqt/fbTXp0Vo+LVCvpdeDGSZRnpBjnf2UvUM/azwEYNO3Pfck5jFVwktelZ4HO3Jjz4ngP4umnFIf/Lojc1x6X55gHQir+HfojYOrzWpy9OMyP9DUPprQzKavLjet+FxlRSqKoO9DcLcI3cmHWfLcVMKo4sHt7MKGm0GbAvRR5j5H6Wr/zjzhXj1KKCK3TDwv37Qkan4oWfrecwu2irGzMPXaZmu5ZNFRf/fJM0NrV84hlfpdiPcOK0TyPDjpImhi0dnpyNVXY/QMkry+tvWe2TrrPcFPTUnHLdHPSlr/FMvGHA4ypJVDrGB8oFzYsolclbEg8p3vgkndnnrOJEfN+3VUXxEz6jovSqsSsZ+mP2yZanXZ57SzaJLKnTv67rzdy0TSC3iF3ddnlgRBTYD+YjNzuhvLfVt3ScfPWaKrs+rMwuqmWrjzJjIMFyNPWnbJr4S8xaSu1NwghdUAjaUejLs8dtaQI229UF8TjZy1/RErp7P+UPxuueMCbvl0i9zuKWjE13RYtD2n/ylOGbZxRHFNSOmhPEBWYYr6EMlEbifUl122+vrrMHG4yNf35g4aoggnf2rrMzXTLcD1GzecbgsX4AkrxzexUH3e9VBvnZDsPTI861pwy8XBdDRBKj6rIOFSjzF8SrknlBGx36D2w0dCACJHmBJelXyg6Cu3c7K6z2lTxsvHSwQR9zts+0LQfFJXoKfgI4XkK+ofHmM2Gro3gjSfIA/4453OpaVtwt5PpdWlyqBzYTr1oYjn/V1izdI6hh8srpViDYYf0ISH4gquPBJ6GQQac9Iptt9ixkn/J7uTZKZDXv9haO5mPq2kCoe/w5Ve5g9LdU/bQaXNtukxV+84cNrvYasMjGbkA13Fsl1tyGx3fjzc2SPx8ts1JTRLIJqrpGVxmQs6ILPGIfN/jZ0aHwQSk1an2XQdeY/datryVilZ9i22cQDSxIGD4HstzA1q6zl9cfrEaS3wY+vWW2yqQhUXmO8hp7wNkwL9YBU6lsCUklxYdrNre3pjA/GX3ERjn7y3Ql+1IAOl5fdK2gpb80DuDlNn/PTIv+YlrKz5xkYvgzts+zxMrLvKMXRy7X13v61pYHcMhfNX2n5/Mw2FzelEwKQfJKq4/LAxEUWe X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SN7PR01MB7903.prod.exchangelabs.com;PTR:;CAT:NONE;SFS:(13230040)(366016)(52116014)(376014)(1800799024)(7416014)(38350700014)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2NXMBT97yjXywL172BHU0eJ7HQ9bfaTLiDthRc8U1vowLkfHAqeOHa2HxtlZVfftt39WE9BUla7lu3lqm7urdV9MwzQPotssBD66CHWMPxRhlblQMyR4CP34fv/3Jc6/K0fKHBAT3k1LavtWYi20frMQLNUeuN/jV+qf773h3lNjfE8LLprz+otKByrQgkscGoDSlhPykmiqTUw2UJjycxh4WycmQEiTSbjoQ9TH5DnHf+5EFyGR1MOpqqbtTerGxZ9ONuDt/uwnPRdoUalZggbGKw9xtgUtVhC7WnCuoPrd1H4FrvaoNpm/BCQO5vDQfTN9ADdamNVIOmn2UEVTRxeaCuxD/loVQ7Nj0ZMSBfYwlR59kDfnxfpdtuS8Q1DeTx9Axy5oKMwKTvqteSz38HXjhLW9y3lke69q9otWPClIs7giv6UCLnK6qSJARgXYxbO4HCY5DGN+0QpXHQlcjU0cNYOMZVlnyHR2ryNH4Arg94PlUOnbKCkaxQ5haeZRCPFofTbRxDK8lBXLEFYYmlAobzAI4ubpINzQldNPVqtnkZMslE2lRCOOsPnowJy+z+owKKwl5DX9UMU9jDbbG6sTExYIZSCH433HbbFhdMAGiSmNduj0VFy4= X-OriginatorOrg: os.amperecomputing.com X-MS-Exchange-CrossTenant-Network-Message-Id: bccf9298-0e91-4894-0a9c-08dd15727289 X-MS-Exchange-CrossTenant-AuthSource: SN7PR01MB7903.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Dec 2024 21:19:05.0803 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3bc2b170-fd94-476d-b0ce-4229bdc904a7 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: HJHTZP2hfD/mdLwCBOH9abYDq06rNfAT2GToW9hEyJJNv5o1meqM7ULt59NlNXjVxj1+9HhAWgApzwiSp5m9Nh1I1mnVu6MfyQuNRPJgHRnx1UrbKob2aO/F1DuDiqy6 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DS0PR01MB8004 The goal of this update is to allow the driver to simultaneously support EINJ and EINJv2. The implementation follows the approved ACPI specs(1)(2) that enables the driver to discover system capabilities through GET_ERROR_TYPE. Note: The first two ACPICA patches are to be dropped once merged in ACPICA project, see pull request(3). (1) https://bugzilla.tianocore.org/show_bug.cgi?id=4615 (2) https://bugzilla.tianocore.org/attachment.cgi?id=1521 (3) https://github.com/acpica/acpica/pull/977 Note: This revision includes an update on patch 5/9 to avoid ambiguity between EINJv1 and EINJv2 error types. Also, it includes an additional patch to fix sparse warnings triggered by test robot. Zaid Alali (9): ACPICA: Update values to hex to follow ACPI specs ACPICA: Add EINJv2 get error type action ACPI: APEI: EINJ: Fix kernel test robot sparse warning ACPI: APEI: EINJ: Remove redundant calls to einj_get_available_error_type ACPI: APEI: EINJ: Enable the discovery of EINJv2 capabilities ACPI: APEI: EINJ: Add einjv2 extension struct ACPI: APEI: EINJ: Add debugfs files for EINJv2 support ACPI: APEI: EINJ: Enable EINJv2 error injections ACPI: APEI: EINJ: Update the documentation for EINJv2 support .../firmware-guide/acpi/apei/einj.rst | 41 ++- drivers/acpi/apei/apei-internal.h | 2 +- drivers/acpi/apei/einj-core.c | 254 ++++++++++++++---- drivers/acpi/apei/einj-cxl.c | 2 +- include/acpi/actbl1.h | 25 +- 5 files changed, 260 insertions(+), 64 deletions(-)