MdeModulePkg: Apply uncrustify changes

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3737

Apply uncrustify changes to .c/.h files in the MdeModulePkg package

Cc: Andrew Fish <afish@apple.com>
Cc: Leif Lindholm <leif@nuviainc.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Signed-off-by: Michael Kubacki <michael.kubacki@microsoft.com>
Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn>
This commit is contained in:
Michael Kubacki
2021-12-05 14:54:02 -08:00
committed by mergify[bot]
parent 7c7184e201
commit 1436aea4d5
994 changed files with 107608 additions and 101311 deletions

View File

@@ -17,14 +17,14 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
#pragma pack(1)
typedef struct {
UNIVERSAL_PAYLOAD_GENERIC_HEADER Header;
EFI_PHYSICAL_ADDRESS Rsdp;
UNIVERSAL_PAYLOAD_GENERIC_HEADER Header;
EFI_PHYSICAL_ADDRESS Rsdp;
} UNIVERSAL_PAYLOAD_ACPI_TABLE;
#pragma pack()
#define UNIVERSAL_PAYLOAD_ACPI_TABLE_REVISION 1
#define UNIVERSAL_PAYLOAD_ACPI_TABLE_REVISION 1
extern GUID gUniversalPayloadAcpiTableGuid;
extern GUID gUniversalPayloadAcpiTableGuid;
#endif // UNIVERSAL_PAYLOAD_ACPI_TABLE_H_

View File

@@ -4,27 +4,28 @@
SPDX-License-Identifier: BSD-2-Clause-Patent
**/
#ifndef EXTRA_DATA_H_
#define EXTRA_DATA_H_
extern GUID gUniversalPayloadExtraDataGuid;
extern GUID gUniversalPayloadExtraDataGuid;
#pragma pack(1)
typedef struct {
CHAR8 Identifier[16];
EFI_PHYSICAL_ADDRESS Base;
UINT64 Size;
CHAR8 Identifier[16];
EFI_PHYSICAL_ADDRESS Base;
UINT64 Size;
} UNIVERSAL_PAYLOAD_EXTRA_DATA_ENTRY;
typedef struct {
UNIVERSAL_PAYLOAD_GENERIC_HEADER Header;
UINT32 Count;
UNIVERSAL_PAYLOAD_EXTRA_DATA_ENTRY Entry[0];
UNIVERSAL_PAYLOAD_GENERIC_HEADER Header;
UINT32 Count;
UNIVERSAL_PAYLOAD_EXTRA_DATA_ENTRY Entry[0];
} UNIVERSAL_PAYLOAD_EXTRA_DATA;
#pragma pack()
#define UNIVERSAL_PAYLOAD_EXTRA_DATA_REVISION 1
#define UNIVERSAL_PAYLOAD_EXTRA_DATA_REVISION 1
#endif

View File

