From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by mx.groups.io with SMTP id smtpd.web09.5206.1576632942484997355 for ; Tue, 17 Dec 2019 17:35:42 -0800 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: intel.com, ip: 134.134.136.24, mailfrom: nathaniel.l.desimone@intel.com) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga003.jf.intel.com ([10.7.209.27]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 17 Dec 2019 17:35:41 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.69,327,1571727600"; d="scan'208";a="217990664" Received: from orsmsx106.amr.corp.intel.com ([10.22.225.133]) by orsmga003.jf.intel.com with ESMTP; 17 Dec 2019 17:35:41 -0800 Received: from orsmsx122.amr.corp.intel.com (10.22.225.227) by ORSMSX106.amr.corp.intel.com (10.22.225.133) with Microsoft SMTP Server (TLS) id 14.3.439.0; Tue, 17 Dec 2019 17:35:41 -0800 Received: from orsmsx114.amr.corp.intel.com ([169.254.8.106]) by ORSMSX122.amr.corp.intel.com ([169.254.11.3]) with mapi id 14.03.0439.000; Tue, 17 Dec 2019 17:35:41 -0800 From: "Nate DeSimone" To: "Agyeman, Prince" CC: "devel@edk2.groups.io" , "Kubacki, Michael A" Subject: Re: [edk2-platforms] [PATCH 10/11] SimicsOpenBoardPkg: Add BDS Board Boot Manager library Thread-Topic: [edk2-platforms] [PATCH 10/11] SimicsOpenBoardPkg: Add BDS Board Boot Manager library Thread-Index: AQHVsh5lvdbiq1DXEkuG6wwWEqBg76e/qMgA Date: Wed, 18 Dec 2019 01:35:41 +0000 Message-ID: <20191218013540.GJ1930@nate-virtualbox> References: <6c40c7b6ebde73fcaa110be9ff55de3e58f7bb47.1576282834.git.prince.agyeman@intel.com> In-Reply-To: <6c40c7b6ebde73fcaa110be9ff55de3e58f7bb47.1576282834.git.prince.agyeman@intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.7.159.63] MIME-Version: 1.0 Return-Path: nathaniel.l.desimone@intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-ID: <25D4B9E91164D5448A9705EF18B00F55@intel.com> Content-Transfer-Encoding: quoted-printable Hi Prince, Reviewed-by: Nate DeSimone Thanks, Nate On Sat, Dec 14, 2019 at 01:32:36AM +0000, Agyeman, Prince wrote: > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2336 >=20 > This library implements PlatformBootManagerWaitCallback > and PlatformBootManagerUnableToBoot which can be linked Minplatform's > PlatformBootManager libary instance. >=20 > Cc: Nate DeSimone > Cc: Michael Kubacki >=20 > Signed-off-by: Prince Agyeman > --- > .../BoardBootManagerLib/BoardBootManager.c | 67 +++++++++++++++++++ > .../BoardBootManagerLib.inf | 45 +++++++++++++ > 2 files changed, 112 insertions(+) > create mode 100644 Platform/Intel/SimicsOpenBoardPkg/Library/BoardBootMa= nagerLib/BoardBootManager.c > create mode 100644 Platform/Intel/SimicsOpenBoardPkg/Library/BoardBootMa= nagerLib/BoardBootManagerLib.inf >=20 > diff --git a/Platform/Intel/SimicsOpenBoardPkg/Library/BoardBootManagerLi= b/BoardBootManager.c b/Platform/Intel/SimicsOpenBoardPkg/Library/BoardBootM= anagerLib/BoardBootManager.c > new file mode 100644 > index 0000000000..58035f2766 > --- /dev/null > +++ b/Platform/Intel/SimicsOpenBoardPkg/Library/BoardBootManagerLib/Board= BootManager.c > @@ -0,0 +1,67 @@ > +/** @file > + The Board Boot Manager Library implements BoardBootManagerWaitCallback > + and BoardBootManagerUnableToBoot callback, which is linked to the > + Platform Boot Manager Library > + > + Copyright (c) 2019 Intel Corporation. All rights reserved.
> + > + SPDX-License-Identifier: BSD-2-Clause-Patent > +**/ > + > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > + > +/** > + This function is called each second during the boot manager waits the > + timeout. > + > + @param TimeoutRemain The remaining timeout. > +**/ > +VOID > +EFIAPI > +BoardBootManagerWaitCallback ( > + UINT16 TimeoutRemain > + ) > +{ > + EFI_GRAPHICS_OUTPUT_BLT_PIXEL_UNION Black; > + EFI_GRAPHICS_OUTPUT_BLT_PIXEL_UNION White; > + UINT16 Timeout; > + > + Timeout =3D PcdGet16 (PcdPlatformBootTimeOut); > + > + Black.Raw =3D 0x00000000; > + White.Raw =3D 0x00FFFFFF; > + > + BootLogoUpdateProgress ( > + White.Pixel, > + Black.Pixel, > + L"Start boot option", > + White.Pixel, > + (Timeout - TimeoutRemain) * 100 / Timeout, > + 0 > + ); > +} > + > +/** > + The function is called when no boot option could be launched, > + including platform recovery options and options pointing to applicatio= ns > + built into firmware volumes. > + > + If this function returns, BDS attempts to enter an infinite loop. > +**/ > +VOID > +EFIAPI > +BoardBootManagerUnableToBoot ( > + VOID > + ) > +{ > + > +} > diff --git a/Platform/Intel/SimicsOpenBoardPkg/Library/BoardBootManagerLi= b/BoardBootManagerLib.inf b/Platform/Intel/SimicsOpenBoardPkg/Library/Board= BootManagerLib/BoardBootManagerLib.inf > new file mode 100644 > index 0000000000..20778981bc > --- /dev/null > +++ b/Platform/Intel/SimicsOpenBoardPkg/Library/BoardBootManagerLib/Board= BootManagerLib.inf > @@ -0,0 +1,45 @@ > +## @file > +# Definition file for the Board Boot Manager Library. > +# > +# Copyright (c) 2019 Intel Corporation. All rights reserved.
> +# > +# SPDX-License-Identifier: BSD-2-Clause-Patent > +# > +## > + > +[Defines] > + INF_VERSION =3D 0x00010005 > + BASE_NAME =3D BoardBootManagerLib > + FILE_GUID =3D EBBB176A-3883-4BA4-A74D-1510D0C35B3= 7 > + MODULE_TYPE =3D DXE_DRIVER > + VERSION_STRING =3D 1.0 > + LIBRARY_CLASS =3D BoardBootManagerLib|DXE_DRIVER > + > +# > +# The following information is for reference only and not required by th= e build tools. > +# > +# VALID_ARCHITECTURES =3D IA32 X64 EBC > +# > + > +[Sources] > + BoardBootManager.c > + > +[Packages] > + MdePkg/MdePkg.dec > + MdeModulePkg/MdeModulePkg.dec > + MinPlatformPkg/MinPlatformPkg.dec > + > +[LibraryClasses] > + BaseLib > + UefiBootServicesTableLib > + DebugLib > + UefiLib > + HobLib > + UefiBootManagerLib > + TimerLib > + BoardBootManagerLib > + BootLogoLib > + PcdLib > + > +[Pcd] > + gEfiMdePkgTokenSpaceGuid.PcdPlatformBootTimeOut > --=20 > 2.19.1.windows.1 > =