OvmfPkg: Apply uncrustify changes

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

Apply uncrustify changes to .c/.h files in the OvmfPkg 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: Andrew Fish <afish@apple.com>
This commit is contained in:
Michael Kubacki
2021-12-05 14:54:09 -08:00
committed by mergify[bot]
parent d1050b9dff
commit ac0a286f4d
445 changed files with 30894 additions and 26369 deletions

View File

@@ -84,7 +84,7 @@
* of the structure must check that memmap_entries is non-zero
* before trying to read the memory map.
*/
#define XEN_HVM_START_MAGIC_VALUE 0x336ec578
#define XEN_HVM_START_MAGIC_VALUE 0x336ec578
/*
* The values used in the type field of the memory map table entries are
@@ -107,37 +107,37 @@
* represent the layout described there using C types.
*/
struct hvm_start_info {
UINT32 magic; /* Contains the magic value 0x336ec578 */
UINT32 magic; /* Contains the magic value 0x336ec578 */
/* ("xEn3" with the 0x80 bit of the "E" set).*/
UINT32 version; /* Version of this structure. */
UINT32 flags; /* SIF_xxx flags. */
UINT32 nr_modules; /* Number of modules passed to the kernel. */
UINT64 modlist_paddr; /* Physical address of an array of */
UINT32 version; /* Version of this structure. */
UINT32 flags; /* SIF_xxx flags. */
UINT32 nr_modules; /* Number of modules passed to the kernel. */
UINT64 modlist_paddr; /* Physical address of an array of */
/* hvm_modlist_entry. */
UINT64 cmdline_paddr; /* Physical address of the command line. */
UINT64 rsdp_paddr; /* Physical address of the RSDP ACPI data */
UINT64 cmdline_paddr; /* Physical address of the command line. */
UINT64 rsdp_paddr; /* Physical address of the RSDP ACPI data */
/* structure. */
/* All following fields only present in version 1 and newer */
UINT64 memmap_paddr; /* Physical address of an array of */
/* All following fields only present in version 1 and newer */
UINT64 memmap_paddr; /* Physical address of an array of */
/* hvm_memmap_table_entry. */
UINT32 memmap_entries; /* Number of entries in the memmap table. */
UINT32 memmap_entries; /* Number of entries in the memmap table. */
/* Value will be zero if there is no memory */
/* map being provided. */
UINT32 reserved; /* Must be zero. */
UINT32 reserved; /* Must be zero. */
};
struct hvm_modlist_entry {
UINT64 paddr; /* Physical address of the module. */
UINT64 size; /* Size of the module in bytes. */
UINT64 cmdline_paddr; /* Physical address of the command line. */
UINT64 reserved;
UINT64 paddr; /* Physical address of the module. */
UINT64 size; /* Size of the module in bytes. */
UINT64 cmdline_paddr; /* Physical address of the command line. */
UINT64 reserved;
};
struct hvm_memmap_table_entry {
UINT64 addr; /* Base address of the memory region */
UINT64 size; /* Size of the memory region in bytes */
UINT32 type; /* Mapping type */
UINT32 reserved; /* Must be zero for Version 1. */
UINT64 addr; /* Base address of the memory region */
UINT64 size; /* Size of the memory region in bytes */
UINT32 type; /* Mapping type */
UINT32 reserved; /* Must be zero for Version 1. */
};
#endif /* __XEN_PUBLIC_ARCH_X86_HVM_START_INFO_H__ */

View File

@@ -23,9 +23,10 @@
#ifndef __ASSEMBLY__
struct arch_vcpu_info {
UINTN cr2;
UINTN pad[5]; /* sizeof(vcpu_info_t) == 64 */
UINTN cr2;
UINTN pad[5]; /* sizeof(vcpu_info_t) == 64 */
};
typedef struct arch_vcpu_info arch_vcpu_info_t;
#endif /* !__ASSEMBLY__ */

View File

@@ -23,9 +23,10 @@
#ifndef __ASSEMBLY__
struct arch_vcpu_info {
UINTN cr2;
UINTN pad; /* sizeof(vcpu_info_t) == 64 */
UINTN cr2;
UINTN pad; /* sizeof(vcpu_info_t) == 64 */
};
typedef struct arch_vcpu_info arch_vcpu_info_t;
#endif /* !__ASSEMBLY__ */

View File

