Re: [PATCH 10/43] OvmfPkg/AcpiPlatformDxe: consolidate #includes and [LibraryClasses] #includes


Philippe Mathieu-Daudé
 

On 5/26/21 10:14 PM, Laszlo Ersek wrote:
- #include only such public headers in "AcpiPlatform.h" that are required
by the function declarations and type definitions introduced in
"AcpiPlatform.h". Don't use "AcpiPlatform.h" as a convenience #include
file.

- In every file, list every necessary public #include individually, with
an example identifier that's actually consumed.

- Remove unnecessary lib classes, add unlisted lib classes.

- Remove unnecessary #include directives, add unlisted #include
directives.

Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Jordan Justen <jordan.l.justen@intel.com>
Cc: Philippe Mathieu-Daudé <philmd@redhat.com>
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2122
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
---
OvmfPkg/AcpiPlatformDxe/AcpiPlatformDxe.inf | 1 -
OvmfPkg/AcpiPlatformDxe/QemuFwCfgAcpiPlatformDxe.inf | 2 ++
OvmfPkg/AcpiPlatformDxe/AcpiPlatform.h | 12 ++----------
OvmfPkg/AcpiPlatformDxe/AcpiPlatform.c | 5 +++++
OvmfPkg/AcpiPlatformDxe/BootScript.c | 7 ++++---
OvmfPkg/AcpiPlatformDxe/EntryPoint.c | 6 +++++-
OvmfPkg/AcpiPlatformDxe/PciDecoding.c | 4 +++-
OvmfPkg/AcpiPlatformDxe/Qemu.c | 14 +++++++-------
OvmfPkg/AcpiPlatformDxe/QemuFwCfgAcpi.c | 19 ++++++++++---------
OvmfPkg/AcpiPlatformDxe/Xen.c | 4 +++-
10 files changed, 41 insertions(+), 33 deletions(-)
Reviewed-by: Philippe Mathieu-Daude <philmd@redhat.com>

Join devel@edk2.groups.io to automatically receive all group messages.