TianoCore EDK2 master
|
Go to the source code of this file.
Data Structures | |
union | IP4_CONFIG2_DATA |
struct | IP4_CONFIG2_DATA_ITEM |
struct | IP4_CONFIG2_DATA_RECORD |
struct | IP4_CONFIG2_VARIABLE |
struct | IP4_CONFIG2_NVDATA |
struct | _IP4_FORM_CALLBACK_INFO |
struct | _IP4_CONFIG2_INSTANCE |
struct | IP4_CONFIG2_DHCP4_OPTION |
Macros | |
#define | IP4_CONFIG2_INSTANCE_SIGNATURE SIGNATURE_32 ('I', 'P', 'C', '2') |
#define | IP4_FORM_CALLBACK_INFO_SIGNATURE SIGNATURE_32 ('I', 'F', 'C', 'I') |
#define | IP4_CONFIG2_VARIABLE_ATTRIBUTE (EFI_VARIABLE_NON_VOLATILE | EFI_VARIABLE_BOOTSERVICE_ACCESS) |
#define | DATA_ATTRIB_SIZE_FIXED 0x1 |
#define | DATA_ATTRIB_VOLATILE 0x2 |
#define | DATA_ATTRIB_SET(Attrib, Bits) (BOOLEAN)((Attrib) & (Bits)) |
#define | SET_DATA_ATTRIB(Attrib, Bits) ((Attrib) |= (Bits)) |
#define | REMOVE_DATA_ATTRIB(Attrib, Bits) ((Attrib) &= (~Bits)) |
#define | IP4_CONFIG2_INSTANCE_FROM_PROTOCOL(Proto) |
#define | IP4_SERVICE_FROM_IP4_CONFIG2_INSTANCE(Instance) |
#define | IP4_CONFIG2_INSTANCE_FROM_FORM_CALLBACK(Callback) |
#define | IP4_FORM_CALLBACK_INFO_FROM_CONFIG_ACCESS(ConfigAccess) |
Typedefs | |
typedef struct _IP4_CONFIG2_INSTANCE | IP4_CONFIG2_INSTANCE |
typedef EFI_STATUS(* | IP4_CONFIG2_SET_DATA) (IN IP4_CONFIG2_INSTANCE *Instance, IN UINTN DataSize, IN VOID *Data) |
typedef EFI_STATUS(* | IP4_CONFIG2_GET_DATA) (IN IP4_CONFIG2_INSTANCE *Instance, IN OUT UINTN *DataSize, IN VOID *Data OPTIONAL) |
typedef struct _IP4_FORM_CALLBACK_INFO | IP4_FORM_CALLBACK_INFO |
Functions | |
EFI_STATUS | Ip4Config2ReadConfigData (IN CHAR16 *VarName, IN OUT IP4_CONFIG2_INSTANCE *Instance) |
EFI_STATUS | Ip4StartAutoConfig (IN IP4_CONFIG2_INSTANCE *Instance) |
EFI_STATUS | Ip4Config2InitInstance (OUT IP4_CONFIG2_INSTANCE *Instance) |
VOID | Ip4Config2CleanInstance (IN OUT IP4_CONFIG2_INSTANCE *Instance) |
VOID EFIAPI | Ip4AutoReconfigCallBack (IN EFI_EVENT Event, IN VOID *Context) |
EFI_STATUS | Ip4Config2DestroyDhcp4 (IN OUT IP4_CONFIG2_INSTANCE *Instance) |
Definitions for EFI IPv4 Configuration II Protocol implementation.
Copyright (c) 2015 - 2018, Intel Corporation. All rights reserved.
(C) Copyright 2015 Hewlett Packard Enterprise Development LP
SPDX-License-Identifier: BSD-2-Clause-Patent
Definition in file Ip4Config2Impl.h.
#define DATA_ATTRIB_SET | ( | Attrib, | |
Bits | |||
) | (BOOLEAN)((Attrib) & (Bits)) |
Definition at line 22 of file Ip4Config2Impl.h.
#define DATA_ATTRIB_SIZE_FIXED 0x1 |
Definition at line 19 of file Ip4Config2Impl.h.
#define DATA_ATTRIB_VOLATILE 0x2 |
Definition at line 20 of file Ip4Config2Impl.h.
#define IP4_CONFIG2_INSTANCE_FROM_FORM_CALLBACK | ( | Callback | ) |
Definition at line 42 of file Ip4Config2Impl.h.
#define IP4_CONFIG2_INSTANCE_FROM_PROTOCOL | ( | Proto | ) |
Definition at line 28 of file Ip4Config2Impl.h.
#define IP4_CONFIG2_INSTANCE_SIGNATURE SIGNATURE_32 ('I', 'P', 'C', '2') |
Definition at line 14 of file Ip4Config2Impl.h.
#define IP4_CONFIG2_VARIABLE_ATTRIBUTE (EFI_VARIABLE_NON_VOLATILE | EFI_VARIABLE_BOOTSERVICE_ACCESS) |
Definition at line 17 of file Ip4Config2Impl.h.
#define IP4_FORM_CALLBACK_INFO_FROM_CONFIG_ACCESS | ( | ConfigAccess | ) |
Definition at line 49 of file Ip4Config2Impl.h.
#define IP4_FORM_CALLBACK_INFO_SIGNATURE SIGNATURE_32 ('I', 'F', 'C', 'I') |
Definition at line 15 of file Ip4Config2Impl.h.
#define IP4_SERVICE_FROM_IP4_CONFIG2_INSTANCE | ( | Instance | ) |
Definition at line 35 of file Ip4Config2Impl.h.
#define REMOVE_DATA_ATTRIB | ( | Attrib, | |
Bits | |||
) | ((Attrib) &= (~Bits)) |
Definition at line 24 of file Ip4Config2Impl.h.
#define SET_DATA_ATTRIB | ( | Attrib, | |
Bits | |||
) | ((Attrib) |= (Bits)) |
Definition at line 23 of file Ip4Config2Impl.h.
typedef EFI_STATUS(* IP4_CONFIG2_GET_DATA) (IN IP4_CONFIG2_INSTANCE *Instance, IN OUT UINTN *DataSize, IN VOID *Data OPTIONAL) |
The prototype of work function for EfiIp4Config2GetData().
[in] | Instance | The pointer to the IP4 config2 instance data. |
[in,out] | DataSize | On input, in bytes, the size of Data. On output, in bytes, the size of buffer required to store the specified configuration data. |
[in] | Data | The data buffer in which the configuration data is returned. Ignored if DataSize is ZERO. |
EFI_BUFFER_TOO_SMALL | The size of Data is too small for the specified configuration data, and the required size is returned in DataSize. |
EFI_SUCCESS | The specified configuration data was obtained successfully. |
Definition at line 94 of file Ip4Config2Impl.h.
typedef struct _IP4_CONFIG2_INSTANCE IP4_CONFIG2_INSTANCE |
Definition at line 26 of file Ip4Config2Impl.h.
typedef EFI_STATUS(* IP4_CONFIG2_SET_DATA) (IN IP4_CONFIG2_INSTANCE *Instance, IN UINTN DataSize, IN VOID *Data) |
The prototype of work function for EfiIp4Config2SetData().
[in] | Instance | The pointer to the IP4 config2 instance data. |
[in] | DataSize | In bytes, the size of the buffer pointed to by Data. |
[in] | Data | The data buffer to set. |
EFI_BAD_BUFFER_SIZE | The DataSize does not match the size of the type, 8 bytes. |
EFI_SUCCESS | The specified configuration data for the EFI IPv4 network stack was set successfully. |
Definition at line 70 of file Ip4Config2Impl.h.
Request Ip4AutoReconfigCallBackDpc as a DPC at TPL_CALLBACK.
Event | The event that is signalled. |
Context | The IP4 service binding instance. |
Definition at line 2134 of file Ip4Config2Impl.c.
VOID Ip4Config2CleanInstance | ( | IN OUT IP4_CONFIG2_INSTANCE * | Instance | ) |
Release an IP4_CONFIG2_INSTANCE.
[in,out] | Instance | The buffer of IP4_CONFIG2_INSTANCE to be freed. |
Definition at line 2049 of file Ip4Config2Impl.c.
EFI_STATUS Ip4Config2DestroyDhcp4 | ( | IN OUT IP4_CONFIG2_INSTANCE * | Instance | ) |
Destroy the Dhcp4 child in IP4_CONFIG2_INSTANCE and release the resources.
[in,out] | Instance | The buffer of IP4 config2 instance to be freed. |
EFI_SUCCESS | The child was successfully destroyed. |
Others | Failed to destroy the child. |
Definition at line 40 of file Ip4Config2Impl.c.
EFI_STATUS Ip4Config2InitInstance | ( | OUT IP4_CONFIG2_INSTANCE * | Instance | ) |
Initialize an IP4_CONFIG2_INSTANCE.
[out] | Instance | The buffer of IP4_CONFIG2_INSTANCE to be initialized. |
EFI_OUT_OF_RESOURCES | Failed to allocate resources to complete the operation. |
EFI_SUCCESS | The IP4_CONFIG2_INSTANCE initialized successfully. |
Definition at line 1942 of file Ip4Config2Impl.c.
EFI_STATUS Ip4Config2ReadConfigData | ( | IN CHAR16 * | VarName, |
IN OUT IP4_CONFIG2_INSTANCE * | Instance | ||
) |
Read the configuration data from variable storage according to the VarName and gEfiIp4Config2ProtocolGuid. It checks the integrity of variable data. If the data is corrupted, it clears the variable data to ZERO. Otherwise, it outputs the configuration data to IP4_CONFIG2_INSTANCE.
[in] | VarName | The pointer to the variable name |
[in,out] | Instance | The pointer to the IP4 config2 instance data. |
EFI_NOT_FOUND | The variable can not be found or already corrupted. |
EFI_OUT_OF_RESOURCES | Fail to allocate resource to complete the operation. |
EFI_SUCCESS | The configuration data was retrieved successfully. |
Definition at line 188 of file Ip4Config2Impl.c.
EFI_STATUS Ip4StartAutoConfig | ( | IN IP4_CONFIG2_INSTANCE * | Instance | ) |
Start the DHCP configuration for this IP service instance. It will locates the EFI_IP4_CONFIG2_PROTOCOL, then start the DHCP configuration.
[in] | Instance | The IP4 config2 instance to configure. |
EFI_SUCCESS | The auto configuration is successfully started. |
Others | Failed to start auto configuration. |
Start the DHCP configuration for this IP service instance. It will locates the EFI_IP4_CONFIG2_PROTOCOL, then start the DHCP configuration.
[in] | Instance | The IP4 config2 instance to configure |
EFI_SUCCESS | The auto configuration is successfully started |
Others | Failed to start auto configuration. |
Definition at line 885 of file Ip4Config2Impl.c.