]> git.proxmox.com Git - mirror_edk2.git/commitdiff
OvmfPkg/Bhyve: Fix various style issues
authorRebecca Cran <rebecca@bsdio.com>
Mon, 30 Nov 2020 05:34:12 +0000 (22:34 -0700)
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Mon, 30 Nov 2020 17:49:39 +0000 (17:49 +0000)
Fix ordering of includes, sources, libraries etc.
Remove leading/trailing underscores from include guards.
Change INF and DSC version numbers to be decimal.

Signed-off-by: Rebecca Cran <rebecca@bsdio.com>
Message-Id: <20201130053412.2-6-rebecca@bsdio.com>
Acked-by: Peter Grehan <grehan@freebsd.org>
Acked-by: Laszlo Ersek <lersek@redhat.com>
Build-tested-by: Laszlo Ersek <lersek@redhat.com>
15 files changed:
OvmfPkg/Bhyve/AcpiPlatformDxe/AcpiPlatform.c
OvmfPkg/Bhyve/AcpiPlatformDxe/AcpiPlatform.h
OvmfPkg/Bhyve/AcpiPlatformDxe/AcpiPlatformDxe.inf
OvmfPkg/Bhyve/AcpiPlatformDxe/Bhyve.c
OvmfPkg/Bhyve/AcpiTables/AcpiTables.inf
OvmfPkg/Bhyve/AcpiTables/Platform.h
OvmfPkg/Bhyve/BhyveRfbDxe/BhyveRfbDxe.inf
OvmfPkg/Bhyve/BhyveRfbDxe/Gop.h
OvmfPkg/Bhyve/BhyveX64.dsc
OvmfPkg/Bhyve/PlatformPei/Cmos.h
OvmfPkg/Bhyve/PlatformPei/Fv.c
OvmfPkg/Bhyve/PlatformPei/Platform.c
OvmfPkg/Bhyve/PlatformPei/PlatformPei.inf
OvmfPkg/Bhyve/SmbiosPlatformDxe/SmbiosPlatformDxe.h
OvmfPkg/Bhyve/SmbiosPlatformDxe/SmbiosPlatformDxe.inf

index 31bbf6c474c7a604058d40dadd72cfcb802222c3..d5c78c61d5ad0d0f96ad5d119c7a4dd2e5e7e03d 100644 (file)
@@ -1,8 +1,9 @@
 /** @file\r
-  OVMF ACPI Platform Driver\r
+  bhyve ACPI Platform Driver\r
 \r
   Copyright (c) 2020, Rebecca Cran <rebecca@bsdio.com>\r
   Copyright (c) 2008 - 2012, Intel Corporation. All rights reserved.<BR>\r
+\r
   SPDX-License-Identifier: BSD-2-Clause-Patent\r
 \r
 **/\r
index d30cd11a1dc9efb4d7130bda026c8bc656beff23..994ee2c7cded4ffc9f28cd90f20781e6e1147ecc 100644 (file)
@@ -1,5 +1,5 @@
 /** @file\r
-  Sample ACPI Platform Driver\r
+  bhyve ACPI Platform Driver\r
 \r
   Copyright (c) 2020, Rebecca Cran <rebecca@bsdio.com>\r
   Copyright (c) 2008 - 2012, Intel Corporation. All rights reserved.<BR>\r
 #define _ACPI_PLATFORM_H_INCLUDED_\r
 \r
 #include <PiDxe.h>\r
-\r
 #include <Protocol/AcpiTable.h>\r
 #include <Protocol/FirmwareVolume2.h>\r
 #include <Protocol/PciIo.h>\r
-\r
 #include <Library/BaseLib.h>\r
-#include <Library/UefiBootServicesTableLib.h>\r
 #include <Library/DebugLib.h>\r
 #include <Library/PcdLib.h>\r
+#include <Library/UefiBootServicesTableLib.h>\r
 #include <Library/XenPlatformLib.h>\r
-\r
 #include <IndustryStandard/Acpi.h>\r
 \r
 typedef struct {\r
@@ -73,5 +70,4 @@ RestorePciDecoding (
   IN UINTN               Count\r
   );\r
 \r
-#endif\r
-\r
+#endif /* _ACPI_PLATFORM_H_INCLUDED_ */\r
index eec5a42f41e3da4de4788111349f7cff11215cd1..595fd055f98a6d10d94f4bf5ac3838efd1047597 100644 (file)
@@ -8,7 +8,7 @@
 ##\r
 \r
 [Defines]\r
