From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by mx.groups.io with SMTP id smtpd.web11.31033.1649690356196127767 for ; Mon, 11 Apr 2022 08:19:16 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="unable to parse pub key" header.i=@intel.com header.s=intel header.b=oD5pyY63; spf=none, err=permanent DNS error (domain: linux.intel.com, ip: 134.134.136.31, mailfrom: maciej.rabeda@linux.intel.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1649690356; x=1681226356; h=message-id:date:mime-version:subject:from:to:cc:reply-to: references:in-reply-to:content-transfer-encoding; bh=/zgO720ryCTnFk+e63Nx8oVtgalWo8wzc+9x0UAe8qc=; b=oD5pyY63Xtrjc8KPfo0swyUes9VCS0F5jSIlCD59qe2X6joDPgYGXMWd iSMPAYBszRitbQmn9EdIk7BycGDjOABcFxKWJ8QlB+6ZHn6KhyEVmDJhV jHGonftzqqk2YZxQYNJt2sPQzEMNL24K60d91e80yNLWSDGVsic61+o1F 6QQ+5KIW708Uk9pZDNIk6Ye5dpI1M0lyfqyAgbrNAF9Q9CFrx9F0qE8+h qdHJJt/GjPOonMkl1sKVsCERHmQfwdj4SeSv+lTDXDD317Yt3tmDO3W9S YO+3VW6ebSSw3JGaBdycsRhnp4OiNX2AxCa1amL7+i/Szmig6x4Akyjlu A==; X-IronPort-AV: E=McAfee;i="6400,9594,10314"; a="322585920" X-IronPort-AV: E=Sophos;i="5.90,252,1643702400"; d="scan'208";a="322585920" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 Apr 2022 08:19:15 -0700 X-IronPort-AV: E=Sophos;i="5.90,252,1643702400"; d="scan'208";a="551181698" Received: from mrabeda-mobl2.ger.corp.intel.com (HELO [10.102.8.146]) ([10.102.8.146]) by orsmga007-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 Apr 2022 08:19:13 -0700 Message-ID: <18b0a3ec-7557-2e62-96c3-6bec24bdfa4f@linux.intel.com> Date: Mon, 11 Apr 2022 17:19:05 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.7.0 Subject: Re: [edk2-devel] [Patch V4] NetworkPkg: Add PCDs for HTTP DNS RetryCount and RetryInterval From: "Maciej Rabeda" To: devel@edk2.groups.io, heng.luo@intel.com Cc: "Fu, Siyuan" , "Wu, Jiaxin" , "Rabeda, Maciej" Reply-To: devel@edk2.groups.io, maciej.rabeda@linux.intel.com References: <16E24E429C73DB68.15950@groups.io> <16E39B356604C22D.23834@groups.io> In-Reply-To: <16E39B356604C22D.23834@groups.io> Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Patch merged: https://github.com/tianocore/edk2/pull/2756 On 7 kwi 2022 13:54, Maciej Rabeda wrote: > Reviewed-by: Maciej Rabeda > > On 6 kwi 2022 04:02, Heng Luo wrote: >> Dear Maintainers, >> Could you review the patch? All checks have passed the EDK2 CI build. >> https://github.com/tianocore/edk2/pull/2717 >> >> Thanks, >> Heng >> >>> -----Original Message----- >>> From: devel@edk2.groups.io On Behalf Of Heng Luo >>> Sent: Sunday, April 3, 2022 2:14 PM >>> To: devel@edk2.groups.io >>> Cc: Maciej Rabeda ; Fu, Siyuan >>> ; Wu, Jiaxin >>> Subject: [edk2-devel] [Patch V4] NetworkPkg: Add PCDs for HTTP DNS >>> RetryCount and RetryInterval >>> >>> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3889 >>> >>> Currently the HTTP DNS Retry Interval is 2 second and no retry attempt. >>> If DNS response can't arrive in 2 second, the DNS request is failed, >>> and then >>> HTTP boot is failed. >>> In order to resolve this issue, Add PCDs to support RetryCount and >>> RetryInterval >>> configured in Platform. >>> >>> Cc: Maciej Rabeda >>> Cc: Fu Siyuan >>> Cc: Wu Jiaxin >>> Signed-off-by: Heng Luo >>> --- >>>   NetworkPkg/HttpDxe/HttpDns.c   |  4 ++++ >>>   NetworkPkg/HttpDxe/HttpDxe.inf |  2 ++ >>>   NetworkPkg/NetworkPkg.dec      |  9 +++++++++ >>>   NetworkPkg/NetworkPkg.uni      | 11 +++++++++++ >>>   4 files changed, 26 insertions(+) >>> >>> diff --git a/NetworkPkg/HttpDxe/HttpDns.c >>> b/NetworkPkg/HttpDxe/HttpDns.c >>> index 59a2784e6a..13cbde0f34 100644 >>> --- a/NetworkPkg/HttpDxe/HttpDns.c >>> +++ b/NetworkPkg/HttpDxe/HttpDns.c >>> @@ -108,6 +108,8 @@ HttpDns4 ( >>>     Dns4CfgData.DnsServerListCount = DnsServerListCount; >>>     Dns4CfgData.DnsServerList      = DnsServerList; >>>     Dns4CfgData.UseDefaultSetting  = HttpInstance- >>>> IPv4Node.UseDefaultAddress; >>> +  Dns4CfgData.RetryInterval      = PcdGet32 (PcdHttpDnsRetryInterval); >>> +  Dns4CfgData.RetryCount         = PcdGet32 (PcdHttpDnsRetryCount); >>>     if (!Dns4CfgData.UseDefaultSetting) { >>>       IP4_COPY_ADDRESS (&Dns4CfgData.StationIp, &HttpInstance- >>>> IPv4Node.LocalAddress); >>>       IP4_COPY_ADDRESS (&Dns4CfgData.SubnetMask, &HttpInstance- >>>> IPv4Node.LocalSubnet); >>> @@ -315,6 +317,8 @@ HttpDns6 ( >>>     Dns6ConfigData.DnsServerList  = DnsServerList; >>>     Dns6ConfigData.EnableDnsCache = TRUE; >>>     Dns6ConfigData.Protocol       = EFI_IP_PROTO_UDP; >>> +  Dns6ConfigData.RetryInterval  = PcdGet32 (PcdHttpDnsRetryInterval); >>> +  Dns6ConfigData.RetryCount     = PcdGet32 (PcdHttpDnsRetryCount); >>>     IP6_COPY_ADDRESS (&Dns6ConfigData.StationIp, &HttpInstance- >>>> Ipv6Node.LocalAddress); >>>     Status = Dns6->Configure ( >>>                      Dns6, >>> diff --git a/NetworkPkg/HttpDxe/HttpDxe.inf >>> b/NetworkPkg/HttpDxe/HttpDxe.inf index af681c0184..c9502d0bb6 100644 >>> --- a/NetworkPkg/HttpDxe/HttpDxe.inf >>> +++ b/NetworkPkg/HttpDxe/HttpDxe.inf >>> @@ -75,6 +75,8 @@ >>>   [Pcd] >>>     gEfiNetworkPkgTokenSpaceGuid.PcdAllowHttpConnections ## CONSUMES >>>     gEfiNetworkPkgTokenSpaceGuid.PcdHttpIoTimeout ## CONSUMES >>> +  gEfiNetworkPkgTokenSpaceGuid.PcdHttpDnsRetryInterval ## CONSUMES >>> +  gEfiNetworkPkgTokenSpaceGuid.PcdHttpDnsRetryCount ## CONSUMES >>> >>>   [UserExtensions.TianoCore."ExtraFiles"] >>>     HttpDxeExtra.uni >>> diff --git a/NetworkPkg/NetworkPkg.dec b/NetworkPkg/NetworkPkg.dec >>> index >>> 928e84fec4..5e43ebf8c5 100644 >>> --- a/NetworkPkg/NetworkPkg.dec >>> +++ b/NetworkPkg/NetworkPkg.dec >>> @@ -163,5 +163,14 @@ >>>     # @Prompt The Timeout value of HTTP Io. Default value is 5000. >>> >>> gEfiNetworkPkgTokenSpaceGuid.PcdHttpIoTimeout|5000|UINT32|0x0000000F >>> >>> +  ## The Retry Interval of HTTP DNS in seconds. If the Retry Interval >>> + is less than  # DNS_DEFAULT_TIMEOUT, then use the >>> DNS_DEFAULT_TIMEOUT. >>> +  # @Prompt The value of Retry Interval. Default value is 0 >>> + >>> + >>> gEfiNetworkPkgTokenSpaceGuid.PcdHttpDnsRetryInterval|0|UINT32|0x000000 >>> + 10 >>> + >>> +  ## The Retry Count of HTTP DNS if no DNS response received after >>> Retry >>> Interval. >>> +  # @Prompt The value of Retry Count,  Default value is 0. >>> + >>> gEfiNetworkPkgTokenSpaceGuid.PcdHttpDnsRetryCount|0|UINT32|0x0000001 >>> 1 >>> + >>>   [UserExtensions.TianoCore."ExtraFiles"] >>>     NetworkPkgExtra.uni >>> diff --git a/NetworkPkg/NetworkPkg.uni b/NetworkPkg/NetworkPkg.uni >>> index >>> 6d0fa67c6f..c0bbbd3ee1 100644 >>> --- a/NetworkPkg/NetworkPkg.uni >>> +++ b/NetworkPkg/NetworkPkg.uni >>> @@ -111,3 +111,14 @@ >>>   #string STR_gEfiNetworkPkgTokenSpaceGuid_PcdHttpIoTimeout_HELP >>> #language en-US "This value is used to configure the request and >>> response >>> timeout when getting " >>> "the recovery image from the >>> remote source during an HTTP recovery boot." >>> "The default value set is 5 seconds." >>> + >>> +#string >>> STR_gEfiNetworkPkgTokenSpaceGuid_PcdHttpDnsRetryInterval_PROMPT >>> #language en-US "Retry Interval of HTTP DNS" >>> + >>> +#string STR_gEfiNetworkPkgTokenSpaceGuid_PcdHttpDnsRetryInterval_HELP >>> #language en-US "This value is used to configure the retry Interval >>> of HTTP >>> DNS." >>> + "The default value set is 0 second. >>> If the value is less than" >>> + "DNS_DEFAULT_TIMEOUT, then >>> use the DNS_DEFAULT_TIMEOUT." >>> + >>> +#string STR_gEfiNetworkPkgTokenSpaceGuid_PcdHttpDnsRetryCount_PROMPT >>> #language en-US "Retry Count of HTTP DNS" >>> + >>> +#string STR_gEfiNetworkPkgTokenSpaceGuid_PcdHttpDnsRetryCount_HELP >>> #language en-US "This value is used to configure the Retry Count of >>> HTTP DNS if >>> " >>> + "no DNS response received after >>> Retry Interval. The default value set is 0." >>> -- >>> 2.31.1.windows.1 >>> >>> >>> >>> >>> >> >> >> >> >> > > > > >