From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by mx.groups.io with SMTP id smtpd.web11.34578.1591634615012753343 for ; Mon, 08 Jun 2020 09:43:35 -0700 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: arm.com, ip: 217.140.110.172, mailfrom: ard.biesheuvel@arm.com) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 570B91FB; Mon, 8 Jun 2020 09:43:34 -0700 (PDT) Received: from [192.168.1.69] (unknown [10.37.8.184]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 4F91A3F73D; Mon, 8 Jun 2020 09:43:33 -0700 (PDT) Subject: Re: [edk2-platforms][PATCH 1/1] Platform/RaspberryPi: Revert don't connect all devices on an ordinary boot To: Pete Batard , devel@edk2.groups.io Cc: leif@nuviainc.com References: <20200608155159.8748-1-pete@akeo.ie> From: "Ard Biesheuvel" Message-ID: <5009d194-b701-b602-ba3a-dd32891173bd@arm.com> Date: Mon, 8 Jun 2020 18:43:27 +0200 User-Agent: Mozilla/5.0 (X11; Linux aarch64; rv:68.0) Gecko/20100101 Thunderbird/68.8.1 MIME-Version: 1.0 In-Reply-To: <20200608155159.8748-1-pete@akeo.ie> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit On 6/8/20 5:51 PM, Pete Batard wrote: > This reverts commit c8000ecccc83b728baf04ced2fedb870bc3bc1b3 on account > of USB keyboard devices not being detected until after the timeout to > enter the Setup menu or run the UEFI Shell has expired. > > The core of the issue is that, when EfiBootManagerConnectAll() is not > invoked, PCI bus scanning only starts after the BDS wait period has > elapsed, which effectively takes away the ability to use an USB device > to enact Boot Device Selection or interact with the Setup menu. > > Signed-off-by: Pete Batard Could we move the call to EfiEventGroupSignal (&gEfiEndOfDxeEventGroupGuid); to the start of PlatformBootManagerBeforeConsole() instead? > --- > Platform/RaspberryPi/Library/PlatformBootManagerLib/PlatformBm.c | 5 +++++ > 1 file changed, 5 insertions(+) > > diff --git a/Platform/RaspberryPi/Library/PlatformBootManagerLib/PlatformBm.c b/Platform/RaspberryPi/Library/PlatformBootManagerLib/PlatformBm.c > index 253614a646c1..2bd625ad7e7c 100644 > --- a/Platform/RaspberryPi/Library/PlatformBootManagerLib/PlatformBm.c > +++ b/Platform/RaspberryPi/Library/PlatformBootManagerLib/PlatformBm.c > @@ -655,6 +655,11 @@ PlatformBootManagerAfterConsole ( > Print (BOOT_PROMPT); > } > > + // > + // Connect the rest of the devices. > + // > + EfiBootManagerConnectAll (); > + > Status = gBS->LocateProtocol (&gEsrtManagementProtocolGuid, NULL, (VOID**)&EsrtManagement); > if (!EFI_ERROR (Status)) { > EsrtManagement->SyncEsrtFmp (); >