Changeset 99404 in vbox for trunk/src/VBox/Devices/EFI/FirmwareNew/NetworkPkg/Dhcp4Dxe/Dhcp4Impl.h
- Timestamp:
- Apr 14, 2023 3:17:44 PM (22 months ago)
- Location:
- trunk/src/VBox/Devices/EFI/FirmwareNew
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/EFI/FirmwareNew
-
Property svn:mergeinfo
changed from (toggle deleted branches)
to (toggle deleted branches)/vendor/edk2/current 103735-103757,103769-103776,129194-145445 /vendor/edk2/current 103735-103757,103769-103776,129194-156846
-
Property svn:mergeinfo
changed from (toggle deleted branches)
-
trunk/src/VBox/Devices/EFI/FirmwareNew/NetworkPkg/Dhcp4Dxe/Dhcp4Impl.h
r80721 r99404 14 14 #ifndef __EFI_DHCP4_IMPL_H__ 15 15 #define __EFI_DHCP4_IMPL_H__ 16 17 18 16 19 17 #include <Uefi.h> … … 29 27 #include <Library/NetLib.h> 30 28 31 typedef struct _DHCP_SERVICE DHCP_SERVICE;32 typedef struct _DHCP_PROTOCOL DHCP_PROTOCOL;29 typedef struct _DHCP_SERVICE DHCP_SERVICE; 30 typedef struct _DHCP_PROTOCOL DHCP_PROTOCOL; 33 31 34 32 #include "Dhcp4Option.h" … … 38 36 #define DHCP_PROTOCOL_SIGNATURE SIGNATURE_32 ('d', 'h', 'c', 'p') 39 37 40 #define DHCP_CHECK_MEDIA_WAITING_TIME 38 #define DHCP_CHECK_MEDIA_WAITING_TIME EFI_TIMER_PERIOD_SECONDS(20) 41 39 42 40 // … … 47 45 // destroyed. 48 46 // 49 #define DHCP_UNCONFIGED 0 50 #define DHCP_CONFIGED 1 51 #define DHCP_DESTROY 2 52 47 #define DHCP_UNCONFIGED 0 48 #define DHCP_CONFIGED 1 49 #define DHCP_DESTROY 2 53 50 54 51 struct _DHCP_PROTOCOL { 55 UINT32 Signature;56 EFI_DHCP4_PROTOCOL Dhcp4Protocol;57 LIST_ENTRY Link;58 EFI_HANDLE Handle;59 DHCP_SERVICE *Service;60 61 BOOLEAN InDestroy;62 63 EFI_EVENT CompletionEvent;64 EFI_EVENT RenewRebindEvent;65 66 EFI_DHCP4_TRANSMIT_RECEIVE_TOKEN *Token;67 UDP_IO *UdpIo; // The UDP IO used for TransmitReceive.68 UINT32 Timeout;69 UINT16 ElaspedTime;70 NET_BUF_QUEUE ResponseQueue;52 UINT32 Signature; 53 EFI_DHCP4_PROTOCOL Dhcp4Protocol; 54 LIST_ENTRY Link; 55 EFI_HANDLE Handle; 56 DHCP_SERVICE *Service; 57 58 BOOLEAN InDestroy; 59 60 EFI_EVENT CompletionEvent; 61 EFI_EVENT RenewRebindEvent; 62 63 EFI_DHCP4_TRANSMIT_RECEIVE_TOKEN *Token; 64 UDP_IO *UdpIo; // The UDP IO used for TransmitReceive. 65 UINT32 Timeout; 66 UINT16 ElaspedTime; 67 NET_BUF_QUEUE ResponseQueue; 71 68 }; 72 69 … … 76 73 // 77 74 struct _DHCP_SERVICE { 78 UINT32 Signature;79 EFI_SERVICE_BINDING_PROTOCOL ServiceBinding;80 81 INTN ServiceState; // CONFIGED, UNCONFIGED, and DESTROY82 83 EFI_HANDLE Controller;84 EFI_HANDLE Image;85 86 LIST_ENTRY Children;87 UINTN NumChildren;88 89 INTN DhcpState;90 EFI_STATUS IoStatus;// the result of last user operation91 UINT32 Xid;92 93 IP4_ADDR ClientAddr;// lease IP or configured client address94 IP4_ADDR Netmask;95 IP4_ADDR ServerAddr;96 97 EFI_DHCP4_PACKET *LastOffer;// The last received offer98 EFI_DHCP4_PACKET *Selected;99 DHCP_PARAMETER *Para;100 101 UINT32 Lease;102 UINT32 T1;103 UINT32 T2;104 INTN ExtraRefresh; // This refresh is reqested by user105 106 UDP_IO *UdpIo; // Udp child receiving all DHCP message107 UDP_IO *LeaseIoPort; // Udp child with lease IP108 EFI_DHCP4_PACKET *LastPacket; // The last sent packet for retransmission109 EFI_MAC_ADDRESS Mac;110 UINT8 HwType;111 UINT8 HwLen;112 UINT8 ClientAddressSendOut[16];113 114 DHCP_PROTOCOL *ActiveChild;115 EFI_DHCP4_CONFIG_DATA ActiveConfig;116 UINT32 UserOptionLen;75 UINT32 Signature; 76 EFI_SERVICE_BINDING_PROTOCOL ServiceBinding; 77 78 INTN ServiceState; // CONFIGED, UNCONFIGED, and DESTROY 79 80 EFI_HANDLE Controller; 81 EFI_HANDLE Image; 82 83 LIST_ENTRY Children; 84 UINTN NumChildren; 85 86 INTN DhcpState; 87 EFI_STATUS IoStatus; // the result of last user operation 88 UINT32 Xid; 89 90 IP4_ADDR ClientAddr; // lease IP or configured client address 91 IP4_ADDR Netmask; 92 IP4_ADDR ServerAddr; 93 94 EFI_DHCP4_PACKET *LastOffer; // The last received offer 95 EFI_DHCP4_PACKET *Selected; 96 DHCP_PARAMETER *Para; 97 98 UINT32 Lease; 99 UINT32 T1; 100 UINT32 T2; 101 INTN ExtraRefresh; // This refresh is reqested by user 102 103 UDP_IO *UdpIo; // Udp child receiving all DHCP message 104 UDP_IO *LeaseIoPort; // Udp child with lease IP 105 EFI_DHCP4_PACKET *LastPacket; // The last sent packet for retransmission 106 EFI_MAC_ADDRESS Mac; 107 UINT8 HwType; 108 UINT8 HwLen; 109 UINT8 ClientAddressSendOut[16]; 110 111 DHCP_PROTOCOL *ActiveChild; 112 EFI_DHCP4_CONFIG_DATA ActiveConfig; 113 UINT32 UserOptionLen; 117 114 118 115 // 119 116 // Timer event and various timer 120 117 // 121 EFI_EVENT Timer;122 123 UINT32 PacketToLive; // Retransmission timer for our packets124 UINT32 LastTimeout; // Record the init value of PacketToLive every time125 INTN CurRetry;126 INTN MaxRetries;127 UINT32 LeaseLife;118 EFI_EVENT Timer; 119 120 UINT32 PacketToLive; // Retransmission timer for our packets 121 UINT32 LastTimeout; // Record the init value of PacketToLive every time 122 INTN CurRetry; 123 INTN MaxRetries; 124 UINT32 LeaseLife; 128 125 }; 129 126 130 127 typedef struct { 131 EFI_DHCP4_PACKET_OPTION 132 UINT32 133 UINT32 128 EFI_DHCP4_PACKET_OPTION **Option; 129 UINT32 OptionCount; 130 UINT32 Index; 134 131 } DHCP_PARSE_CONTEXT; 135 132 … … 140 137 CR ((Sb), DHCP_SERVICE, ServiceBinding, DHCP_SERVICE_SIGNATURE) 141 138 142 extern EFI_DHCP4_PROTOCOL mDhcp4ProtocolTemplate;139 extern EFI_DHCP4_PROTOCOL mDhcp4ProtocolTemplate; 143 140 144 141 /** … … 152 149 VOID 153 150 DhcpYieldControl ( 154 IN DHCP_SERVICE 151 IN DHCP_SERVICE *DhcpSb 155 152 ); 156 153 … … 188 185 EFIAPI 189 186 DhcpDummyExtFree ( 190 IN VOID 187 IN VOID *Arg 191 188 ); 192 189 … … 200 197 VOID 201 198 SetElapsedTime ( 202 IN UINT16 203 IN DHCP_PROTOCOL 199 IN UINT16 *Elapsed, 200 IN DHCP_PROTOCOL *Instance 204 201 ); 205 202
Note:
See TracChangeset
for help on using the changeset viewer.