-  INF_VERSION                    = 0x00010005\r
+  INF_VERSION                    = 1.29\r
   BASE_NAME                      = AcpiPlatform\r
   FILE_GUID                      = D5F92408-BAB5-44CA-8A60-C212F01D7E9D\r
   MODULE_TYPE                    = DXE_DRIVER\r
@@ -24,9 +24,9 @@
 [Sources]\r
   AcpiPlatform.c\r
   AcpiPlatform.h\r
+  Bhyve.c\r
   EntryPoint.c\r
   PciDecoding.c\r
-  Bhyve.c\r
 \r
 [Packages]\r
   MdePkg/MdePkg.dec\r
   UefiCpuPkg/UefiCpuPkg.dec\r
 \r
 [LibraryClasses]\r
-  UefiLib\r
-  PcdLib\r
+  BaseLib\r
   BaseMemoryLib\r
-  DebugLib\r
-  UefiBootServicesTableLib\r
-  UefiDriverEntryPoint\r
   BhyveFwCtlLib\r
-  MemoryAllocationLib\r
-  BaseLib\r
+  DebugLib\r
   DxeServicesTableLib\r
+  MemoryAllocationLib\r
   OrderedCollectionLib\r
+  PcdLib\r
+  UefiBootServicesTableLib\r
+  UefiDriverEntryPoint\r
+  UefiLib\r
 \r
 [Protocols]\r
   gEfiAcpiTableProtocolGuid                     # PROTOCOL ALWAYS_CONSUMED\r
index 6d42264b654ac92ca09a5d0219fe0732f28c6c7d..01ee89474667983928f94b57892edda88d0eccc3 100644 (file)
@@ -9,8 +9,8 @@
 #include "AcpiPlatform.h"\r
 \r
 #include <Library/BaseMemoryLib.h>\r
-#include <Library/MemoryAllocationLib.h>\r
 #include <Library/BhyveFwCtlLib.h>\r
+#include <Library/MemoryAllocationLib.h>\r
 \r
 STATIC\r
 EFI_STATUS\r
index 3aab42419ca72163262062f8031e74bbecc3decb..f422793f49383df6b48994aea6ec9387791d3b44 100644 (file)
@@ -12,7 +12,7 @@
 ##\r
 \r
 [Defines]\r
-  INF_VERSION                    = 0x00010005\r
+  INF_VERSION                    = 1.29\r
   BASE_NAME                      = PlatformAcpiTables\r
   FILE_GUID                      = B4BA6241-936C-4485-A483-9FA832C758CA\r
   MODULE_TYPE                    = USER_DEFINED\r
 #\r
 \r
 [Sources]\r
-  Platform.h\r
-  Madt.aslc\r
+  Dsdt.asl\r
   Facp.aslc\r
   Facs.aslc\r
-  Dsdt.asl\r
   Hpet.aslc\r
-  Spcr.aslc\r
+  Madt.aslc\r
   Mcfg.aslc\r
+  Platform.h\r
+  Spcr.aslc\r
 \r
 [Packages]\r
   MdePkg/MdePkg.dec\r
index fc43ab41148602e571c2211ff73766bcb723c7c2..c6d43041f36d6db45b38df34d6d7bb7fdd58d8e7 100644 (file)
@@ -14,8 +14,8 @@
 #define _Platform_h_INCLUDED_\r
 \r
 #include <IndustryStandard/Acpi.h>\r
-#include <IndustryStandard/SerialPortConsoleRedirectionTable.h>\r
 #include <IndustryStandard/MemoryMappedConfigurationSpaceAccessTable.h>\r
+#include <IndustryStandard/SerialPortConsoleRedirectionTable.h>\r
 \r
 //\r
 // ACPI table information used to initialize tables.\r
index 5d6e41f0575af03813e35c95ab7cab9c1099fb37..d4016605f3438ec400b8c52c91e8544e8df00c71 100644 (file)
@@ -10,7 +10,7 @@
 ##\r
 \r
 [Defines]\r
