From mboxrd@z Thu Jan 1 00:00:00 1970 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 049E615CD55; Mon, 2 Jun 2025 14:35:07 +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=1748874907; cv=none; b=LY4SdKx/52v1FT6dkGS6UFWqvA7EBCz4cT9nOmdmOEaeGaXvcudvaEAjAVfuj9AoV/fj9q3BBD8MGgRXP6KwP2K3Gcl1F+UJrUGPG7IlCY6VzMyFktrdn7bBnhVw8zvHpZY6utZ7BINcZOPJT+Lg8YFFdInVtoJpIdVMXC8grkg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1748874907; c=relaxed/simple; bh=alvV6cepbsReBSv1xgk2c0D68WknYFPIVyG4+boIXvg=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=pEARGjOX+fQrazVjZn7j4GRYbd7DyVoOip6qu5rumypgkEjWcvJA/b6kmFb3jw0nC2QkjUBynbAFIFjvIrnr0pFnlpD6O9g8vcDEjtDMgNP4haRlx5JxerQUUlU+TvZp0pdSS2/64YkJIVVvgikMBSIszVA0Kha2Y4YiSYv5+Ig= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=naMcjerV; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="naMcjerV" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 68D36C4CEEB; Mon, 2 Jun 2025 14:35:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1748874906; bh=alvV6cepbsReBSv1xgk2c0D68WknYFPIVyG4+boIXvg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=naMcjerVPY2z+8UxYFp1/NAcYmxswpWnLg2LiVisVTrhY/68dVzuhHAkhjTcrLiFC pok8jYDARBnZmAY9pw0kqrQiLeNVqScDYvB1ufAyy3sKzpMJWdWt6K+FMUOiEOnD0M ke5dwTCirHeCpaSiQ8c0nbDkyjJsX9ewflWLhUxc= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Xiaofei Tan , "Rafael J. Wysocki" , Sasha Levin Subject: [PATCH 5.4 141/204] ACPI: HED: Always initialize before evged Date: Mon, 2 Jun 2025 15:47:54 +0200 Message-ID: <20250602134301.189130831@linuxfoundation.org> X-Mailer: git-send-email 2.49.0 In-Reply-To: <20250602134255.449974357@linuxfoundation.org> References: <20250602134255.449974357@linuxfoundation.org> User-Agent: quilt/0.68 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 5.4-stable review patch. If anyone has any objections, please let me know. ------------------ From: Xiaofei Tan [ Upstream commit cccf6ee090c8c133072d5d5b52ae25f3bc907a16 ] When the HED driver is built-in, it initializes after evged because they both are at the same initcall level, so the initialization ordering depends on the Makefile order. However, this prevents RAS records coming in between the evged driver initialization and the HED driver initialization from being handled. If the number of such RAS records is above the APEI HEST error source number, the HEST resources may be exhausted, and that may affect subsequent RAS error reporting. To fix this issue, change the initcall level of HED to subsys_initcall and prevent the driver from being built as a module by changing ACPI_HED in Kconfig from "tristate" to "bool". Signed-off-by: Xiaofei Tan Link: https://patch.msgid.link/20250212063408.927666-1-tanxiaofei@huawei.com [ rjw: Changelog edits ] Signed-off-by: Rafael J. Wysocki Signed-off-by: Sasha Levin --- drivers/acpi/Kconfig | 2 +- drivers/acpi/hed.c | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/drivers/acpi/Kconfig b/drivers/acpi/Kconfig index ebe1e9e5fd81c..3902fe64c484d 100644 --- a/drivers/acpi/Kconfig +++ b/drivers/acpi/Kconfig @@ -431,7 +431,7 @@ config ACPI_SBS the modules will be called sbs and sbshc. config ACPI_HED - tristate "Hardware Error Device" + bool "Hardware Error Device" help This driver supports the Hardware Error Device (PNP0C33), which is used to report some hardware errors notified via diff --git a/drivers/acpi/hed.c b/drivers/acpi/hed.c index cf148287e2baf..75166839c99e0 100644 --- a/drivers/acpi/hed.c +++ b/drivers/acpi/hed.c @@ -72,7 +72,12 @@ static struct acpi_driver acpi_hed_driver = { .notify = acpi_hed_notify, }, }; -module_acpi_driver(acpi_hed_driver); + +static int __init acpi_hed_driver_init(void) +{ + return acpi_bus_register_driver(&acpi_hed_driver); +} +subsys_initcall(acpi_hed_driver_init); ACPI_MODULE_NAME("hed"); MODULE_AUTHOR("Huang Ying"); -- 2.39.5