From nobody Fri Dec 27 20:55:58 2024 Delivered-To: importer@patchew.org Received-SPF: none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) client-ip=198.145.21.10; envelope-from=edk2-devel-bounces@lists.01.org; helo=ml01.01.org; Authentication-Results: mx.zohomail.com; spf=none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) smtp.mailfrom=edk2-devel-bounces@lists.01.org Return-Path: Received: from ml01.01.org (ml01.01.org [198.145.21.10]) by mx.zohomail.com with SMTPS id 1500984783052945.1054660969468; Tue, 25 Jul 2017 05:13:03 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id DC21321C9126B; Tue, 25 Jul 2017 05:10:52 -0700 (PDT) Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) (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 5017221C91264 for ; Tue, 25 Jul 2017 05:10:51 -0700 (PDT) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 25 Jul 2017 05:12:52 -0700 Received: from jiaxinwu-mobl2.ccr.corp.intel.com ([10.255.27.40]) by orsmga001.jf.intel.com with ESMTP; 25 Jul 2017 05:12:51 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.40,411,1496127600"; d="scan'208";a="1155145662" From: Jiaxin Wu To: edk2-devel@lists.01.org Date: Tue, 25 Jul 2017 20:12:44 +0800 Message-Id: <1500984765-8040-4-git-send-email-jiaxin.wu@intel.com> X-Mailer: git-send-email 1.9.5.msysgit.1 In-Reply-To: <1500984765-8040-1-git-send-email-jiaxin.wu@intel.com> References: <1500984765-8040-1-git-send-email-jiaxin.wu@intel.com> Subject: [edk2] [Patch 3/4] MdeModulePkg/UefiBootManagerLib: Support DNS device path description X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Ye Ting , Fu Siyuan , Wu Jiaxin MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Errors-To: edk2-devel-bounces@lists.01.org Sender: "edk2-devel" X-ZohoMail: RSF_4 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" This patch is to update UEFI Boot manager to support DNS device path for HTTP(S) network boot. Cc: Ye Ting Cc: Fu Siyuan Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Wu Jiaxin --- MdeModulePkg/Library/UefiBootManagerLib/BmBootDescription.c | 13 +++++++++= ++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/MdeModulePkg/Library/UefiBootManagerLib/BmBootDescription.c b/= MdeModulePkg/Library/UefiBootManagerLib/BmBootDescription.c index 6e69a15..7647bac 100644 --- a/MdeModulePkg/Library/UefiBootManagerLib/BmBootDescription.c +++ b/MdeModulePkg/Library/UefiBootManagerLib/BmBootDescription.c @@ -385,12 +385,12 @@ BmGetNetworkDescription ( // ....../Mac(...)[/Vlan(...)][/Wi-Fi(...)] // ....../Mac(...)[/Vlan(...)][/Wi-Fi(...)]/IPv4(...) // ....../Mac(...)[/Vlan(...)][/Wi-Fi(...)]/IPv6(...) // // The HTTP device path is like: - // ....../Mac(...)[/Vlan(...)][/Wi-Fi(...)]/IPv4(...)/Uri(...) - // ....../Mac(...)[/Vlan(...)][/Wi-Fi(...)]/IPv6(...)/Uri(...) + // ....../Mac(...)[/Vlan(...)][/Wi-Fi(...)]/IPv4(...)[/Dns(...)]/Uri(.= ..) + // ....../Mac(...)[/Vlan(...)][/Wi-Fi(...)]/IPv6(...)[/Dns(...)]/Uri(.= ..) // while (!IsDevicePathEnd (DevicePath) && ((DevicePathType (DevicePath) !=3D MESSAGING_DEVICE_PATH) || (DevicePathSubType (DevicePath) !=3D MSG_MAC_ADDR_DP)) ) { @@ -435,10 +435,19 @@ BmGetNetworkDescription ( Ip =3D DevicePath; DevicePath =3D NextDevicePathNode (DevicePath); } else { Ip =3D NULL; } + =20 + // + // Skip the optional DNS node + // + if ((DevicePathType (DevicePath) =3D=3D MESSAGING_DEVICE_PATH) && + (DevicePathSubType (DevicePath) =3D=3D MSG_DNS_DP) + ) { + DevicePath =3D NextDevicePathNode (DevicePath); + } =20 // // Locate the URI node // if ((DevicePathType (DevicePath) =3D=3D MESSAGING_DEVICE_PATH) && --=20 1.9.5.msysgit.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel