]> git.proxmox.com Git - mirror_edk2.git/blobdiff - OvmfPkg/AcpiPlatformDxe/QemuFwCfgAcpiPlatform.c
ShellPkg/for: Fix potential null pointer deference
[mirror_edk2.git] / OvmfPkg / AcpiPlatformDxe / QemuFwCfgAcpiPlatform.c
index 88512ba3f4de2085c92ec7ff1e720f5358000e23..5cb3bac9dbb84cf71ca7cc0fd710fafc6c74dccc 100644 (file)
@@ -1,21 +1,22 @@
 /** @file\r
   OVMF ACPI Platform Driver using QEMU's fw-cfg interface\r
 \r
+  Copyright (C) 2015, Red Hat, Inc.\r
   Copyright (c) 2008 - 2014, Intel Corporation. All rights reserved.<BR>\r
-  This program and the accompanying materials\r
-  are licensed and made available under the terms and conditions of the BSD License\r
-  which accompanies this distribution.  The full text of the license may be found at\r
-  http://opensource.org/licenses/bsd-license.php\r
 \r
-  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+  This program and the accompanying materials are licensed and made available\r
+  under the terms and conditions of the BSD License which accompanies this\r
+  distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
 \r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, WITHOUT\r
+  WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 **/\r
 \r
 #include "AcpiPlatform.h"\r
 \r
 /**\r
-  Entrypoint of Acpi Platform driver.\r
+  Effective entrypoint of QEMU fw-cfg Acpi Platform driver.\r
 \r
   @param  ImageHandle\r
   @param  SystemTable\r
 **/\r
 EFI_STATUS\r
 EFIAPI\r
-QemuFwCfgAcpiPlatformEntryPoint (\r
-  IN EFI_HANDLE         ImageHandle,\r
-  IN EFI_SYSTEM_TABLE   *SystemTable\r
+InstallAcpiTables (\r
+  IN   EFI_ACPI_TABLE_PROTOCOL       *AcpiTable\r
   )\r
 {\r
   EFI_STATUS                         Status;\r
-  EFI_ACPI_TABLE_PROTOCOL            *AcpiTable;\r
-\r
-  //\r
-  // Find the AcpiTable protocol\r
-  //\r
-  Status = gBS->LocateProtocol (\r
-                  &gEfiAcpiTableProtocolGuid,\r
-                  NULL,\r
-                  (VOID**)&AcpiTable\r
-                  );\r
-  if (EFI_ERROR (Status)) {\r
-    return EFI_ABORTED;\r
-  }\r
-\r
-  Status = InstallAllQemuLinkedTables (AcpiTable);\r
+\r
+  Status = InstallQemuFwCfgTables (AcpiTable);\r
   return Status;\r
 }\r