From: will.deacon@arm.com (Will Deacon)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v5 7/8] arm64/efi: remove free_boot_services() and friends
Date: Fri, 9 Jan 2015 15:49:24 +0000 [thread overview]
Message-ID: <20150109154924.GH11258@arm.com> (raw)
In-Reply-To: <1420742914-2404-8-git-send-email-ard.biesheuvel@linaro.org>
On Thu, Jan 08, 2015 at 06:48:33PM +0000, Ard Biesheuvel wrote:
> Now that we are calling SetVirtualAddressMap() from the stub, there is no
> need to reserve boot-only memory regions, which implies that there is also
> no reason to free them again later.
>
> Acked-by: Leif Lindholm <leif.lindholm@linaro.org>
> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
> ---
> arch/arm64/kernel/efi.c | 123 +-----------------------------------------------
> 1 file changed, 1 insertion(+), 122 deletions(-)
[...]
> -static void __init free_boot_services(void)
> -{
> - u64 total_freed = 0;
> - u64 keep_end, free_start, free_end;
> - efi_memory_desc_t *md;
> -
> - /*
> - * If kernel uses larger pages than UEFI, we have to be careful
> - * not to inadvertantly free memory we want to keep if there is
> - * overlap at the kernel page size alignment. We do not want to
> - * free is_reserve_region() memory nor the UEFI memmap itself.
> - *
> - * The memory map is sorted, so we keep track of the end of
> - * any previous region we want to keep, remember any region
> - * we want to free and defer freeing it until we encounter
> - * the next region we want to keep. This way, before freeing
> - * it, we can clip it as needed to avoid freeing memory we
> - * want to keep for UEFI.
> - */
> -
> - keep_end = 0;
> - free_start = 0;
> -
> - for_each_efi_memory_desc(&memmap, md) {
> - u64 paddr, npages, size;
I'm glad to see the back of this function, thanks.
Acked-by: Will Deacon <will.deacon@arm.com>
Will
next prev parent reply other threads:[~2015-01-09 15:49 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-08 18:48 [PATCH v5 0/8] arm64: stable UEFI virtual mappings for kexec Ard Biesheuvel
2015-01-08 18:48 ` [PATCH v5 1/8] arm64/mm: add explicit struct_mm argument to __create_mapping() Ard Biesheuvel
2015-01-08 18:48 ` [PATCH v5 2/8] arm64/mm: add create_pgd_mapping() to create private page tables Ard Biesheuvel
2015-01-08 18:48 ` [PATCH v5 3/8] efi: split off remapping code from efi_config_init() Ard Biesheuvel
2015-01-08 18:48 ` [PATCH v5 4/8] efi: efistub: allow allocation alignment larger than EFI_PAGE_SIZE Ard Biesheuvel
2015-01-08 18:48 ` [PATCH v5 5/8] arm64/efi: set EFI_ALLOC_ALIGN to 64 KB Ard Biesheuvel
2015-01-08 18:48 ` [PATCH v5 6/8] arm64/efi: move SetVirtualAddressMap() to UEFI stub Ard Biesheuvel
2015-01-09 16:41 ` Leif Lindholm
2015-01-12 11:46 ` Matt Fleming
2015-01-12 16:09 ` Ard Biesheuvel
2015-01-12 16:26 ` Matt Fleming
2015-01-08 18:48 ` [PATCH v5 7/8] arm64/efi: remove free_boot_services() and friends Ard Biesheuvel
2015-01-09 15:49 ` Will Deacon [this message]
2015-01-08 18:48 ` [PATCH v5 8/8] arm64/efi: remove idmap manipulations from UEFI code Ard Biesheuvel
2015-01-09 16:03 ` Will Deacon
2015-01-09 16:16 ` [PATCH v5 0/8] arm64: stable UEFI virtual mappings for kexec Leif Lindholm
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20150109154924.GH11258@arm.com \
--to=will.deacon@arm.com \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).