-  INF_VERSION                    = 0x00010005\r
+  INF_VERSION                    = 1.29\r
   BASE_NAME                      = EmuGopDxe\r
   FILE_GUID                      = 1b290126-5760-424e-8aa2-3faf4d0d7978\r
   MODULE_TYPE                    = UEFI_DRIVER\r
 \r
 [Sources]\r
   ComponentName.c\r
-  GopScreen.c\r
-  GopDriver.c\r
   Gop.h\r
+  GopDriver.c\r
+  GopScreen.c\r
   VbeShim.c\r
 \r
-\r
 [Packages]\r
   MdePkg/MdePkg.dec\r
   OvmfPkg/OvmfPkg.dec\r
@@ -55,7 +54,6 @@
   UefiBootServicesTableLib\r
   UefiDriverEntryPoint\r
 \r
-\r
 [Protocols]\r
   gEfiGraphicsOutputProtocolGuid   # PROTOCOL BY_START\r
   gEfiDevicePathProtocolGuid       # PROTOCOL TO_START\r
index d196a8e6cf93214b7f0d50c5351c517ed9a8deaf..13cf3976266c75e879a497f9fd75b5e6ddaa3b64 100644 (file)
@@ -8,8 +8,8 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
 \r
 **/\r
 \r
-#ifndef __UGA_H_\r
-#define __UGA_H_\r
+#ifndef _GOP_H_\r
+#define _GOP_H_\r
 \r
 #include <Uefi.h>\r
 #include <Protocol/GraphicsOutput.h>\r
@@ -146,4 +146,4 @@ InstallVbeShim (
   IN EFI_PHYSICAL_ADDRESS FrameBufferBase\r
   );\r
 \r
-#endif\r
+#endif /* _GOP_H_ */\r
index c9813097ca32d97654f3c01d8c474f85649019b5..b93fe30ae4e057267fc6620eb9d1e1ad544487c3 100644 (file)
@@ -17,7 +17,7 @@
   PLATFORM_NAME                  = Bhyve\r
   PLATFORM_GUID                  = 562b76ee-ceb2-4f4f-adfe-a4c8dc46e4ff\r
   PLATFORM_VERSION               = 0.1\r
-  DSC_SPECIFICATION              = 0x00010005\r
+  DSC_SPECIFICATION              = 1.30\r
   OUTPUT_DIRECTORY               = Build/BhyveX64\r
   SUPPORTED_ARCHITECTURES        = X64\r
   BUILD_TARGETS                  = NOOPT|DEBUG|RELEASE\r
index 3cd98799a3af6993617d6d75a049e7ed02295b1a..ef7901fbeaa89c8136745ba7676a6debe950d8de 100644 (file)
@@ -6,8 +6,8 @@
 \r
 **/\r
 \r
-#ifndef __CMOS_H__\r
-#define __CMOS_H__\r
+#ifndef _CMOS_H_\r
+#define _CMOS_H_\r
 \r
 /**\r
   Reads 8-bits of CMOS data.\r
@@ -46,5 +46,5 @@ CmosWrite8 (
   );\r
 \r
 \r
-#endif\r
+#endif /* _CMOS_H_ */\r
 \r
index ee4ecab615f9a4506fc4a50ad992c726027edfb6..94b7e2141562fd4c302b97f641cf29c2b3e32461 100644 (file)
@@ -10,8 +10,8 @@
 #include "Platform.h"\r
 #include <Library/DebugLib.h>\r
 #include <Library/HobLib.h>\r
-#include <Library/PeiServicesLib.h>\r
 #include <Library/PcdLib.h>\r