@@ -14,13 +14,13 @@
#define __XEN_PUBLIC_ARCH_X86_XEN_H__
/* Structural guest handles introduced in 0x00030201. */
#if __XEN_INTERFACE_VERSION__ >= 0x00030201
#if __XEN_INTERFACE_VERSION__ >= 0x00030201
#define ___DEFINE_XEN_GUEST_HANDLE(name, type) \
typedef struct { type *p; } __guest_handle_ ## name
#else
#else
#define ___DEFINE_XEN_GUEST_HANDLE(name, type) \
typedef type * __guest_handle_ ## name
#endif
#endif
/*
* XEN_GUEST_HANDLE represents a guest pointer, when passed as a field
@@ -33,55 +33,56 @@
#define __DEFINE_XEN_GUEST_HANDLE(name, type) \
___DEFINE_XEN_GUEST_HANDLE(name, type); \
___DEFINE_XEN_GUEST_HANDLE(const_##name, const type)
#define DEFINE_XEN_GUEST_HANDLE(name) __DEFINE_XEN_GUEST_HANDLE(name, name)
#define __XEN_GUEST_HANDLE(name) __guest_handle_ ## name
#define XEN_GUEST_HANDLE(name) __XEN_GUEST_HANDLE(name)
#define XEN_GUEST_HANDLE_PARAM(name) XEN_GUEST_HANDLE(name)
#define DEFINE_XEN_GUEST_HANDLE(name) __DEFINE_XEN_GUEST_HANDLE(name, name)
#define __XEN_GUEST_HANDLE(name) __guest_handle_ ## name
#define XEN_GUEST_HANDLE(name) __XEN_GUEST_HANDLE(name)
#define XEN_GUEST_HANDLE_PARAM(name) XEN_GUEST_HANDLE(name)
#define set_xen_guest_handle_raw(hnd, val) do { (hnd).p = val; } while (0)
#ifdef __XEN_TOOLS__
#ifdef __XEN_TOOLS__
#define get_xen_guest_handle(val, hnd) do { val = (hnd).p; } while (0)
#endif
#define set_xen_guest_handle(hnd, val) set_xen_guest_handle_raw(hnd, val)
#endif
#define set_xen_guest_handle(hnd, val) set_xen_guest_handle_raw(hnd, val)
#if defined(MDE_CPU_IA32)
#include "xen-x86_32.h"
#elif defined(MDE_CPU_X64)
#include "xen-x86_64.h"
#endif
#if defined (MDE_CPU_IA32)
#include "xen-x86_32.h"
#elif defined (MDE_CPU_X64)
#include "xen-x86_64.h"
#endif
#ifndef __ASSEMBLY__
#ifndef __ASSEMBLY__
typedef UINTN xen_pfn_t;
#define PRI_xen_pfn "lx"
#endif
#define PRI_xen_pfn "lx"
#endif
#define XEN_HAVE_PV_UPCALL_MASK 1
#define XEN_HAVE_PV_UPCALL_MASK 1
/* Maximum number of virtual CPUs in legacy multi-processor guests. */
#define XEN_LEGACY_MAX_VCPUS 32
#define XEN_LEGACY_MAX_VCPUS 32
#ifndef __ASSEMBLY__
#ifndef __ASSEMBLY__
typedef UINTN xen_ulong_t;
#define PRI_xen_ulong "lx"
#define PRI_xen_ulong "lx"
typedef UINT64 tsc_timestamp_t; /* RDTSC timestamp */
#ifdef MDE_CPU_IA32
#pragma pack(4)
#endif
#ifdef MDE_CPU_IA32
#pragma pack(4)
#endif
struct arch_shared_info {
UINTN max_pfn; /* max pfn that appears in table */
/* Frame containing list of mfns containing list of mfns containing p2m. */
xen_pfn_t pfn_to_mfn_frame_list_list;
UINTN nmi_reason;
UINT64 pad[32];
UINTN max_pfn; /* max pfn that appears in table */
/* Frame containing list of mfns containing list of mfns containing p2m. */
xen_pfn_t pfn_to_mfn_frame_list_list;
UINTN nmi_reason;
UINT64 pad[32];
};
typedef struct arch_shared_info arch_shared_info_t;
#ifdef MDE_CPU_IA32
#pragma pack()
#endif
#endif /* !__ASSEMBLY__ */
typedef struct arch_shared_info arch_shared_info_t;
#ifdef MDE_CPU_IA32
#pragma pack()
#endif
#endif /* !__ASSEMBLY__ */
#endif /* __XEN_PUBLIC_ARCH_X86_XEN_H__ */