Re: [patch 4/9 v3] efi: cleanup efi_enter_virtual_mode function

From: Borislav Petkov
Date: Thu Nov 21 2013 - 11:49:44 EST


On Thu, Nov 21, 2013 at 02:17:08PM +0800, dyoung@xxxxxxxxxx wrote:
> Add two small functions:
> efi_merge_regions and efi_map_regions, efi_enter_virtual_mode
> calls them instead of embedding two long for loop.
>
> v1->v2:
> refresh; coding style fixes.
>
> v2->v3:
> Toshi Kani:
> remove unused variable
> Matt: check return value of krealloc.
>
> Signed-off-by: Dave Young <dyoung@xxxxxxxxxx>

Same short comment nitpick as earlier :)

Otherwise:

Acked-by: Borislav Petkov <bp@xxxxxxx>

> ---
> arch/x86/platform/efi/efi.c | 109 ++++++++++++++++++++++++++------------------
> 1 file changed, 66 insertions(+), 43 deletions(-)
>
> --- efi.orig/arch/x86/platform/efi/efi.c
> +++ efi/arch/x86/platform/efi/efi.c

[ â ]

> @@ -837,6 +805,18 @@ void __init efi_enter_virtual_mode(void)
> prev_md = md;
>
> }
> +}
> +
> +/*
> + * Map efi memory ranges for runtime serivce and
> + * update new_memmap with virtual addresses.
> + */

Stretch comment to 80 cols:

/*
* Map efi memory ranges for runtime serivce and update new_memmap with virtual
* addresses.
*/

like it is customary for the rest of the file.

> +static void * __init efi_map_regions(int *count)
> +{
> + efi_memory_desc_t *md;
> + void *p, *new_memmap = NULL;
> + unsigned long size;
> + u64 end, systab;
>
> for (p = memmap.map; p < memmap.map_end; p += memmap.desc_size) {
> md = p;

--
Regards/Gruss,
Boris.

Sent from a fat crate under my desk. Formatting is fine.
--
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/