diff options
author | Michael Kubacki <michael.kubacki@microsoft.com> | 2021-12-05 14:53:57 -0800 |
---|---|---|
committer | mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> | 2021-12-07 17:24:28 +0000 |
commit | a550d468a6ca577d9e9c57a0eafcf2fc9fbb8c97 (patch) | |
tree | 16ea0a059e01bb8af07f41dcea5996424c309a95 /EmulatorPkg/Unix/Host/LinuxPacketFilter.c | |
parent | e7108d0e9655b1795c94ac372b0449f28dd907df (diff) | |
download | edk2-a550d468a6ca577d9e9c57a0eafcf2fc9fbb8c97.tar.gz edk2-a550d468a6ca577d9e9c57a0eafcf2fc9fbb8c97.tar.bz2 edk2-a550d468a6ca577d9e9c57a0eafcf2fc9fbb8c97.zip |
EmulatorPkg: Apply uncrustify changes
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3737
Apply uncrustify changes to .c/.h files in the EmulatorPkg 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: Ray Ni <ray.ni@intel.com>
Diffstat (limited to 'EmulatorPkg/Unix/Host/LinuxPacketFilter.c')
-rw-r--r-- | EmulatorPkg/Unix/Host/LinuxPacketFilter.c | 142 |
1 files changed, 67 insertions, 75 deletions
diff --git a/EmulatorPkg/Unix/Host/LinuxPacketFilter.c b/EmulatorPkg/Unix/Host/LinuxPacketFilter.c index 2b772ab884..87c3dd6be4 100644 --- a/EmulatorPkg/Unix/Host/LinuxPacketFilter.c +++ b/EmulatorPkg/Unix/Host/LinuxPacketFilter.c @@ -12,21 +12,18 @@ SPDX-License-Identifier: BSD-2-Clause-Patent **/
-
#include "Host.h"
#ifndef __APPLE__
-#define EMU_SNP_PRIVATE_SIGNATURE SIGNATURE_32('E', 'M', 's', 'n')
+#define EMU_SNP_PRIVATE_SIGNATURE SIGNATURE_32('E', 'M', 's', 'n')
typedef struct {
- UINTN Signature;
-
- EMU_IO_THUNK_PROTOCOL *Thunk;
-
+ UINTN Signature;
- EMU_SNP_PROTOCOL EmuSnp;
- EFI_SIMPLE_NETWORK_MODE *Mode;
+ EMU_IO_THUNK_PROTOCOL *Thunk;
+ EMU_SNP_PROTOCOL EmuSnp;
+ EFI_SIMPLE_NETWORK_MODE *Mode;
} EMU_SNP_PRIVATE;
#define EMU_SNP_PRIVATE_DATA_FROM_THIS(a) \
@@ -48,7 +45,7 @@ EmuSnpCreateMapping ( IN EFI_SIMPLE_NETWORK_MODE *Mode
)
{
- EMU_SNP_PRIVATE *Private;
+ EMU_SNP_PRIVATE *Private;
Private = EMU_SNP_PRIVATE_DATA_FROM_THIS (This);
@@ -74,7 +71,7 @@ EmuSnpStart ( IN EMU_SNP_PROTOCOL *This
)
{
- EMU_SNP_PRIVATE *Private;
+ EMU_SNP_PRIVATE *Private;
Private = EMU_SNP_PRIVATE_DATA_FROM_THIS (This);
@@ -98,7 +95,7 @@ EmuSnpStop ( IN EMU_SNP_PROTOCOL *This
)
{
- EMU_SNP_PRIVATE *Private;
+ EMU_SNP_PRIVATE *Private;
Private = EMU_SNP_PRIVATE_DATA_FROM_THIS (This);
@@ -133,12 +130,12 @@ EmuSnpStop ( **/
EFI_STATUS
EmuSnpInitialize (
- IN EMU_SNP_PROTOCOL *This,
- IN UINTN ExtraRxBufferSize OPTIONAL,
- IN UINTN ExtraTxBufferSize OPTIONAL
+ IN EMU_SNP_PROTOCOL *This,
+ IN UINTN ExtraRxBufferSize OPTIONAL,
+ IN UINTN ExtraTxBufferSize OPTIONAL
)
{
- EMU_SNP_PRIVATE *Private;
+ EMU_SNP_PRIVATE *Private;
Private = EMU_SNP_PRIVATE_DATA_FROM_THIS (This);
@@ -163,11 +160,11 @@ EmuSnpInitialize ( **/
EFI_STATUS
EmuSnpReset (
- IN EMU_SNP_PROTOCOL *This,
- IN BOOLEAN ExtendedVerification
+ IN EMU_SNP_PROTOCOL *This,
+ IN BOOLEAN ExtendedVerification
)
{
- EMU_SNP_PRIVATE *Private;
+ EMU_SNP_PRIVATE *Private;
Private = EMU_SNP_PRIVATE_DATA_FROM_THIS (This);
@@ -192,7 +189,7 @@ EmuSnpShutdown ( IN EMU_SNP_PROTOCOL *This
)
{
- EMU_SNP_PRIVATE *Private;
+ EMU_SNP_PRIVATE *Private;
Private = EMU_SNP_PRIVATE_DATA_FROM_THIS (This);
@@ -225,15 +222,15 @@ EmuSnpShutdown ( **/
EFI_STATUS
EmuSnpReceiveFilters (
- IN EMU_SNP_PROTOCOL *This,
- IN UINT32 Enable,
- IN UINT32 Disable,
- IN BOOLEAN ResetMCastFilter,
- IN UINTN MCastFilterCnt OPTIONAL,
- IN EFI_MAC_ADDRESS *MCastFilter OPTIONAL
+ IN EMU_SNP_PROTOCOL *This,
+ IN UINT32 Enable,
+ IN UINT32 Disable,
+ IN BOOLEAN ResetMCastFilter,
+ IN UINTN MCastFilterCnt OPTIONAL,
+ IN EFI_MAC_ADDRESS *MCastFilter OPTIONAL
)
{
- EMU_SNP_PRIVATE *Private;
+ EMU_SNP_PRIVATE *Private;
Private = EMU_SNP_PRIVATE_DATA_FROM_THIS (This);
@@ -257,12 +254,12 @@ EmuSnpReceiveFilters ( **/
EFI_STATUS
EmuSnpStationAddress (
- IN EMU_SNP_PROTOCOL *This,
- IN BOOLEAN Reset,
- IN EFI_MAC_ADDRESS *New OPTIONAL
+ IN EMU_SNP_PROTOCOL *This,
+ IN BOOLEAN Reset,
+ IN EFI_MAC_ADDRESS *New OPTIONAL
)
{
- EMU_SNP_PRIVATE *Private;
+ EMU_SNP_PRIVATE *Private;
Private = EMU_SNP_PRIVATE_DATA_FROM_THIS (This);
@@ -292,13 +289,13 @@ EmuSnpStationAddress ( **/
EFI_STATUS
EmuSnpStatistics (
- IN EMU_SNP_PROTOCOL *This,
- IN BOOLEAN Reset,
- IN OUT UINTN *StatisticsSize OPTIONAL,
- OUT EFI_NETWORK_STATISTICS *StatisticsTable OPTIONAL
+ IN EMU_SNP_PROTOCOL *This,
+ IN BOOLEAN Reset,
+ IN OUT UINTN *StatisticsSize OPTIONAL,
+ OUT EFI_NETWORK_STATISTICS *StatisticsTable OPTIONAL
)
{
- EMU_SNP_PRIVATE *Private;
+ EMU_SNP_PRIVATE *Private;
Private = EMU_SNP_PRIVATE_DATA_FROM_THIS (This);
@@ -328,13 +325,13 @@ EmuSnpStatistics ( **/
EFI_STATUS
EmuSnpMCastIpToMac (
- IN EMU_SNP_PROTOCOL *This,
- IN BOOLEAN IPv6,
- IN EFI_IP_ADDRESS *IP,
- OUT EFI_MAC_ADDRESS *MAC
+ IN EMU_SNP_PROTOCOL *This,
+ IN BOOLEAN IPv6,
+ IN EFI_IP_ADDRESS *IP,
+ OUT EFI_MAC_ADDRESS *MAC
)
{
- EMU_SNP_PRIVATE *Private;
+ EMU_SNP_PRIVATE *Private;
Private = EMU_SNP_PRIVATE_DATA_FROM_THIS (This);
@@ -363,14 +360,14 @@ EmuSnpMCastIpToMac ( **/
EFI_STATUS
EmuSnpNvData (
- IN EMU_SNP_PROTOCOL *This,
- IN BOOLEAN ReadWrite,
- IN UINTN Offset,
- IN UINTN BufferSize,
- IN OUT VOID *Buffer
+ IN EMU_SNP_PROTOCOL *This,
+ IN BOOLEAN ReadWrite,
+ IN UINTN Offset,
+ IN UINTN BufferSize,
+ IN OUT VOID *Buffer
)
{
- EMU_SNP_PRIVATE *Private;
+ EMU_SNP_PRIVATE *Private;
Private = EMU_SNP_PRIVATE_DATA_FROM_THIS (This);
@@ -404,12 +401,12 @@ EmuSnpNvData ( **/
EFI_STATUS
EmuSnpGetStatus (
- IN EMU_SNP_PROTOCOL *This,
- OUT UINT32 *InterruptStatus OPTIONAL,
- OUT VOID **TxBuf OPTIONAL
+ IN EMU_SNP_PROTOCOL *This,
+ OUT UINT32 *InterruptStatus OPTIONAL,
+ OUT VOID **TxBuf OPTIONAL
)
{
- EMU_SNP_PRIVATE *Private;
+ EMU_SNP_PRIVATE *Private;
Private = EMU_SNP_PRIVATE_DATA_FROM_THIS (This);
@@ -451,16 +448,16 @@ EmuSnpGetStatus ( **/
EFI_STATUS
EmuSnpTransmit (
- IN EMU_SNP_PROTOCOL *This,
- IN UINTN HeaderSize,
- IN UINTN BufferSize,
- IN VOID *Buffer,
- IN EFI_MAC_ADDRESS *SrcAddr OPTIONAL,
- IN EFI_MAC_ADDRESS *DestAddr OPTIONAL,
- IN UINT16 *Protocol OPTIONAL
+ IN EMU_SNP_PROTOCOL *This,
+ IN UINTN HeaderSize,
+ IN UINTN BufferSize,
+ IN VOID *Buffer,
+ IN EFI_MAC_ADDRESS *SrcAddr OPTIONAL,
+ IN EFI_MAC_ADDRESS *DestAddr OPTIONAL,
+ IN UINT16 *Protocol OPTIONAL
)
{
- EMU_SNP_PRIVATE *Private;
+ EMU_SNP_PRIVATE *Private;
Private = EMU_SNP_PRIVATE_DATA_FROM_THIS (This);
@@ -501,24 +498,23 @@ EmuSnpTransmit ( **/
EFI_STATUS
EmuSnpReceive (
- IN EMU_SNP_PROTOCOL *This,
- OUT UINTN *HeaderSize OPTIONAL,
- IN OUT UINTN *BufferSize,
- OUT VOID *Buffer,
- OUT EFI_MAC_ADDRESS *SrcAddr OPTIONAL,
- OUT EFI_MAC_ADDRESS *DestAddr OPTIONAL,
- OUT UINT16 *Protocol OPTIONAL
+ IN EMU_SNP_PROTOCOL *This,
+ OUT UINTN *HeaderSize OPTIONAL,
+ IN OUT UINTN *BufferSize,
+ OUT VOID *Buffer,
+ OUT EFI_MAC_ADDRESS *SrcAddr OPTIONAL,
+ OUT EFI_MAC_ADDRESS *DestAddr OPTIONAL,
+ OUT UINT16 *Protocol OPTIONAL
)
{
- EMU_SNP_PRIVATE *Private;
+ EMU_SNP_PRIVATE *Private;
Private = EMU_SNP_PRIVATE_DATA_FROM_THIS (This);
return EFI_UNSUPPORTED;
}
-
-EMU_SNP_PROTOCOL gEmuSnpProtocol = {
+EMU_SNP_PROTOCOL gEmuSnpProtocol = {
GasketSnpCreateMapping,
GasketSnpStart,
GasketSnpStop,
@@ -537,7 +533,7 @@ EMU_SNP_PROTOCOL gEmuSnpProtocol = { EFI_STATUS
EmuSnpThunkOpen (
- IN EMU_IO_THUNK_PROTOCOL *This
+ IN EMU_IO_THUNK_PROTOCOL *This
)
{
EMU_SNP_PRIVATE *Private;
@@ -555,7 +551,6 @@ EmuSnpThunkOpen ( return EFI_OUT_OF_RESOURCES;
}
-
Private->Signature = EMU_SNP_PRIVATE_SIGNATURE;
Private->Thunk = This;
CopyMem (&Private->EmuSnp, &gEmuSnpProtocol, sizeof (gEmuSnpProtocol));
@@ -565,10 +560,9 @@ EmuSnpThunkOpen ( return EFI_SUCCESS;
}
-
EFI_STATUS
EmuSnpThunkClose (
- IN EMU_IO_THUNK_PROTOCOL *This
+ IN EMU_IO_THUNK_PROTOCOL *This
)
{
EMU_SNP_PRIVATE *Private;
@@ -583,9 +577,7 @@ EmuSnpThunkClose ( return EFI_SUCCESS;
}
-
-
-EMU_IO_THUNK_PROTOCOL gSnpThunkIo = {
+EMU_IO_THUNK_PROTOCOL gSnpThunkIo = {
&gEmuSnpProtocolGuid,
NULL,
NULL,
|