X-Git-Url: https://git.proxmox.com/?a=blobdiff_plain;f=MdeModulePkg%2FUniversal%2FNetwork%2FIp4Dxe%2FIp4Impl.h;h=ddca6ce897f6ecdee0e46d1af6ec2b50893bf473;hb=3028d73e5a4073841fdfc94b1e984c92e8e8fa7a;hp=a1a76bd612b9c33f5f94e2aff15173636cba9281;hpb=e371cc146dfac1680e69112a01a3f7d121998c37;p=mirror_edk2.git diff --git a/MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Impl.h b/MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Impl.h index a1a76bd612..ddca6ce897 100644 --- a/MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Impl.h +++ b/MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Impl.h @@ -1,7 +1,9 @@ /** @file Ip4 internal functions and type defintions. - -Copyright (c) 2005 - 2015, Intel Corporation. All rights reserved.
+ +Copyright (c) 2005 - 2018, Intel Corporation. All rights reserved.
+(C) Copyright 2015 Hewlett-Packard Development Company, L.P.
+ This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at @@ -26,6 +28,8 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. #include #include +#include + #include #include #include @@ -60,12 +64,10 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. // // The state of IP4 protocol. It starts from UNCONFIGED. if it is // successfully configured, it goes to CONFIGED. if configure NULL -// is called, it becomes UNCONFIGED again. If (partly) destroyed, it -// becomes DESTROY. +// is called, it becomes UNCONFIGED again. // #define IP4_STATE_UNCONFIGED 0 #define IP4_STATE_CONFIGED 1 -#define IP4_STATE_DESTROY 2 // // The state of IP4 service. It starts from UNSTARTED. It transits @@ -132,6 +134,8 @@ struct _IP4_PROTOCOL { EFI_HANDLE Handle; INTN State; + BOOLEAN InDestroy; + IP4_SERVICE *Service; LIST_ENTRY Link; // Link to all the IP protocol from the service @@ -202,13 +206,13 @@ struct _IP4_SERVICE { EFI_SIMPLE_NETWORK_MODE SnpMode; EFI_EVENT Timer; - + EFI_EVENT ReconfigCheckTimer; EFI_EVENT ReconfigEvent; BOOLEAN Reconfig; // - // Underlying media present status. + // Underlying media present status. // BOOLEAN MediaPresent; @@ -330,10 +334,9 @@ Ip4Groups ( ); /** - The heart beat timer of IP4 service instance. It times out - all of its IP4 children's received-but-not-delivered and - transmitted-but-not-recycle packets, and provides time input - for its IGMP protocol. + This heart beat timer of IP4 service instance times out all of its IP4 children's + received-but-not-delivered and transmitted-but-not-recycle packets, and provides + time input for its IGMP protocol. @param[in] Event The IP4 service instance's heart beat timer. @param[in] Context The IP4 service instance. @@ -346,6 +349,25 @@ Ip4TimerTicking ( IN VOID *Context ); +/** + This dedicated timer is used to poll underlying network media status. In case + of cable swap or wireless network switch, a new round auto configuration will + be initiated. The timer will signal the IP4 to run DHCP configuration again. + IP4 driver will free old IP address related resource, such as route table and + Interface, then initiate a DHCP process to acquire new IP, eventually create + route table for new IP address. + + @param[in] Event The IP4 service instance's heart beat timer. + @param[in] Context The IP4 service instance. + +**/ +VOID +EFIAPI +Ip4TimerReconfigChecking ( + IN EFI_EVENT Event, + IN VOID *Context + ); + /** Decrease the life of the transmitted packets. If it is decreased to zero, cancel the packet. This function is @@ -396,5 +418,6 @@ Ip4FreeTxToken ( ); extern EFI_IPSEC2_PROTOCOL *mIpSec; +extern BOOLEAN mIpSec2Installed; #endif