+#include <Library/PeiServicesLib.h>\r
 \r
 \r
 /**\r
index 9f1900626d6bda07202e0cdc0620c4213925f273..3a414ffcb7382927ff428e5635dc0917a5f0d11e 100644 (file)
 #include <Library/DebugLib.h>\r
 #include <Library/HobLib.h>\r
 #include <Library/IoLib.h>\r
+#include <Library/LocalApicLib.h>\r
 #include <Library/MemoryAllocationLib.h>\r
 #include <Library/PcdLib.h>\r
 #include <Library/PciLib.h>\r
 #include <Library/PeimEntryPoint.h>\r
 #include <Library/PeiServicesLib.h>\r
 #include <Library/ResourcePublicationLib.h>\r
-#include <Library/LocalApicLib.h>\r
 #include <Guid/MemoryTypeInformation.h>\r
 #include <Ppi/MasterBootMode.h>\r
 #include <IndustryStandard/Pci22.h>\r
index 7288cff4c8a33acaae4df06c0df149fd15277370..12203e9f804db676b4ec589bf8161dd139508b85 100644 (file)
@@ -11,7 +11,7 @@
 ##\r
 \r
 [Defines]\r
-  INF_VERSION                    = 0x00010005\r
+  INF_VERSION                    = 1.29\r
   BASE_NAME                      = PlatformPei\r
   FILE_GUID                      = aa89d903-345b-4ab2-9abf-030b5efb5d50\r
   MODULE_TYPE                    = PEIM\r
   DebugLib\r
   HobLib\r
   IoLib\r
+  LocalApicLib\r
+  MemEncryptSevLib\r
+  MtrrLib\r
   PciLib\r
-  ResourcePublicationLib\r
+  PeimEntryPoint\r
   PeiServicesLib\r
   PeiServicesTablePointerLib\r
-  PeimEntryPoint\r
-  MtrrLib\r
-  MemEncryptSevLib\r
   PcdLib\r
-  LocalApicLib\r
+  ResourcePublicationLib\r
 \r
 [Pcd]\r
   gUefiOvmfPkgTokenSpaceGuid.PcdOvmfPeiMemFvBase\r
index 1971827be462023e67bf8b6557b46d27a2e2dcd8..12d7be7b2411faa67afe73809c9f74fe73808fea 100644 (file)
 #define _SMBIOS_PLATFORM_DXE_H_\r
 \r
 #include <PiDxe.h>\r
-\r
 #include <Protocol/Smbios.h>\r
 #include <IndustryStandard/SmBios.h>\r
-#include <Library/DebugLib.h>\r
 #include <Library/BaseLib.h>\r
 #include <Library/BaseMemoryLib.h>\r
-#include <Library/UefiBootServicesTableLib.h>\r
+#include <Library/DebugLib.h>\r
 #include <Library/MemoryAllocationLib.h>\r
+#include <Library/UefiBootServicesTableLib.h>\r
 \r
 \r
 /**\r
@@ -49,4 +48,4 @@ IsEntryPointStructureValid (
   IN SMBIOS_TABLE_ENTRY_POINT  *EntryPointStructure\r
   );\r
 \r
-#endif\r
+#endif /* _SMBIOS_PLATFORM_DXE_H_ */\r
index a4cc6e7a565c4d066dd3e01fad62678ec54fd79b..12deae7825e6274742341004d0c67a787e4372b5 100644 (file)
@@ -10,7 +10,7 @@
 ##\r
 \r
 [Defines]\r
-  INF_VERSION                    = 0x00010005\r
+  INF_VERSION                    = 1.29\r
   BASE_NAME                      = SmbiosPlatformDxe\r
   FILE_GUID                      = e2d8a63c-c239-484f-bb21-2917843cc382\r
   MODULE_TYPE                    = DXE_DRIVER\r
@@ -25,9 +25,9 @@
 #\r
 \r
 [Sources]\r
+  Bhyve.c\r
   SmbiosPlatformDxe.h\r
   SmbiosPlatformDxe.c\r
-  Bhyve.c\r
 \r
 [Packages]\r
   MdePkg/MdePkg.dec\r
   OvmfPkg/OvmfPkg.dec\r
 \r
 [LibraryClasses]\r
-  UefiBootServicesTableLib\r
-  BaseMemoryLib\r
   BaseLib\r
-  UefiDriverEntryPoint\r
+  BaseMemoryLib\r
   DebugLib\r
   HobLib\r
   MemoryAllocationLib\r
   PcdLib\r
+  UefiBootServicesTableLib\r
+  UefiDriverEntryPoint\r
 \r
 [Pcd]\r
   gUefiOvmfPkgTokenSpaceGuid.PcdQemuSmbiosValidated\r