[edk2-devel] [PATCH 07/43] OvmfPkg/AcpiPlatformDxe: sort #includes and [LibraryClasses]
Laszlo Ersek
lersek at redhat.com
Wed May 26 20:14:10 UTC 2021
Place all public #includes first, all module-private #includes second.
Separate them with a single empty line. Keep each section sorted in
itself.
Sort all sections in both INF files.
Cc: Ard Biesheuvel <ardb+tianocore at kernel.org>
Cc: Jordan Justen <jordan.l.justen at intel.com>
Cc: Philippe Mathieu-Daudé <philmd at redhat.com>
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2122
Signed-off-by: Laszlo Ersek <lersek at redhat.com>
---
OvmfPkg/AcpiPlatformDxe/AcpiPlatformDxe.inf | 18 +++++++++---------
OvmfPkg/AcpiPlatformDxe/QemuFwCfgAcpiPlatformDxe.inf | 2 +-
OvmfPkg/AcpiPlatformDxe/AcpiPlatform.h | 15 ++++++---------
OvmfPkg/AcpiPlatformDxe/EntryPoint.c | 1 +
OvmfPkg/AcpiPlatformDxe/Qemu.c | 11 ++++++-----
OvmfPkg/AcpiPlatformDxe/QemuFwCfgAcpi.c | 12 ++++++------
OvmfPkg/AcpiPlatformDxe/Xen.c | 3 ++-
7 files changed, 31 insertions(+), 31 deletions(-)
diff --git a/OvmfPkg/AcpiPlatformDxe/AcpiPlatformDxe.inf b/OvmfPkg/AcpiPlatformDxe/AcpiPlatformDxe.inf
index e486b8afa56d..4522d7f6110c 100644
--- a/OvmfPkg/AcpiPlatformDxe/AcpiPlatformDxe.inf
+++ b/OvmfPkg/AcpiPlatformDxe/AcpiPlatformDxe.inf
@@ -29,30 +29,30 @@ [Sources]
Qemu.c
QemuFwCfgAcpi.c
QemuLoader.h
Xen.c
[Packages]
- MdePkg/MdePkg.dec
MdeModulePkg/MdeModulePkg.dec
+ MdePkg/MdePkg.dec
OvmfPkg/OvmfPkg.dec
UefiCpuPkg/UefiCpuPkg.dec
[LibraryClasses]
- UefiLib
- PcdLib
+ BaseLib
BaseMemoryLib
DebugLib
- UefiBootServicesTableLib
- UefiDriverEntryPoint
- QemuFwCfgLib
- QemuFwCfgS3Lib
- MemoryAllocationLib
- BaseLib
DxeServicesTableLib
+ MemoryAllocationLib
OrderedCollectionLib
+ PcdLib
+ QemuFwCfgLib
+ QemuFwCfgS3Lib
+ UefiBootServicesTableLib
+ UefiDriverEntryPoint
+ UefiLib
XenPlatformLib
[Protocols]
gEfiAcpiTableProtocolGuid # PROTOCOL ALWAYS_CONSUMED
gEfiFirmwareVolume2ProtocolGuid # PROTOCOL SOMETIMES_CONSUMED
gEfiPciIoProtocolGuid # PROTOCOL SOMETIMES_CONSUMED
diff --git a/OvmfPkg/AcpiPlatformDxe/QemuFwCfgAcpiPlatformDxe.inf b/OvmfPkg/AcpiPlatformDxe/QemuFwCfgAcpiPlatformDxe.inf
index c9ec4f60bc78..cc24f35bd83a 100644
--- a/OvmfPkg/AcpiPlatformDxe/QemuFwCfgAcpiPlatformDxe.inf
+++ b/OvmfPkg/AcpiPlatformDxe/QemuFwCfgAcpiPlatformDxe.inf
@@ -27,14 +27,14 @@ [Sources]
PciDecoding.c
QemuFwCfgAcpi.c
QemuFwCfgAcpiPlatform.c
QemuLoader.h
[Packages]
- MdePkg/MdePkg.dec
MdeModulePkg/MdeModulePkg.dec
+ MdePkg/MdePkg.dec
OvmfPkg/OvmfPkg.dec
[LibraryClasses]
BaseLib
DebugLib
MemoryAllocationLib
diff --git a/OvmfPkg/AcpiPlatformDxe/AcpiPlatform.h b/OvmfPkg/AcpiPlatformDxe/AcpiPlatform.h
index c8dee8ab7a3c..511a30782f6d 100644
--- a/OvmfPkg/AcpiPlatformDxe/AcpiPlatform.h
+++ b/OvmfPkg/AcpiPlatformDxe/AcpiPlatform.h
@@ -6,25 +6,22 @@
**/
#ifndef ACPI_PLATFORM_H_
#define ACPI_PLATFORM_H_
-#include <PiDxe.h>
-
-#include <Protocol/AcpiTable.h>
-#include <Protocol/FirmwareVolume2.h>
-#include <Protocol/PciIo.h>
-
+#include <IndustryStandard/Acpi.h>
#include <Library/BaseLib.h>
-#include <Library/UefiBootServicesTableLib.h>
#include <Library/DebugLib.h>
#include <Library/PcdLib.h>
+#include <Library/UefiBootServicesTableLib.h>
#include <Library/XenPlatformLib.h>
-
-#include <IndustryStandard/Acpi.h>
+#include <PiDxe.h>
+#include <Protocol/AcpiTable.h>
+#include <Protocol/FirmwareVolume2.h>
+#include <Protocol/PciIo.h>
typedef struct {
EFI_PCI_IO_PROTOCOL *PciIo;
UINT64 PciAttributes;
} ORIGINAL_ATTRIBUTES;
diff --git a/OvmfPkg/AcpiPlatformDxe/EntryPoint.c b/OvmfPkg/AcpiPlatformDxe/EntryPoint.c
index f66f89291157..fb07ed85373d 100644
--- a/OvmfPkg/AcpiPlatformDxe/EntryPoint.c
+++ b/OvmfPkg/AcpiPlatformDxe/EntryPoint.c
@@ -5,12 +5,13 @@
Copyright (c) 2008 - 2015, Intel Corporation. All rights reserved.<BR>
SPDX-License-Identifier: BSD-2-Clause-Patent
**/
#include <Guid/RootBridgesConnectedEventGroup.h>
+
#include "AcpiPlatform.h"
STATIC
EFI_ACPI_TABLE_PROTOCOL *
FindAcpiTableProtocol (
VOID
diff --git a/OvmfPkg/AcpiPlatformDxe/Qemu.c b/OvmfPkg/AcpiPlatformDxe/Qemu.c
index 7fb42270043f..bed3b16159a6 100644
--- a/OvmfPkg/AcpiPlatformDxe/Qemu.c
+++ b/OvmfPkg/AcpiPlatformDxe/Qemu.c
@@ -6,20 +6,21 @@
Copyright (C) 2012-2014, Red Hat, Inc.
SPDX-License-Identifier: BSD-2-Clause-Patent
**/
-#include "AcpiPlatform.h"
+#include <IndustryStandard/Acpi.h>
#include <Library/BaseMemoryLib.h>
-#include <Library/MemoryAllocationLib.h>
-#include <Library/QemuFwCfgLib.h>
#include <Library/DxeServicesTableLib.h>
-#include <Library/PcdLib.h>
+#include <Library/MemoryAllocationLib.h>
#include <Library/OrderedCollectionLib.h>
-#include <IndustryStandard/Acpi.h>
+#include <Library/PcdLib.h>
+#include <Library/QemuFwCfgLib.h>
+
+#include "AcpiPlatform.h"
BOOLEAN
QemuDetected (
VOID
)
{
diff --git a/OvmfPkg/AcpiPlatformDxe/QemuFwCfgAcpi.c b/OvmfPkg/AcpiPlatformDxe/QemuFwCfgAcpi.c
index b62027db6e66..c07b84a21385 100644
--- a/OvmfPkg/AcpiPlatformDxe/QemuFwCfgAcpi.c
+++ b/OvmfPkg/AcpiPlatformDxe/QemuFwCfgAcpi.c
@@ -5,23 +5,23 @@
Copyright (C) 2012-2014, Red Hat, Inc.
SPDX-License-Identifier: BSD-2-Clause-Patent
**/
-#include "AcpiPlatform.h"
-#include "QemuLoader.h"
+#include <IndustryStandard/Acpi.h>
#include <Library/BaseMemoryLib.h>
+#include <Library/DxeServicesTableLib.h>
#include <Library/MemoryAllocationLib.h>
+#include <Library/OrderedCollectionLib.h>
+#include <Library/PcdLib.h>
#include <Library/QemuFwCfgLib.h>
#include <Library/QemuFwCfgS3Lib.h>
-#include <Library/DxeServicesTableLib.h>
-#include <Library/PcdLib.h>
-#include <Library/OrderedCollectionLib.h>
-#include <IndustryStandard/Acpi.h>
+#include "AcpiPlatform.h"
+#include "QemuLoader.h"
//
// The user structure for the ordered collection that will track the fw_cfg
// blobs under processing.
//
typedef struct {
diff --git a/OvmfPkg/AcpiPlatformDxe/Xen.c b/OvmfPkg/AcpiPlatformDxe/Xen.c
index 289ef971c4b8..1d69989042c6 100644
--- a/OvmfPkg/AcpiPlatformDxe/Xen.c
+++ b/OvmfPkg/AcpiPlatformDxe/Xen.c
@@ -5,15 +5,16 @@
Copyright (c) 2012, Bei Guan <gbtju85 at gmail.com>
SPDX-License-Identifier: BSD-2-Clause-Patent
**/
-#include "AcpiPlatform.h"
#include <Library/BaseLib.h>
+#include "AcpiPlatform.h"
+
#define XEN_ACPI_PHYSICAL_ADDRESS 0x000EA020
#define XEN_BIOS_PHYSICAL_END 0x000FFFFF
EFI_ACPI_2_0_ROOT_SYSTEM_DESCRIPTION_POINTER *XenAcpiRsdpStructurePtr = NULL;
/**
--
2.19.1.3.g30247aa5d201
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#75676): https://edk2.groups.io/g/devel/message/75676
Mute This Topic: https://groups.io/mt/83110397/1813853
Mute #includes:https://edk2.groups.io/g/devel/mutehashtag/includes
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-
More information about the edk2-devel-archive
mailing list