]> git.proxmox.com Git - mirror_edk2.git/commitdiff
MdeModulePkg BootScriptExecutorDxe: Consume PcdAcpiS3Enable to control the code
authorStar Zeng <star.zeng@intel.com>
Thu, 7 Apr 2016 05:54:47 +0000 (13:54 +0800)
committerStar Zeng <star.zeng@intel.com>
Mon, 11 Apr 2016 00:48:29 +0000 (08:48 +0800)
Cc: Feng Tian <feng.tian@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
Tested-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
MdeModulePkg/Universal/Acpi/BootScriptExecutorDxe/BootScriptExecutorDxe.inf
MdeModulePkg/Universal/Acpi/BootScriptExecutorDxe/ScriptExecute.c

index c761f609b9ddb7fa30f244f4e64f07e20b8cf98e..a1bdee8e4dc8b35d82a7c6ec7ba37ce188035879 100644 (file)
@@ -4,7 +4,7 @@
 # This is a standalone Boot Script Executor. Standalone means it does not\r
 # depends on any PEI or DXE service.\r
 #\r
-# Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>\r
+# Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.<BR>\r
 #\r
 # This program and the accompanying materials are\r
 # licensed and made available under the terms and conditions of the BSD License\r
@@ -82,6 +82,7 @@
 [Pcd]\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdUse1GPageTable              ## SOMETIMES_CONSUMES\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdMemoryProfilePropertyMask   ## CONSUMES\r
+  gEfiMdeModulePkgTokenSpaceGuid.PcdAcpiS3Enable                ## CONSUMES\r
 \r
 [Depex]\r
   gEfiLockBoxProtocolGuid\r
index f8b27822447fa3c3de2b0794a485b405a9458128..10493bea021bbb46f183a8d0700533dcabac5e69 100644 (file)
@@ -4,7 +4,7 @@
   This driver is dispatched by Dxe core and the driver will reload itself to ACPI reserved memory\r
   in the entry point. The functionality is to interpret and restore the S3 boot script\r
 \r
-Copyright (c) 2006 - 2015, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.<BR>\r
 \r
 This program and the accompanying materials\r
 are licensed and made available under the terms and conditions of the BSD License\r
@@ -403,6 +403,10 @@ BootScriptExecutorEntryPoint (
   UINT32                                        RegEax;\r
   UINT32                                        RegEdx;\r
 \r
+  if (!PcdGetBool (PcdAcpiS3Enable)) {\r
+    return EFI_UNSUPPORTED;\r
+  }\r
+\r
   //\r
   // Test if the gEfiCallerIdGuid of this image is already installed. if not, the entry\r
   // point is loaded by DXE code which is the first time loaded. or else, it is already\r