Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1171086

[PATCH v2 07/28] ACPICA: Tables: Fix an issue that FACS initialization is performed twice.

From Lv Zheng <lv.zheng@intel.com>
Newsgroups linux.kernel
Subject [PATCH v2 07/28] ACPICA: Tables: Fix an issue that FACS initialization is performed twice.
Date 2015-06-24 05:10 +0200
Message-ID <pEJez-5H5-43@gated-at.bofh.it> (permalink)
References <pCVjP-3H9-3@gated-at.bofh.it> <pEJex-5H5-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


ACPICA commit 90f5332a15e9d9ba83831ca700b2b9f708274658

This patch adds a new FACS initialization flag for acpi_tb_initialize().
acpi_enable_subsystem() might be invoked several times in OS bootup process,
and we don't want FACS initialization to be invoked twice. Lv Zheng.

Link: https://github.com/acpica/acpica/commit/90f5332a
Cc: All applicable <stable@vger.kernel.org> # All applicable
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Bob Moore <robert.moore@intel.com>
---
 drivers/acpi/acpica/utxfinit.c |   10 ++++++----
 include/acpi/actypes.h         |    1 +
 2 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/drivers/acpi/acpica/utxfinit.c b/drivers/acpi/acpica/utxfinit.c
index 083a768..42a32a6 100644
--- a/drivers/acpi/acpica/utxfinit.c
+++ b/drivers/acpi/acpica/utxfinit.c
@@ -179,10 +179,12 @@ acpi_status __init acpi_enable_subsystem(u32 flags)
 	 * Obtain a permanent mapping for the FACS. This is required for the
 	 * Global Lock and the Firmware Waking Vector
 	 */
-	status = acpi_tb_initialize_facs();
-	if (ACPI_FAILURE(status)) {
-		ACPI_WARNING((AE_INFO, "Could not map the FACS table"));
-		return_ACPI_STATUS(status);
+	if (!(flags & ACPI_NO_FACS_INIT)) {
+		status = acpi_tb_initialize_facs();
+		if (ACPI_FAILURE(status)) {
+			ACPI_WARNING((AE_INFO, "Could not map the FACS table"));
+			return_ACPI_STATUS(status);
+		}
 	}
 #endif				/* !ACPI_REDUCED_HARDWARE */
 
diff --git a/include/acpi/actypes.h b/include/acpi/actypes.h
index 63fd7f5..ff0b53e 100644
--- a/include/acpi/actypes.h
+++ b/include/acpi/actypes.h
@@ -568,6 +568,7 @@ typedef u64 acpi_integer;
 #define ACPI_NO_ACPI_ENABLE             0x10
 #define ACPI_NO_DEVICE_INIT             0x20
 #define ACPI_NO_OBJECT_INIT             0x40
+#define ACPI_NO_FACS_INIT               0x80
 
 /*
  * Initialization state
-- 
1.7.10

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v2 00/28] ACPICA: 20150619 Release Lv Zheng <lv.zheng@intel.com> - 2015-06-24 05:10 +0200
  [PATCH v2 21/28] ACPICA: acpidump: Convert the default behavior to dump from /sys/firmware/acpi/tables. Lv Zheng <lv.zheng@intel.com> - 2015-06-24 05:10 +0200
  [PATCH v2 09/28] ACPICA: Tables: Enable default 64-bit FADT addresses favor. Lv Zheng <lv.zheng@intel.com> - 2015-06-24 05:10 +0200
  [PATCH v2 25/28] ACPICA: Update definitions for the TCPA and TPM2 ACPI tables. Lv Zheng <lv.zheng@intel.com> - 2015-06-24 05:10 +0200
  [PATCH v2 13/28] ACPICA: Utilities: Add _CLS processing Lv Zheng <lv.zheng@intel.com> - 2015-06-24 05:10 +0200
  [PATCH v2 05/28] ACPICA: Hardware: Enable firmware waking vector for both 32-bit and 64-bit FACS. Lv Zheng <lv.zheng@intel.com> - 2015-06-24 05:10 +0200
    Re: [PATCH v2 05/28] ACPICA: Hardware: Enable firmware waking vector for both 32-bit and 64-bit FACS. "Rafael J. Wysocki" <rjw@rjwysocki.net> - 2015-06-25 01:40 +0200
      RE: [PATCH v2 05/28] ACPICA: Hardware: Enable firmware waking  vector for both 32-bit and 64-bit FACS. "Zheng, Lv" <lv.zheng@intel.com> - 2015-06-25 02:50 +0200
  [PATCH v2 07/28] ACPICA: Tables: Fix an issue that FACS initialization is performed twice. Lv Zheng <lv.zheng@intel.com> - 2015-06-24 05:10 +0200
  [PATCH v2 20/28] ACPICA: acpidump: Allow customized tables to be dumped without accessing /dev/mem. Lv Zheng <lv.zheng@intel.com> - 2015-06-24 05:10 +0200

csiph-web