From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=209.132.183.28; helo=mx1.redhat.com; envelope-from=lersek@redhat.com; receiver=edk2-devel@lists.01.org Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 40AAC21143991 for ; Tue, 25 Sep 2018 13:23:30 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id C3CE38830E; Tue, 25 Sep 2018 20:23:29 +0000 (UTC) Received: from lacos-laptop-7.usersys.redhat.com (ovpn-120-71.rdu2.redhat.com [10.10.120.71]) by smtp.corp.redhat.com (Postfix) with ESMTP id 6C3625E1A8; Tue, 25 Sep 2018 20:23:28 +0000 (UTC) To: Jiaxin Wu , edk2-devel@lists.01.org Cc: Ye Ting , Shao Ming , Fu Siyuan References: <20180925011145.14316-1-Jiaxin.wu@intel.com> <20180925011145.14316-3-Jiaxin.wu@intel.com> From: Laszlo Ersek Message-ID: Date: Tue, 25 Sep 2018 22:23:27 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <20180925011145.14316-3-Jiaxin.wu@intel.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.28]); Tue, 25 Sep 2018 20:23:29 +0000 (UTC) Subject: Re: [PATCH v2 5/5] NetworkPkg/UefiPxeBcDxe: Use the specified MTFTP windowsize. X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 25 Sep 2018 20:23:30 -0000 Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit On 09/25/18 03:11, Jiaxin Wu wrote: > *v2: Since the new PCD (PcdPxeTftpWindowSize) was renamed/defined in > NetworkPkg instead of MdeModulePkg, this new version is to update the > consuming PXE driver. > > Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=886 > > This patch is to use the specified MTFTP windowsize to benefit the PXE > download performance. > > Cc: Ye Ting > Cc: Fu Siyuan > Cc: Shao Ming > Cc: Laszlo Ersek > Contributed-under: TianoCore Contribution Agreement 1.1 > Signed-off-by: Wu Jiaxin > --- > NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c | 10 +- > NetworkPkg/UefiPxeBcDxe/PxeBcMtftp.c | 137 +++++++++++++++++------ > NetworkPkg/UefiPxeBcDxe/PxeBcMtftp.h | 6 +- > NetworkPkg/UefiPxeBcDxe/UefiPxeBcDxe.inf | 3 + > 4 files changed, 121 insertions(+), 35 deletions(-) I compared this variant against the v1 posting. The difference is very small (as you explain in the blurb): > diff --git a/NetworkPkg/UefiPxeBcDxe/UefiPxeBcDxe.inf b/NetworkPkg/UefiPxeBcDxe/UefiPxeBcDxe.inf > index 949596c029be..e2a0eb44b1fc 100644 > --- a/NetworkPkg/UefiPxeBcDxe/UefiPxeBcDxe.inf > +++ b/NetworkPkg/UefiPxeBcDxe/UefiPxeBcDxe.inf > @@ -55,6 +55,7 @@ [Sources] > [Packages] > MdePkg/MdePkg.dec > MdeModulePkg/MdeModulePkg.dec > + NetworkPkg/NetworkPkg.dec > > > [LibraryClasses] > @@ -107,7 +108,7 @@ [Guids] > > [Pcd] > gEfiMdeModulePkgTokenSpaceGuid.PcdTftpBlockSize ## SOMETIMES_CONSUMES > - gEfiMdeModulePkgTokenSpaceGuid.PcdTftpWindowSize ## SOMETIMES_CONSUMES > + gEfiNetworkPkgTokenSpaceGuid.PcdPxeTftpWindowSize ## SOMETIMES_CONSUMES > > [UserExtensions.TianoCore."ExtraFiles"] > UefiPxeBcDxeExtra.uni > diff --git a/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c b/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c > index db463d1b11fb..468b38d887d8 100644 > --- a/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c > +++ b/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c > @@ -874,9 +874,9 @@ EfiPxeBcMtftp ( > Mode = Private->PxeBc.Mode; > > // > - // Get PcdTftpWindowSize. > + // Get PcdPxeTftpWindowSize. > // > - WindowSize = (UINTN) PcdGet64 (PcdTftpWindowSize); > + WindowSize = (UINTN) PcdGet64 (PcdPxeTftpWindowSize); > > if (Mode->UsingIpv6) { > if (!NetIp6IsValidUnicast (&ServerIp->v6)) { Also, the renaming of the PCD hasn't changed its default value (4), its data type (UINT64), or its "flavor" ([PcdsFixedAtBuild, PcdsPatchableInModule]). Therefore, in this specific case, I think we should carry forward my T-b for this patch (patch #5) as well, from: http://mid.mail-archive.com/bbd4d8e9-6470-8cc8-ff7d-6b154adbd7ce@redhat.com Thanks! Laszlo