Lines Matching refs:entry
81 struct e820_entry *entry = &e820_table->entries[i]; in e820__mapped_any() local
83 if (type && entry->type != type) in e820__mapped_any()
85 if (entry->addr >= end || entry->addr + entry->size <= start) in e820__mapped_any()
105 struct e820_entry *entry = &e820_table->entries[i]; in __e820__mapped_all() local
107 if (type && entry->type != type) in __e820__mapped_all()
111 if (entry->addr >= end || entry->addr + entry->size <= start) in __e820__mapped_all()
118 if (entry->addr <= start) in __e820__mapped_all()
119 start = entry->addr + entry->size; in __e820__mapped_all()
126 return entry; in __e820__mapped_all()
145 struct e820_entry *entry = __e820__mapped_all(start, end, 0); in e820__get_entry_type() local
147 return entry ? entry->type : -EINVAL; in e820__get_entry_type()
265 struct e820_entry *entry; member
289 return (ap->addr != ap->entry->addr) - (bp->addr != bp->entry->addr); in cpcompare()
325 change_point[chg_idx++]->entry = &entries[i]; in e820__update_table()
327 change_point[chg_idx++]->entry = &entries[i]; in e820__update_table()
344 if (change_point[chg_idx]->addr == change_point[chg_idx]->entry->addr) { in e820__update_table()
346 overlap_list[overlap_entries++] = change_point[chg_idx]->entry; in e820__update_table()
350 if (overlap_list[i] == change_point[chg_idx]->entry) in e820__update_table()
394 struct boot_e820_entry *entry = entries; in __append_e820_table() local
397 u64 start = entry->addr; in __append_e820_table()
398 u64 size = entry->size; in __append_e820_table()
400 u32 type = entry->type; in __append_e820_table()
408 entry++; in __append_e820_table()
452 struct e820_entry *entry = &table->entries[i]; in __e820__range_update() local
456 if (entry->type != old_type) in __e820__range_update()
459 entry_end = entry->addr + entry->size; in __e820__range_update()
462 if (entry->addr >= start && entry_end <= end) { in __e820__range_update()
463 entry->type = new_type; in __e820__range_update()
464 real_updated_size += entry->size; in __e820__range_update()
469 if (entry->addr < start && entry_end > end) { in __e820__range_update()
471 __e820__range_add(table, end, entry_end - end, entry->type); in __e820__range_update()
472 entry->size = start - entry->addr; in __e820__range_update()
478 final_start = max(start, entry->addr); in __e820__range_update()
491 entry->size -= final_end - final_start; in __e820__range_update()
492 if (entry->addr < final_start) in __e820__range_update()
495 entry->addr = final_end; in __e820__range_update()
527 struct e820_entry *entry = &e820_table->entries[i]; in e820__range_remove() local
531 if (check_type && entry->type != old_type) in e820__range_remove()
534 entry_end = entry->addr + entry->size; in e820__range_remove()
537 if (entry->addr >= start && entry_end <= end) { in e820__range_remove()
538 real_removed_size += entry->size; in e820__range_remove()
539 memset(entry, 0, sizeof(*entry)); in e820__range_remove()
544 if (entry->addr < start && entry_end > end) { in e820__range_remove()
545 e820__range_add(end, entry_end - end, entry->type); in e820__range_remove()
546 entry->size = start - entry->addr; in e820__range_remove()
552 final_start = max(start, entry->addr); in e820__range_remove()
563 entry->size -= final_end - final_start; in e820__range_remove()
564 if (entry->addr < final_start) in e820__range_remove()
567 entry->addr = final_end; in e820__range_remove()
732 struct e820_entry *entry = &e820_table->entries[i]; in e820__register_nosave_regions() local
734 if (pfn < PFN_UP(entry->addr)) in e820__register_nosave_regions()
735 register_nosave_region(pfn, PFN_UP(entry->addr)); in e820__register_nosave_regions()
737 pfn = PFN_DOWN(entry->addr + entry->size); in e820__register_nosave_regions()
739 if (entry->type != E820_TYPE_RAM && entry->type != E820_TYPE_RESERVED_KERN) in e820__register_nosave_regions()
740 register_nosave_region(PFN_UP(entry->addr), pfn); in e820__register_nosave_regions()
757 struct e820_entry *entry = &e820_table->entries[i]; in e820__register_nvs_regions() local
759 if (entry->type == E820_TYPE_NVS) in e820__register_nvs_regions()
760 acpi_nvs_register(entry->addr, entry->size); in e820__register_nvs_regions()
810 struct e820_entry *entry = &e820_table->entries[i]; in e820_end_pfn() local
814 if (entry->type != type) in e820_end_pfn()
817 start_pfn = entry->addr >> PAGE_SHIFT; in e820_end_pfn()
818 end_pfn = (entry->addr + entry->size) >> PAGE_SHIFT; in e820_end_pfn()
995 static const char *__init e820_type_to_string(struct e820_entry *entry) in e820_type_to_string() argument
997 switch (entry->type) { in e820_type_to_string()
1010 static unsigned long __init e820_type_to_iomem_type(struct e820_entry *entry) in e820_type_to_iomem_type() argument
1012 switch (entry->type) { in e820_type_to_iomem_type()
1025 static unsigned long __init e820_type_to_iores_desc(struct e820_entry *entry) in e820_type_to_iores_desc() argument
1027 switch (entry->type) { in e820_type_to_iores_desc()
1081 struct e820_entry *entry = e820_table->entries + i; in e820__reserve_resources() local
1083 end = entry->addr + entry->size - 1; in e820__reserve_resources()
1088 res->start = entry->addr; in e820__reserve_resources()
1090 res->name = e820_type_to_string(entry); in e820__reserve_resources()
1091 res->flags = e820_type_to_iomem_type(entry); in e820__reserve_resources()
1092 res->desc = e820_type_to_iores_desc(entry); in e820__reserve_resources()
1099 if (do_mark_busy(entry->type, res)) { in e820__reserve_resources()
1108 struct e820_entry *entry = e820_table_firmware->entries + i; in e820__reserve_resources() local
1110 firmware_map_add_early(entry->addr, entry->addr + entry->size, e820_type_to_string(entry)); in e820__reserve_resources()
1152 struct e820_entry *entry = &e820_table->entries[i]; in e820__reserve_resources_late() local
1155 if (entry->type != E820_TYPE_RAM) in e820__reserve_resources_late()
1158 start = entry->addr + entry->size; in e820__reserve_resources_late()
1244 struct e820_entry *entry = &e820_table->entries[i]; in e820__memblock_setup() local
1246 end = entry->addr + entry->size; in e820__memblock_setup()
1250 if (entry->type != E820_TYPE_RAM && entry->type != E820_TYPE_RESERVED_KERN) in e820__memblock_setup()
1253 memblock_add(entry->addr, entry->size); in e820__memblock_setup()