]> git.baikalelectronics.ru Git - kernel.git/commit
efi: Make code to find mirrored memory ranges generic
authorMa Wupeng <mawupeng1@huawei.com>
Tue, 14 Jun 2022 09:21:52 +0000 (17:21 +0800)
committerArd Biesheuvel <ardb@kernel.org>
Wed, 15 Jun 2022 10:11:19 +0000 (12:11 +0200)
commit20b2292eae5adec3373bd8e7375e29e82723e6e2
tree38866d9dd01dbfe2d82b4eada37e356064f591d0
parentcf1710d1388cf5bd81996b258399c4907d27006e
efi: Make code to find mirrored memory ranges generic

Commit ac8ed90d54c0 ("x86, mirror: x86 enabling - find mirrored memory
ranges") introduce the efi_find_mirror() function on x86. In order to reuse
the API we make it public.

Arm64 can support mirrored memory too, so function efi_find_mirror() is added to
efi_init() to this support for arm64.

Since efi_init() is shared by ARM, arm64 and riscv, this patch will bring
mirror memory support for these architectures, but this support is only tested
in arm64.

Signed-off-by: Ma Wupeng <mawupeng1@huawei.com>
Link: https://lore.kernel.org/r/20220614092156.1972846-2-mawupeng1@huawei.com
[ardb: fix subject to better reflect the payload]
Acked-by: Mike Rapoport <rppt@linux.ibm.com>
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
arch/x86/include/asm/efi.h
arch/x86/platform/efi/efi.c
drivers/firmware/efi/efi-init.c
drivers/firmware/efi/efi.c
include/linux/efi.h