From mboxrd@z Thu Jan 1 00:00:00 1970 From: =?iso-8859-1?Q?Br=FCns=2C_Stefan?= Date: Thu, 27 Jul 2017 14:44:17 +0000 Subject: [U-Boot] [PATCH] efi_loader: fix bug in efi_get_memory_map In-Reply-To: References: <20170726183405.27841-1-robdclark@gmail.com> <8d8e2780-04cd-62fa-53f8-0684a563507f@suse.de> Message-ID: <4132452.iGmGEkvGJM@sbruens-linux> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable To: u-boot@lists.denx.de On Mittwoch, 26. Juli 2017 22:25:29 CEST Rob Clark wrote: > On Wed, Jul 26, 2017 at 4:10 PM, Alexander Graf wrote: > > On 26.07.17 20:34, Rob Clark wrote: > >> When booting shim -> fallback -> shim -> grub -> linux the memory map = is > >> a bit larger than the size linux passes in on the first call. But in > >> the EFI_BUFFER_TOO_SMALL case we were not passing back the updated size > >> to linux so it would loop forever. > >>=20 > >> Signed-off-by: Rob Clark > >=20 > > The spec is actually very explicit about this case. It says in the > > EFI_BUFFER_TOO_SMALL case, we *have* to return the map size. >=20 > yes, that is what I fixed. We *weren't* returning the required buffer > size before :-) Sigh, yes, this was correct in the first 3 versions of the patch series, bu= t=20 unfortunately broken in v4 which was actually committed ... See: https://lists.denx.de/pipermail/u-boot/2016-October/268766.html Actually, the map_size variable is no longer needed, if you assign to=20 *memory_map_size directly. Anyway, this patch is: Reviewed-by: Stefan Br=C3=BCns Kind regards, Stefan