summaryrefslogtreecommitdiffstats
path: root/arch/x86/platform
diff options
context:
space:
mode:
authorIngo Molnar <mingo@kernel.org>2017-01-28 17:09:33 +0100
committerIngo Molnar <mingo@kernel.org>2017-01-28 22:55:22 +0100
commit09821ff1d50a1ecade182c2a68a90f835e257eef (patch)
tree040a51657852db7300a8ebf2acb8a838252ce1bf /arch/x86/platform
parent6afc03b86470f602d118825d09addfeeaef535f0 (diff)
downloadop-kernel-dev-09821ff1d50a1ecade182c2a68a90f835e257eef.zip
op-kernel-dev-09821ff1d50a1ecade182c2a68a90f835e257eef.tar.gz
x86/boot/e820: Prefix the E820_* type names with "E820_TYPE_"
So there's a number of constants that start with "E820" but which are not types - these create a confusing mixture when seen together with 'enum e820_type' values: E820MAP E820NR E820_X_MAX E820MAX To better differentiate the 'enum e820_type' values prefix them with E820_TYPE_. No change in functionality. Cc: Alex Thorlton <athorlton@sgi.com> Cc: Andy Lutomirski <luto@kernel.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dan Williams <dan.j.williams@intel.com> Cc: Denys Vlasenko <dvlasenk@redhat.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Huang, Ying <ying.huang@intel.com> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Juergen Gross <jgross@suse.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Paul Jackson <pj@sgi.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Rafael J. Wysocki <rjw@sisk.pl> Cc: Tejun Heo <tj@kernel.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Wei Yang <richard.weiyang@gmail.com> Cc: Yinghai Lu <yinghai@kernel.org> Cc: linux-kernel@vger.kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'arch/x86/platform')
-rw-r--r--arch/x86/platform/efi/efi.c14
-rw-r--r--arch/x86/platform/efi/quirks.c6
2 files changed, 10 insertions, 10 deletions
diff --git a/arch/x86/platform/efi/efi.c b/arch/x86/platform/efi/efi.c
index d97c05e..14d0a6b 100644
--- a/arch/x86/platform/efi/efi.c
+++ b/arch/x86/platform/efi/efi.c
@@ -140,21 +140,21 @@ static void __init do_add_efi_memmap(void)
case EFI_BOOT_SERVICES_DATA:
case EFI_CONVENTIONAL_MEMORY:
if (md->attribute & EFI_MEMORY_WB)
- e820_type = E820_RAM;
+ e820_type = E820_TYPE_RAM;
else
- e820_type = E820_RESERVED;
+ e820_type = E820_TYPE_RESERVED;
break;
case EFI_ACPI_RECLAIM_MEMORY:
- e820_type = E820_ACPI;
+ e820_type = E820_TYPE_ACPI;
break;
case EFI_ACPI_MEMORY_NVS:
- e820_type = E820_NVS;
+ e820_type = E820_TYPE_NVS;
break;
case EFI_UNUSABLE_MEMORY:
- e820_type = E820_UNUSABLE;
+ e820_type = E820_TYPE_UNUSABLE;
break;
case EFI_PERSISTENT_MEMORY:
- e820_type = E820_PMEM;
+ e820_type = E820_TYPE_PMEM;
break;
default:
/*
@@ -162,7 +162,7 @@ static void __init do_add_efi_memmap(void)
* EFI_RUNTIME_SERVICES_DATA EFI_MEMORY_MAPPED_IO
* EFI_MEMORY_MAPPED_IO_PORT_SPACE EFI_PAL_CODE
*/
- e820_type = E820_RESERVED;
+ e820_type = E820_TYPE_RESERVED;
break;
}
e820__range_add(start, size, e820_type);
diff --git a/arch/x86/platform/efi/quirks.c b/arch/x86/platform/efi/quirks.c
index d4acd16..3c8d8e5 100644
--- a/arch/x86/platform/efi/quirks.c
+++ b/arch/x86/platform/efi/quirks.c
@@ -242,14 +242,14 @@ void __init efi_arch_mem_reserve(phys_addr_t addr, u64 size)
* else. We must only reserve (and then free) regions:
*
* - Not within any part of the kernel
- * - Not the BIOS reserved area (E820_RESERVED, E820_NVS, etc)
+ * - Not the BIOS reserved area (E820_TYPE_RESERVED, E820_TYPE_NVS, etc)
*/
static bool can_free_region(u64 start, u64 size)
{
if (start + size > __pa_symbol(_text) && start <= __pa_symbol(_end))
return false;
- if (!e820__mapped_all(start, start+size, E820_RAM))
+ if (!e820__mapped_all(start, start+size, E820_TYPE_RAM))
return false;
return true;
@@ -282,7 +282,7 @@ void __init efi_reserve_boot_services(void)
* A good example of a critical region that must not be
* freed is page zero (first 4Kb of memory), which may
* contain boot services code/data but is marked
- * E820_RESERVED by trim_bios_range().
+ * E820_TYPE_RESERVED by trim_bios_range().
*/
if (!already_reserved) {
memblock_reserve(start, size);
OpenPOWER on IntegriCloud