@@ -23,8 +23,8 @@ typedef struct {
// Base and Limit are the device address instead of host address when
// Translation is not zero
//
UINT64 Base;
UINT64 Limit;
UINT64 Base;
UINT64 Limit;
//
// According to UEFI 2.7, Device Address = Host Address + Translation,
// so Translation = Device Address - Host Address.
@@ -39,53 +39,53 @@ typedef struct {
// situation and makes the current resource allocation code in generic PCI
// host bridge driver still work.
//
UINT64 Translation;
UINT64 Translation;
} UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGE_APERTURE;
///
/// Payload PCI Root Bridge Information HOB
///
typedef struct {
UINT32 Segment; ///< Segment number.
UINT64 Supports; ///< Supported attributes.
///< Refer to EFI_PCI_ATTRIBUTE_xxx used by GetAttributes()
///< and SetAttributes() in EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL.
UINT64 Attributes; ///< Initial attributes.
///< Refer to EFI_PCI_ATTRIBUTE_xxx used by GetAttributes()
///< and SetAttributes() in EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL.
BOOLEAN DmaAbove4G; ///< DMA above 4GB memory.
///< Set to TRUE when root bridge supports DMA above 4GB memory.
BOOLEAN NoExtendedConfigSpace; ///< When FALSE, the root bridge supports
///< Extended (4096-byte) Configuration Space.
///< When TRUE, the root bridge supports
///< 256-byte Configuration Space only.
UINT64 AllocationAttributes; ///< Allocation attributes.
///< Refer to EFI_PCI_HOST_BRIDGE_COMBINE_MEM_PMEM and
///< EFI_PCI_HOST_BRIDGE_MEM64_DECODE used by GetAllocAttributes()
///< in EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL.
UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGE_APERTURE Bus; ///< Bus aperture which can be used by the root bridge.
UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGE_APERTURE Io; ///< IO aperture which can be used by the root bridge.
UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGE_APERTURE Mem; ///< MMIO aperture below 4GB which can be used by the root bridge.
UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGE_APERTURE MemAbove4G; ///< MMIO aperture above 4GB which can be used by the root bridge.
UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGE_APERTURE PMem; ///< Prefetchable MMIO aperture below 4GB which can be used by the root bridge.
UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGE_APERTURE PMemAbove4G; ///< Prefetchable MMIO aperture above 4GB which can be used by the root bridge.
UINT32 HID; ///< PnP hardware ID of the root bridge. This value must match the corresponding
///< _HID in the ACPI name space.
UINT32 UID; ///< Unique ID that is required by ACPI if two devices have the same _HID.
///< This value must also match the corresponding _UID/_HID pair in the ACPI name space.
UINT32 Segment; ///< Segment number.
UINT64 Supports; ///< Supported attributes.
///< Refer to EFI_PCI_ATTRIBUTE_xxx used by GetAttributes()
///< and SetAttributes() in EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL.
UINT64 Attributes; ///< Initial attributes.
///< Refer to EFI_PCI_ATTRIBUTE_xxx used by GetAttributes()
///< and SetAttributes() in EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL.
BOOLEAN DmaAbove4G; ///< DMA above 4GB memory.
///< Set to TRUE when root bridge supports DMA above 4GB memory.
BOOLEAN NoExtendedConfigSpace; ///< When FALSE, the root bridge supports
///< Extended (4096-byte) Configuration Space.
///< When TRUE, the root bridge supports
///< 256-byte Configuration Space only.
UINT64 AllocationAttributes; ///< Allocation attributes.
///< Refer to EFI_PCI_HOST_BRIDGE_COMBINE_MEM_PMEM and
///< EFI_PCI_HOST_BRIDGE_MEM64_DECODE used by GetAllocAttributes()
///< in EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL.
UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGE_APERTURE Bus; ///< Bus aperture which can be used by the root bridge.
UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGE_APERTURE Io; ///< IO aperture which can be used by the root bridge.
UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGE_APERTURE Mem; ///< MMIO aperture below 4GB which can be used by the root bridge.
UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGE_APERTURE MemAbove4G; ///< MMIO aperture above 4GB which can be used by the root bridge.
UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGE_APERTURE PMem; ///< Prefetchable MMIO aperture below 4GB which can be used by the root bridge.
UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGE_APERTURE PMemAbove4G; ///< Prefetchable MMIO aperture above 4GB which can be used by the root bridge.
UINT32 HID; ///< PnP hardware ID of the root bridge. This value must match the corresponding
///< _HID in the ACPI name space.
UINT32 UID; ///< Unique ID that is required by ACPI if two devices have the same _HID.
///< This value must also match the corresponding _UID/_HID pair in the ACPI name space.
} UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGE;
typedef struct {
UNIVERSAL_PAYLOAD_GENERIC_HEADER Header;
BOOLEAN ResourceAssigned;
UINT8 Count;
UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGE RootBridge[0];
UNIVERSAL_PAYLOAD_GENERIC_HEADER Header;
BOOLEAN ResourceAssigned;
UINT8 Count;
UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGE RootBridge[0];
} UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGES;
#pragma pack()
#define UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGES_REVISION 1
#define UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGES_REVISION 1
extern GUID gUniversalPayloadPciRootBridgeInfoGuid;
extern GUID gUniversalPayloadPciRootBridgeInfoGuid;
#endif // UNIVERSAL_PAYLOAD_PCI_ROOT_BRIDGES_H_

View File

@@ -15,16 +15,16 @@
#pragma pack(1)
typedef struct {
UNIVERSAL_PAYLOAD_GENERIC_HEADER Header;
BOOLEAN UseMmio;
UINT8 RegisterStride;
UINT32 BaudRate;
EFI_PHYSICAL_ADDRESS RegisterBase;
UNIVERSAL_PAYLOAD_GENERIC_HEADER Header;
BOOLEAN UseMmio;
UINT8 RegisterStride;
UINT32 BaudRate;
EFI_PHYSICAL_ADDRESS RegisterBase;
} UNIVERSAL_PAYLOAD_SERIAL_PORT_INFO;
#pragma pack()
#define UNIVERSAL_PAYLOAD_SERIAL_PORT_INFO_REVISION 1
#define UNIVERSAL_PAYLOAD_SERIAL_PORT_INFO_REVISION 1
extern GUID gUniversalPayloadSerialPortInfoGuid;
extern GUID gUniversalPayloadSerialPortInfoGuid;
#endif // UNIVERSAL_PAYLOAD_SERIAL_PORT_INFO_H_

View File

@@ -17,14 +17,14 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
#pragma pack (1)
typedef struct {
UNIVERSAL_PAYLOAD_GENERIC_HEADER Header;
EFI_PHYSICAL_ADDRESS SmBiosEntryPoint;
UNIVERSAL_PAYLOAD_GENERIC_HEADER Header;
EFI_PHYSICAL_ADDRESS SmBiosEntryPoint;
} UNIVERSAL_PAYLOAD_SMBIOS_TABLE;
#pragma pack()
#define UNIVERSAL_PAYLOAD_SMBIOS_TABLE_REVISION 1
#define UNIVERSAL_PAYLOAD_SMBIOS_TABLE_REVISION 1
extern GUID gUniversalPayloadSmbios3TableGuid;
extern GUID gUniversalPayloadSmbiosTableGuid;
extern GUID gUniversalPayloadSmbios3TableGuid;
extern GUID gUniversalPayloadSmbiosTableGuid;
#endif // UNIVERSAL_PAYLOAD_SMBIOS_TABLE_H_

View File

@@ -16,31 +16,31 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
@param HobList Pointer to the beginning of the HOB List from boot loader.
**/
typedef VOID (EFIAPI *UNIVERSAL_PAYLOAD_ENTRY) (VOID *HobList);
typedef VOID (EFIAPI *UNIVERSAL_PAYLOAD_ENTRY)(VOID *HobList);
#define UNIVERSAL_PAYLOAD_IDENTIFIER SIGNATURE_32('U', 'P', 'L', 'D')
#define UNIVERSAL_PAYLOAD_INFO_SEC_NAME ".upld_info"
#define UNIVERSAL_PAYLOAD_EXTRA_SEC_NAME_PREFIX ".upld."
#define UNIVERSAL_PAYLOAD_EXTRA_SEC_NAME_PREFIX_LENGTH (sizeof (UNIVERSAL_PAYLOAD_EXTRA_SEC_NAME_PREFIX) - 1)
#define UNIVERSAL_PAYLOAD_IDENTIFIER SIGNATURE_32('U', 'P', 'L', 'D')
#define UNIVERSAL_PAYLOAD_INFO_SEC_NAME ".upld_info"
#define UNIVERSAL_PAYLOAD_EXTRA_SEC_NAME_PREFIX ".upld."
#define UNIVERSAL_PAYLOAD_EXTRA_SEC_NAME_PREFIX_LENGTH (sizeof (UNIVERSAL_PAYLOAD_EXTRA_SEC_NAME_PREFIX) - 1)
#pragma pack(1)
typedef struct {
UINT32 Identifier;
UINT32 HeaderLength;
UINT16 SpecRevision;
UINT8 Reserved[2];
UINT32 Revision;
UINT32 Attribute;
UINT32 Capability;
CHAR8 ProducerId[16];
CHAR8 ImageId[16];
UINT32 Identifier;
UINT32 HeaderLength;
UINT16 SpecRevision;
UINT8 Reserved[2];
UINT32 Revision;
UINT32 Attribute;
UINT32 Capability;
CHAR8 ProducerId[16];
CHAR8 ImageId[16];
} UNIVERSAL_PAYLOAD_INFO_HEADER;
typedef struct {
UINT8 Revision;
UINT8 Reserved;
UINT16 Length;
UINT8 Revision;
UINT8 Reserved;
UINT16 Length;
} UNIVERSAL_PAYLOAD_GENERIC_HEADER;
#pragma pack()
@@ -54,6 +54,6 @@ typedef struct {
@return size, in bytes.
**/
#define UNIVERSAL_PAYLOAD_SIZEOF_THROUGH_FIELD(TYPE, Field) (OFFSET_OF(TYPE, Field) + sizeof (((TYPE *) 0)->Field))
#define UNIVERSAL_PAYLOAD_SIZEOF_THROUGH_FIELD(TYPE, Field) (OFFSET_OF(TYPE, Field) + sizeof (((TYPE *) 0)->Field))
#endif // UNIVERSAL_PAYLOAD_H_