From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM01-BN3-obe.outbound.protection.outlook.com (mail-bn3nam01on070a.outbound.protection.outlook.com [IPv6:2a01:111:f400:fe41::70a]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 051901A1E56 for ; Wed, 31 Aug 2016 19:18:22 -0700 (PDT) Received: from CS1PR84MB0295.NAMPRD84.PROD.OUTLOOK.COM (10.162.190.26) by CS1PR84MB0296.NAMPRD84.PROD.OUTLOOK.COM (10.162.190.27) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA_P384) id 15.1.587.13; Thu, 1 Sep 2016 02:18:18 +0000 Received: from CS1PR84MB0295.NAMPRD84.PROD.OUTLOOK.COM ([10.162.190.26]) by CS1PR84MB0295.NAMPRD84.PROD.OUTLOOK.COM ([10.162.190.26]) with mapi id 15.01.0599.010; Thu, 1 Sep 2016 02:18:18 +0000 From: "Wang, Sunny (HPS SW)" To: Liming Gao , "edk2-devel@lists.01.org" CC: Ruiyu Ni , Eric Dong , "Wang, Sunny (HPS SW)" Thread-Topic: [edk2] [Patch] MdeModulePkg UefiBootManagerLib: Ignore BootManagerMenuApp from LoadFile Thread-Index: AQHSA2BwvljuzY6cF0SpYJRKgJvBFaBj5V/w Date: Thu, 1 Sep 2016 02:18:18 +0000 Message-ID: References: <1472631553-26232-1-git-send-email-liming.gao@intel.com> In-Reply-To: <1472631553-26232-1-git-send-email-liming.gao@intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=sunnywang@hpe.com; x-originating-ip: [15.211.131.5] x-ms-office365-filtering-correlation-id: 9542528b-856f-4763-8d50-08d3d20e3d43 x-microsoft-exchange-diagnostics: 1; CS1PR84MB0296; 6:ihbmYMrt/eRuv4ixpmcm4epxKcb8xooNlvHdDipI+y8pPt1Lt4Gz8L39VO7RrQDzvGmFvmm58+l4xjnDuRRR+mjfDqkNj9k9swcB+ijcxgjnYZngiAOYR+j9QxhMnNhLAy7PfnmwqKiZcBsZG/UnPKCTnb35+3xIHNoy40XZKpeemz8Mz+UJ8PhdAINM4M3PzsXGnypcvGAZw9hePMcBaWnKFlKJA935eYfWGlRIyolRiWT0JtXpUdJUWP0in6tJIBcRqGFVCQvymmw11b4ULtoSz/6sSP1Qd1LlokGoiTJQcvpUBn/wYSSurBgeUGa4CqURlG5UFW575GC6wg6VxQ==; 5:ddL9C3G+dFM+jiedGU78qBi5V3brSTMLy5kw8JagHXfcrlsG+7gokSbjPhc8uhG/ussIu3XsFVaYYuLYUpqri7F1JrJe/QIMxjTPIIwBHqa9voaRkixGx4PAJkkCY503q1CfffzBwSnXsjwZ7a5nIQ==; 24:z/Mprbhatx992oT9/BmGl9AzFIWOHMrl6SrmM2EMxc5vo5d15knl8aT2bpdMpKi7x20K1WnsEcYI9S0VcMNzX1dXZ8Vl/1C831bVWRqA5oE=; 7:Do176Q7K6IV4RqcdjZ+Ek2PmDc3Bj2Muh5i372l9oBTFbs1dq2v4ZKU6+cpNTVFuLy0MgJ7sRz86H0uMi1opUl+/6Fkb+vkRMUq7tUP7PFOmpBf/qggED2lM/ZFrmrpRy9wx3eAFMx6YrS66zsQJFk8uKytj8GlxTZLCZrNSkJQGaVqquAISybGsNf188Tm/RksSoGpUrarpRN+GU98cLM208u7xUvOXWGCcuzYm449F686cYOyuQTXEjW4zwyB9 x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:CS1PR84MB0296; x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(227479698468861)(162533806227266)(228905959029699); x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(6040176)(601004)(2401047)(8121501046)(5005006)(10201501046)(3002001)(6055026); SRVR:CS1PR84MB0296; BCL:0; PCL:0; RULEID:; SRVR:CS1PR84MB0296; x-forefront-prvs: 0052308DC6 x-forefront-antispam-report: SFV:NSPM; SFS:(10019020)(6009001)(7916002)(199003)(13464003)(189002)(377454003)(106116001)(105586002)(5001770100001)(99286002)(2501003)(92566002)(106356001)(2950100001)(15975445007)(77096005)(2900100001)(5660300001)(81156014)(8676002)(3846002)(586003)(189998001)(97736004)(102836003)(74316002)(6116002)(33656002)(81166006)(2906002)(68736007)(3280700002)(7736002)(7696003)(87936001)(76176999)(19580395003)(19580405001)(54356999)(50986999)(101416001)(66066001)(575784001)(86362001)(9686002)(11100500001)(7846002)(8936002)(4326007)(305945005)(10400500002)(122556002)(5002640100001)(3660700001); DIR:OUT; SFP:1102; SCL:1; SRVR:CS1PR84MB0296; H:CS1PR84MB0295.NAMPRD84.PROD.OUTLOOK.COM; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en; received-spf: None (protection.outlook.com: hpe.com does not designate permitted sender hosts) spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: hpe.com X-MS-Exchange-CrossTenant-originalarrivaltime: 01 Sep 2016 02:18:18.5741 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 105b2061-b669-4b31-92ac-24d304d195dc X-MS-Exchange-Transport-CrossTenantHeadersStamped: CS1PR84MB0296 Subject: Re: [Patch] MdeModulePkg UefiBootManagerLib: Ignore BootManagerMenuApp from LoadFile X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 01 Sep 2016 02:18:22 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hi Liming,=20 Except Ray's comment, others Look good to me.=20 Reviewed-by: Sunny Wang Hi Ray and Eric,=20 It looks like this code change is used for replacing the one which we offli= ne discussed to fix the duplicated Boot Manager menu issue, isn't it? =20 - [edk2] [Patch] MdeModulePkg UefiBootManagerLib: Add OptioalData for boot= option. Regards, Sunny Wang -----Original Message----- From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Limi= ng Gao Sent: Wednesday, August 31, 2016 4:19 PM To: edk2-devel@lists.01.org Cc: Ruiyu Ni ; Eric Dong Subject: [edk2] [Patch] MdeModulePkg UefiBootManagerLib: Ignore BootManager= MenuApp from LoadFile BootManagerMenuApp boot option is handled by EfiBootManagerGetBootManagerMe= nu. Don't need to handle it again when parse LoadFile protocol. Cc: Ruiyu Ni Cc: Eric Dong Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Liming Gao --- MdeModulePkg/Library/UefiBootManagerLib/BmBoot.c | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/MdeModulePkg/Library/UefiBootManagerLib/BmBoot.c b/MdeModulePk= g/Library/UefiBootManagerLib/BmBoot.c index ecd0ae3..f8a3988 100644 --- a/MdeModulePkg/Library/UefiBootManagerLib/BmBoot.c +++ b/MdeModulePkg/Library/UefiBootManagerLib/BmBoot.c @@ -1940,7 +1940,6 @@ BmEnumerateBootOptions ( UINTN Removable; UINTN Index; CHAR16 *Description; - UINT32 BootAttributes; =20 ASSERT (BootOptionCount !=3D NULL); =20 @@ -2070,6 +2069,12 @@ BmEnumerateBootOptions ( &Handles ); for (Index =3D 0; Index < HandleCount; Index++) { + // + // Ignore BootMenuApp. its boot option will be created by BmRegisterBo= otManagerMenu(). + // + if (BmIsBootMenuAppFilePath (DevicePathFromHandle (Handles[Index]))) { + continue; + } =20 Description =3D BmGetBootDescription (Handles[Index]); BootOptions =3D ReallocatePool ( @@ -2079,19 +2084,11 @@ BmEnumerateBootOptions ( ); ASSERT (BootOptions !=3D NULL); =20 - // - // If LoadFile includes BootMenuApp, its boot attribue will be set to = APP and HIDDEN. - // - BootAttributes =3D LOAD_OPTION_ACTIVE; - if (BmIsBootMenuAppFilePath (DevicePathFromHandle (Handles[Index]))) { - BootAttributes =3D LOAD_OPTION_CATEGORY_APP | LOAD_OPTION_ACTIVE | L= OAD_OPTION_HIDDEN; - } - Status =3D EfiBootManagerInitializeLoadOption ( &BootOptions[(*BootOptionCount)++], LoadOptionNumberUnassigned, LoadOptionTypeBoot, - BootAttributes, + LOAD_OPTION_ACTIVE, Description, DevicePathFromHandle (Handles[Index]), NULL, --=20 2.8.0.windows.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel