From patchwork Tue Mar 5 03:36:39 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ivan Hu X-Patchwork-Id: 1907987 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.ubuntu.com (client-ip=185.125.189.65; helo=lists.ubuntu.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=patchwork.ozlabs.org) Received: from lists.ubuntu.com (lists.ubuntu.com [185.125.189.65]) (using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Tph8D1T3Xz23qm for ; Tue, 5 Mar 2024 14:37:15 +1100 (AEDT) Received: from localhost ([127.0.0.1] helo=lists.ubuntu.com) by lists.ubuntu.com with esmtp (Exim 4.86_2) (envelope-from ) id 1rhLbq-000810-SQ; Tue, 05 Mar 2024 03:36:56 +0000 Received: from smtp-relay-canonical-0.internal ([10.131.114.83] helo=smtp-relay-canonical-0.canonical.com) by lists.ubuntu.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1rhLbj-0007zA-Is for kernel-team@lists.ubuntu.com; Tue, 05 Mar 2024 03:36:47 +0000 Received: from canonical.com (unknown [106.104.136.95]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-canonical-0.canonical.com (Postfix) with ESMTPSA id CE57D3F863 for ; Tue, 5 Mar 2024 03:36:46 +0000 (UTC) From: Ivan Hu To: kernel-team@lists.ubuntu.com Subject: [SRU][M][PATCH v6 0/3] Dynamically determine acpi_handle_list size Date: Tue, 5 Mar 2024 11:36:39 +0800 Message-Id: <20240305033642.98326-1-ivan.hu@canonical.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" BugLink: https://bugs.launchpad.net/bugs/2049733 [Impact] ACPI handle list will be dynamic allocated without default fixed size. [Fix] Currently the ACPI_MAX_HANDLES is defined fix to 10, and it is not enough for some platforms that called ACPI _PSL method to get passive cooling device objects. then will get the error message "Invalid passive threshold", this patch change the fixed size with the dynamic handle list size which fixes the handle reference error. [Test Case] check the dmesg to see if there is the error message "Invalid passive threshold" [Where problems could occur] Only change the fixed size with the dynamic handle list size. Risk of regression is low. [Other Info] Change of v2: add the "ACPI: utils: Fix error path in acpi_evaluate_reference()" patch for fixing the "ACPI: utils: Dynamically determine acpi_handle_list size" issue and modify the cherrypicked to backported Change of v3 add missing [SRU][M] Change of v4 add missing BugLinks Change of v5 add backport explanation Change of v6 add the "ACPI: utils: Fix white space in struct acpi_handle_list definition" patch Rafael J. Wysocki (3): ACPI: utils: Dynamically determine acpi_handle_list size ACPI: utils: Fix error path in acpi_evaluate_reference() ACPI: utils: Fix white space in struct acpi_handle_list definition drivers/acpi/acpi_lpss.c | 10 ++- drivers/acpi/scan.c | 1 + drivers/acpi/thermal.c | 29 ++++++--- drivers/acpi/utils.c | 63 ++++++++++++++++++- .../platform/surface/surface_acpi_notify.c | 10 ++- include/acpi/acpi_bus.h | 9 ++- 6 files changed, 101 insertions(+), 21 deletions(-) Acked-by: Andrei Gherzan Acked-by: Manuel Diewald