From d674ed538f7ea31dd8aa292f439989136d0b6fc5 Mon Sep 17 00:00:00 2001 From: eric_tian Date: Wed, 2 Sep 2009 02:33:15 +0000 Subject: [PATCH] UEFI 2.3 Specification should be updated to move these status code definitions into Appendix D, so all the EFI_STATUS codes are defined in a single place in the specifications, and that will help avoid status code collisions as new status codes may be defined over time. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9222 6f19259b-4bc3-4df7-8a09-765794883524 --- MdePkg/Include/Protocol/Tcp4.h | 4 ---- MdePkg/Include/Protocol/Udp4.h | 9 --------- MdePkg/Include/Uefi/UefiBaseType.h | 29 ++++++++++++++++++++++------- 3 files changed, 22 insertions(+), 20 deletions(-) diff --git a/MdePkg/Include/Protocol/Tcp4.h b/MdePkg/Include/Protocol/Tcp4.h index 355afe1835..2d7f788c64 100644 --- a/MdePkg/Include/Protocol/Tcp4.h +++ b/MdePkg/Include/Protocol/Tcp4.h @@ -500,10 +500,6 @@ struct _EFI_TCP4_PROTOCOL { EFI_TCP4_POLL Poll; }; -#define EFI_CONNECTION_FIN EFIERR (104) -#define EFI_CONNECTION_RESET EFIERR (105) -#define EFI_CONNECTION_REFUSED EFIERR (106) - extern EFI_GUID gEfiTcp4ServiceBindingProtocolGuid; extern EFI_GUID gEfiTcp4ProtocolGuid; diff --git a/MdePkg/Include/Protocol/Udp4.h b/MdePkg/Include/Protocol/Udp4.h index 6ba49a7d27..8807aa660c 100644 --- a/MdePkg/Include/Protocol/Udp4.h +++ b/MdePkg/Include/Protocol/Udp4.h @@ -48,15 +48,6 @@ typedef struct { EFI_UDP4_SERVICE_POINT Services[1]; } EFI_UDP4_VARIABLE_DATA; -// -//ICMP error definitions -// -#define EFI_NETWORK_UNREACHABLE EFIERR(100) -#define EFI_HOST_UNREACHABLE EFIERR(101) -#define EFI_PROTOCOL_UNREACHABLE EFIERR(102) -#define EFI_PORT_UNREACHABLE EFIERR(103) - - typedef struct { UINT32 FragmentLength; VOID *FragmentBuffer; diff --git a/MdePkg/Include/Uefi/UefiBaseType.h b/MdePkg/Include/Uefi/UefiBaseType.h index 572f695935..b98ed9c4dc 100644 --- a/MdePkg/Include/Uefi/UefiBaseType.h +++ b/MdePkg/Include/Uefi/UefiBaseType.h @@ -115,9 +115,9 @@ typedef union { } EFI_IP_ADDRESS; -// -// Enumeration of EFI_STATUS. -// +/// +/// Enumeration of EFI_STATUS. +///@{ #define EFI_SUCCESS RETURN_SUCCESS #define EFI_LOAD_ERROR RETURN_LOAD_ERROR #define EFI_INVALID_PARAMETER RETURN_INVALID_PARAMETER @@ -154,16 +154,31 @@ typedef union { #define EFI_WARN_DELETE_FAILURE RETURN_WARN_DELETE_FAILURE #define EFI_WARN_WRITE_FAILURE RETURN_WARN_WRITE_FAILURE #define EFI_WARN_BUFFER_TOO_SMALL RETURN_WARN_BUFFER_TOO_SMALL +///@} - -// -// Define macro to encode the status code. -// +/// +/// Define macro to encode the status code. +/// #define EFIERR(_a) ENCODE_ERROR(_a) #define EFI_ERROR(A) RETURN_ERROR(A) +/// +/// ICMP error definitions +///@{ +#define EFI_NETWORK_UNREACHABLE EFIERR(100) +#define EFI_HOST_UNREACHABLE EFIERR(101) +#define EFI_PROTOCOL_UNREACHABLE EFIERR(102) +#define EFI_PORT_UNREACHABLE EFIERR(103) +///@} +/// +/// Tcp connection status definitions +///@{ +#define EFI_CONNECTION_FIN EFIERR(104) +#define EFI_CONNECTION_RESET EFIERR(105) +#define EFI_CONNECTION_REFUSED EFIERR(106) +///@} // // The EFI memory allocation functions work in units of EFI_PAGEs that are -- 2.39.2