grub-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [patch] arm64: set correct length of device path end entry


From: Vladimir 'φ-coder/phcoder' Serbinenko
Subject: Re: [patch] arm64: set correct length of device path end entry
Date: Tue, 07 Jan 2014 18:11:51 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20131103 Icedove/17.0.10

On 07.01.2014 18:06, Leif Lindholm wrote:
> The length of the Device Path End entry in the grub_linux_boot()
> funtcion is incorrectly set to 0. This triggers an assert failure
> in debug builds of Tianocore.
> 
> The correct length is 4 bytes (1 byte type, 1 byte subtype,
> 2 bytes length).
> 
> Reported-by: Mark Salter <address@hidden>
> 
> diff --git a/grub-core/loader/arm64/linux.c b/grub-core/loader/arm64/linux.c
> index 9d15aad..7c9bc2b 100644
> --- a/grub-core/loader/arm64/linux.c
> +++ b/grub-core/loader/arm64/linux.c
> @@ -268,7 +268,7 @@ grub_linux_boot (void)
>  
>    mempath[1].header.type = GRUB_EFI_END_DEVICE_PATH_TYPE;
>    mempath[1].header.subtype = GRUB_EFI_END_ENTIRE_DEVICE_PATH_SUBTYPE;
> -  mempath[1].header.length = 0;
> +  mempath[1].header.length = 4;
> 
Could you use sizeof ?

>    b = grub_efi_system_table->boot_services;
>    status = b->load_image (0, grub_efi_image_handle,
> 
> 
> _______________________________________________
> Grub-devel mailing list
> address@hidden
> https://lists.gnu.org/mailman/listinfo/grub-devel
> 


Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]