DynamicTablesPkg: Apply uncrustify changes
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3737 Apply uncrustify changes to .c/.h files in the DynamicTablesPkg 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: Sami Mujawar <sami.mujawar@arm.com>
This commit is contained in:
committed by
mergify[bot]
parent
7c34237831
commit
731c67e1d7
@@ -45,22 +45,22 @@ NOTE: This implementation ignores the possibility that the Serial settings may
|
||||
|
||||
/** A string representing the name of the SPCR port.
|
||||
*/
|
||||
#define NAME_STR_SPCR_PORT "COM1"
|
||||
#define NAME_STR_SPCR_PORT "COM1"
|
||||
|
||||
/** An UID representing the SPCR port.
|
||||
*/
|
||||
#define UID_SPCR_PORT 1
|
||||
#define UID_SPCR_PORT 1
|
||||
|
||||
/** This macro defines the no flow control option.
|
||||
*/
|
||||
#define SPCR_FLOW_CONTROL_NONE 0
|
||||
#define SPCR_FLOW_CONTROL_NONE 0
|
||||
|
||||
/**A template for generating the SPCR Table.
|
||||
|
||||
Note: fields marked "{Template}" will be updated dynamically.
|
||||
*/
|
||||
STATIC
|
||||
EFI_ACPI_SERIAL_PORT_CONSOLE_REDIRECTION_TABLE AcpiSpcr = {
|
||||
EFI_ACPI_SERIAL_PORT_CONSOLE_REDIRECTION_TABLE AcpiSpcr = {
|
||||
ACPI_HEADER (
|
||||
EFI_ACPI_6_2_SERIAL_PORT_CONSOLE_REDIRECTION_TABLE_SIGNATURE,
|
||||
EFI_ACPI_SERIAL_PORT_CONSOLE_REDIRECTION_TABLE,
|
||||
@@ -120,15 +120,15 @@ STATIC
|
||||
EFI_STATUS
|
||||
EFIAPI
|
||||
FreeSpcrTableEx (
|
||||
IN CONST ACPI_TABLE_GENERATOR * CONST This,
|
||||
IN CONST CM_STD_OBJ_ACPI_TABLE_INFO * CONST AcpiTableInfo,
|
||||
IN CONST EDKII_CONFIGURATION_MANAGER_PROTOCOL * CONST CfgMgrProtocol,
|
||||
IN OUT EFI_ACPI_DESCRIPTION_HEADER *** CONST Table,
|
||||
IN CONST ACPI_TABLE_GENERATOR *CONST This,
|
||||
IN CONST CM_STD_OBJ_ACPI_TABLE_INFO *CONST AcpiTableInfo,
|
||||
IN CONST EDKII_CONFIGURATION_MANAGER_PROTOCOL *CONST CfgMgrProtocol,
|
||||
IN OUT EFI_ACPI_DESCRIPTION_HEADER ***CONST Table,
|
||||
IN CONST UINTN TableCount
|
||||
)
|
||||
{
|
||||
EFI_STATUS Status;
|
||||
EFI_ACPI_DESCRIPTION_HEADER ** TableList;
|
||||
EFI_STATUS Status;
|
||||
EFI_ACPI_DESCRIPTION_HEADER **TableList;
|
||||
|
||||
ASSERT (This != NULL);
|
||||
ASSERT (AcpiTableInfo != NULL);
|
||||
@@ -138,7 +138,8 @@ FreeSpcrTableEx (
|
||||
|
||||
if ((Table == NULL) ||
|
||||
(*Table == NULL) ||
|
||||
(TableCount != 2)) {
|
||||
(TableCount != 2))
|
||||
{
|
||||
DEBUG ((DEBUG_ERROR, "ERROR: SPCR: Invalid Table Pointer\n"));
|
||||
return EFI_INVALID_PARAMETER;
|
||||
}
|
||||
@@ -147,7 +148,8 @@ FreeSpcrTableEx (
|
||||
|
||||
if ((TableList[1] == NULL) ||
|
||||
(TableList[1]->Signature !=
|
||||
EFI_ACPI_6_3_SECONDARY_SYSTEM_DESCRIPTION_TABLE_SIGNATURE)) {
|
||||
EFI_ACPI_6_3_SECONDARY_SYSTEM_DESCRIPTION_TABLE_SIGNATURE))
|
||||
{
|
||||
DEBUG ((DEBUG_ERROR, "ERROR: SPCR: Invalid SSDT table pointer.\n"));
|
||||
return EFI_INVALID_PARAMETER;
|
||||
}
|
||||
@@ -191,17 +193,17 @@ STATIC
|
||||
EFI_STATUS
|
||||
EFIAPI
|
||||
BuildSpcrTableEx (
|
||||
IN CONST ACPI_TABLE_GENERATOR * This,
|
||||
IN CONST CM_STD_OBJ_ACPI_TABLE_INFO * CONST AcpiTableInfo,
|
||||
IN CONST EDKII_CONFIGURATION_MANAGER_PROTOCOL * CONST CfgMgrProtocol,
|
||||
OUT EFI_ACPI_DESCRIPTION_HEADER *** Table,
|
||||
OUT UINTN * CONST TableCount
|
||||
IN CONST ACPI_TABLE_GENERATOR *This,
|
||||
IN CONST CM_STD_OBJ_ACPI_TABLE_INFO *CONST AcpiTableInfo,
|
||||
IN CONST EDKII_CONFIGURATION_MANAGER_PROTOCOL *CONST CfgMgrProtocol,
|
||||
OUT EFI_ACPI_DESCRIPTION_HEADER ***Table,
|
||||
OUT UINTN *CONST TableCount
|
||||
)
|
||||
{
|
||||
EFI_STATUS Status;
|
||||
CM_ARM_SERIAL_PORT_INFO * SerialPortInfo;
|
||||
UINT32 SerialPortCount;
|
||||
EFI_ACPI_DESCRIPTION_HEADER ** TableList;
|
||||
EFI_STATUS Status;
|
||||
CM_ARM_SERIAL_PORT_INFO *SerialPortInfo;
|
||||
UINT32 SerialPortCount;
|
||||
EFI_ACPI_DESCRIPTION_HEADER **TableList;
|
||||
|
||||
ASSERT (This != NULL);
|
||||
ASSERT (AcpiTableInfo != NULL);
|
||||
@@ -212,7 +214,8 @@ BuildSpcrTableEx (
|
||||
ASSERT (AcpiTableInfo->AcpiTableSignature == This->AcpiTableSignature);
|
||||
|
||||
if ((AcpiTableInfo->AcpiTableRevision < This->MinAcpiTableRevision) ||
|
||||
(AcpiTableInfo->AcpiTableRevision > This->AcpiTableRevision)) {
|
||||
(AcpiTableInfo->AcpiTableRevision > This->AcpiTableRevision))
|
||||
{
|
||||
DEBUG ((
|
||||
DEBUG_ERROR,
|
||||
"ERROR: SPCR: Requested table revision = %d, is not supported."
|
||||
@@ -264,8 +267,8 @@ BuildSpcrTableEx (
|
||||
}
|
||||
|
||||
// Allocate a table to store pointers to the SPCR and SSDT tables.
|
||||
TableList = (EFI_ACPI_DESCRIPTION_HEADER**)
|
||||
AllocateZeroPool (sizeof (EFI_ACPI_DESCRIPTION_HEADER*) * 2);
|
||||
TableList = (EFI_ACPI_DESCRIPTION_HEADER **)
|
||||
AllocateZeroPool (sizeof (EFI_ACPI_DESCRIPTION_HEADER *) * 2);
|
||||
if (TableList == NULL) {
|
||||
Status = EFI_OUT_OF_RESOURCES;
|
||||
DEBUG ((
|
||||
@@ -281,7 +284,7 @@ BuildSpcrTableEx (
|
||||
Status = AddAcpiHeader (
|
||||
CfgMgrProtocol,
|
||||
This,
|
||||
(EFI_ACPI_DESCRIPTION_HEADER*)&AcpiSpcr,
|
||||
(EFI_ACPI_DESCRIPTION_HEADER *)&AcpiSpcr,
|
||||
AcpiTableInfo,
|
||||
sizeof (EFI_ACPI_SERIAL_PORT_CONSOLE_REDIRECTION_TABLE)
|
||||
);
|
||||
@@ -364,7 +367,7 @@ BuildSpcrTableEx (
|
||||
goto error_handler;
|
||||
} // switch
|
||||
|
||||
TableList[0] = (EFI_ACPI_DESCRIPTION_HEADER*)&AcpiSpcr;
|
||||
TableList[0] = (EFI_ACPI_DESCRIPTION_HEADER *)&AcpiSpcr;
|
||||
|
||||
// Build a SSDT table describing the serial port.
|
||||
Status = BuildSsdtSerialPortTable (
|
||||
@@ -384,7 +387,7 @@ BuildSpcrTableEx (
|
||||
}
|
||||
|
||||
*TableCount = 2;
|
||||
*Table = TableList;
|
||||
*Table = TableList;
|
||||
|
||||
return Status;
|
||||
|
||||
@@ -398,13 +401,13 @@ error_handler:
|
||||
|
||||
/** This macro defines the SPCR Table Generator revision.
|
||||
*/
|
||||
#define SPCR_GENERATOR_REVISION CREATE_REVISION (1, 0)
|
||||
#define SPCR_GENERATOR_REVISION CREATE_REVISION (1, 0)
|
||||
|
||||
/** The interface for the SPCR Table Generator.
|
||||
*/
|
||||
STATIC
|
||||
CONST
|
||||
ACPI_TABLE_GENERATOR SpcrGenerator = {
|
||||
ACPI_TABLE_GENERATOR SpcrGenerator = {
|
||||
// Generator ID
|
||||
CREATE_STD_ACPI_TABLE_GEN_ID (EStdAcpiTableIdSpcr),
|
||||
// Generator Description
|
||||
@@ -442,11 +445,12 @@ ACPI_TABLE_GENERATOR SpcrGenerator = {
|
||||
EFI_STATUS
|
||||
EFIAPI
|
||||
AcpiSpcrLibConstructor (
|
||||
IN EFI_HANDLE ImageHandle,
|
||||
IN EFI_SYSTEM_TABLE * SystemTable
|
||||
IN EFI_HANDLE ImageHandle,
|
||||
IN EFI_SYSTEM_TABLE *SystemTable
|
||||
)
|
||||
{
|
||||
EFI_STATUS Status;
|
||||
|
||||
Status = RegisterAcpiTableGenerator (&SpcrGenerator);
|
||||
DEBUG ((DEBUG_INFO, "SPCR: Register Generator. Status = %r\n", Status));
|
||||
ASSERT_EFI_ERROR (Status);
|
||||
@@ -465,11 +469,12 @@ AcpiSpcrLibConstructor (
|
||||
EFI_STATUS
|
||||
EFIAPI
|
||||
AcpiSpcrLibDestructor (
|
||||
IN EFI_HANDLE ImageHandle,
|
||||
IN EFI_SYSTEM_TABLE * SystemTable
|
||||
IN EFI_HANDLE ImageHandle,
|
||||
IN EFI_SYSTEM_TABLE *SystemTable
|
||||
)
|
||||
{
|
||||
EFI_STATUS Status;
|
||||
|
||||
Status = DeregisterAcpiTableGenerator (&SpcrGenerator);
|
||||
DEBUG ((DEBUG_INFO, "SPCR: Deregister Generator. Status = %r\n", Status));
|
||||
ASSERT_EFI_ERROR (Status);
|
||||
|
Reference in New Issue
Block a user