extern int e820_all_mapped(u64 start, u64 end, unsigned type);
extern void e820_add_region(u64 start, u64 size, int type);
extern void e820_print_map(char *who);
-extern int sanitize_e820_table(struct e820_entry *biosmap, int max_nr_map, u32 *pnr_map);
+extern int e820__update_table(struct e820_entry *biosmap, int max_nr_map, u32 *pnr_map);
extern u64 e820_update_range(u64 start, u64 size, unsigned old_type, unsigned new_type);
extern u64 e820_remove_range(u64 start, u64 size, unsigned old_type, int checktype);
extern void e820__update_table_print(void);
*
* This allows for bootstrap/firmware quirks such as possible duplicate
* E820 entries that might need room in the same arrays, prior to the
- * call to sanitize_e820_table() to remove duplicates. The allowance
+ * call to e820__update_table() to remove duplicates. The allowance
* of three memory map entries per node is "enough" entries for
* the initial hardware platform motivating this mechanism to make
* use of additional EFI map entries. Future platforms may want
* sanitizing succeeds the *pnr_map will be updated with the new
* number of valid entries (something no more than max_nr_map).
*
- * The return value from sanitize_e820_table() is zero if it
+ * The return value from e820__update_table() is zero if it
* successfully 'sanitized' the map entries passed in, and is -1
* if it did nothing, which can happen if either of (1) it was
* only passed one map entry, or (2) any of the input map entries
return (ap->addr != ap->pbios->addr) - (bp->addr != bp->pbios->addr);
}
-int __init sanitize_e820_table(struct e820_entry *biosmap, int max_nr_map, u32 *pnr_map)
+int __init e820__update_table(struct e820_entry *biosmap, int max_nr_map, u32 *pnr_map)
{
static struct change_member change_point_list[2*E820_X_MAX] __initdata;
static struct change_member *change_point[2*E820_X_MAX] __initdata;
void __init e820__update_table_print(void)
{
- if (sanitize_e820_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries))
+ if (e820__update_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries))
return;
pr_info("e820: modified physical RAM map:\n");
static void __init e820__update_table_firmware(void)
{
- sanitize_e820_table(e820_table_firmware->entries, ARRAY_SIZE(e820_table_firmware->entries), &e820_table_firmware->nr_entries);
+ e820__update_table(e820_table_firmware->entries, ARRAY_SIZE(e820_table_firmware->entries), &e820_table_firmware->nr_entries);
}
#define MAX_GAP_END 0x100000000ull
extmap = (struct e820_entry *)(sdata->data);
__append_e820_table(extmap, entries);
- sanitize_e820_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries);
+ e820__update_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries);
early_memunmap(sdata, data_len);
pr_info("e820: extended physical RAM map:\n");
early_memunmap(data, sizeof(*data));
}
- sanitize_e820_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries);
+ e820__update_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries);
memcpy(e820_table_firmware, e820_table, sizeof(struct e820_table));
printk(KERN_INFO "extended physical RAM map:\n");
e820_print_map("reserve setup_data");
void __init e820__finish_early_params(void)
{
if (userdef) {
- if (sanitize_e820_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries) < 0)
+ if (e820__update_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries) < 0)
early_panic("Invalid user supplied memory map");
pr_info("e820: user-defined physical RAM map:\n");
* the next section from 1mb->appropriate_mem_k
*/
new_nr = boot_params.e820_entries;
- sanitize_e820_table(boot_params.e820_table, ARRAY_SIZE(boot_params.e820_table), &new_nr);
+ e820__update_table(boot_params.e820_table, ARRAY_SIZE(boot_params.e820_table), &new_nr);
boot_params.e820_entries = new_nr;
if (append_e820_table(boot_params.e820_table, boot_params.e820_entries) < 0) {
/* Mark this space as reserved */
e820_add_region(base, size, E820_RESERVED);
- sanitize_e820_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries);
+ e820__update_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries);
}
static void __init intel_graphics_quirks(int num, int slot, int func)
*/
e820_remove_range(BIOS_BEGIN, BIOS_END - BIOS_BEGIN, E820_RAM, 1);
- sanitize_e820_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries);
+ e820__update_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries);
}
/* called before trim_bios_range() to spare extra sanitize */
if (ppro_with_ram_bug()) {
e820_update_range(0x70000000ULL, 0x40000ULL, E820_RAM,
E820_RESERVED);
- sanitize_e820_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries);
+ e820__update_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries);
printk(KERN_INFO "fixed physical RAM map:\n");
e820_print_map("bad_ppro");
}
}
e820_add_region(start, size, e820_type);
}
- sanitize_e820_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries);
+ e820__update_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries);
}
int __init efi_memblock_x86_reserve_range(void)
xen_ignore_unusable();
/* Make sure the Xen-supplied memory map is well-ordered. */
- sanitize_e820_table(xen_e820_table, ARRAY_SIZE(xen_e820_table),
+ e820__update_table(xen_e820_table, ARRAY_SIZE(xen_e820_table),
&xen_e820_table_entries);
max_pages = xen_get_max_pages();
e820_add_region(ISA_START_ADDRESS, ISA_END_ADDRESS - ISA_START_ADDRESS,
E820_RESERVED);
- sanitize_e820_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries);
+ e820__update_table(e820_table->entries, ARRAY_SIZE(e820_table->entries), &e820_table->nr_entries);
/*
* Check whether the kernel itself conflicts with the target E820 map.
xen_e820_table_entries = memmap.nr_entries;
- sanitize_e820_table(xen_e820_table, ARRAY_SIZE(xen_e820_table),
+ e820__update_table(xen_e820_table, ARRAY_SIZE(xen_e820_table),
&xen_e820_table_entries);
for (i = 0; i < xen_e820_table_entries; i++)