Searched refs:altmap (Results 1 - 24 of 24) sorted by relevance

/linux-master/mm/
H A Dsparse-vmemmap.c74 struct vmem_altmap *altmap);
78 struct vmem_altmap *altmap)
82 if (altmap)
83 return altmap_alloc_block_buf(size, altmap);
91 static unsigned long __meminit vmem_altmap_next_pfn(struct vmem_altmap *altmap) argument
93 return altmap->base_pfn + altmap->reserve + altmap->alloc
94 + altmap->align;
97 static unsigned long __meminit vmem_altmap_nr_free(struct vmem_altmap *altmap) argument
77 vmemmap_alloc_block_buf(unsigned long size, int node, struct vmem_altmap *altmap) argument
106 altmap_alloc_block_buf(unsigned long size, struct vmem_altmap *altmap) argument
144 vmemmap_pte_populate(pmd_t *pmd, unsigned long addr, int node, struct vmem_altmap *altmap, struct page *reuse) argument
245 vmemmap_populate_address(unsigned long addr, int node, struct vmem_altmap *altmap, struct page *reuse) argument
275 vmemmap_populate_range(unsigned long start, unsigned long end, int node, struct vmem_altmap *altmap, struct page *reuse) argument
292 vmemmap_populate_basepages(unsigned long start, unsigned long end, int node, struct vmem_altmap *altmap) argument
309 vmemmap_populate_hugepages(unsigned long start, unsigned long end, int node, struct vmem_altmap *altmap) argument
452 __populate_section_memmap(unsigned long pfn, unsigned long nr_pages, int nid, struct vmem_altmap *altmap, struct dev_pagemap *pgmap) argument
[all...]
H A Dsparse.c429 unsigned long nr_pages, int nid, struct vmem_altmap *altmap,
634 unsigned long nr_pages, int nid, struct vmem_altmap *altmap,
637 return __populate_section_memmap(pfn, nr_pages, nid, altmap, pgmap);
641 struct vmem_altmap *altmap)
646 vmemmap_free(start, end, altmap);
706 unsigned long nr_pages, int nid, struct vmem_altmap *altmap,
714 struct vmem_altmap *altmap)
782 struct vmem_altmap *altmap)
822 depopulate_section_memmap(pfn, nr_pages, altmap);
831 unsigned long nr_pages, struct vmem_altmap *altmap,
428 __populate_section_memmap(unsigned long pfn, unsigned long nr_pages, int nid, struct vmem_altmap *altmap, struct dev_pagemap *pgmap) argument
633 populate_section_memmap(unsigned long pfn, unsigned long nr_pages, int nid, struct vmem_altmap *altmap, struct dev_pagemap *pgmap) argument
640 depopulate_section_memmap(unsigned long pfn, unsigned long nr_pages, struct vmem_altmap *altmap) argument
705 populate_section_memmap(unsigned long pfn, unsigned long nr_pages, int nid, struct vmem_altmap *altmap, struct dev_pagemap *pgmap) argument
713 depopulate_section_memmap(unsigned long pfn, unsigned long nr_pages, struct vmem_altmap *altmap) argument
781 section_deactivate(unsigned long pfn, unsigned long nr_pages, struct vmem_altmap *altmap) argument
830 section_activate(int nid, unsigned long pfn, unsigned long nr_pages, struct vmem_altmap *altmap, struct dev_pagemap *pgmap) argument
892 sparse_add_section(int nid, unsigned long start_pfn, unsigned long nr_pages, struct vmem_altmap *altmap, struct dev_pagemap *pgmap) argument
928 sparse_remove_section(unsigned long pfn, unsigned long nr_pages, struct vmem_altmap *altmap) argument
[all...]
H A Dmemory_hotplug.c375 struct vmem_altmap *altmap = params->altmap; local
382 if (altmap) {
384 * Validate altmap is within bounds of the total request
386 if (altmap->base_pfn != pfn
387 || vmem_altmap_offset(altmap) > nr_pages) {
388 pr_warn_once("memory add fail, invalid altmap\n");
391 altmap->alloc = 0;
403 err = sparse_add_section(nid, pfn, cur_nr_pages, altmap,
566 * @altmap
573 __remove_pages(unsigned long pfn, unsigned long nr_pages, struct vmem_altmap *altmap) argument
750 move_pfn_range_to_zone(struct zone *zone, unsigned long start_pfn, unsigned long nr_pages, struct vmem_altmap *altmap, int migratetype) argument
1401 struct vmem_altmap *altmap = NULL; local
[all...]
H A Dmm_init.c853 struct vmem_altmap *altmap, int migratetype)
870 if (!altmap)
873 if (start_pfn == altmap->base_pfn)
874 start_pfn += altmap->reserve;
875 end_pfn = altmap->base_pfn + vmem_altmap_offset(altmap);
1027 * of an altmap. See vmemmap_populate_compound_pages().
1029 static inline unsigned long compound_nr_pages(struct vmem_altmap *altmap, argument
1032 if (!vmemmap_can_optimize(altmap, pgmap))
1072 struct vmem_altmap *altmap local
850 memmap_init_range(unsigned long size, int nid, unsigned long zone, unsigned long start_pfn, unsigned long zone_end_pfn, enum meminit_context context, struct vmem_altmap *altmap, int migratetype) argument
[all...]
H A Dmemremap.c153 WARN_ONCE(pgmap->altmap.alloc, "failed to free all reserved pages\n");
179 "altmap not supported for multiple ranges\n"))
256 PHYS_PFN(range_len(range)), params->altmap,
295 .altmap = pgmap_altmap(pgmap),
392 * 2/ The altmap field may optionally be initialized, in which case
/linux-master/arch/powerpc/mm/
H A Dinit_64.c187 bool altmap_cross_boundary(struct vmem_altmap *altmap, unsigned long start, argument
193 if ((start_pfn + nr_pfn - 1) > altmap->end_pfn)
196 if (start_pfn < altmap->base_pfn)
203 struct vmem_altmap *altmap)
227 * Allocate from the altmap first if we have one. This may
229 * fall back to system memory if the altmap allocation fail.
231 if (altmap && !altmap_cross_boundary(altmap, start, page_size)) {
232 p = vmemmap_alloc_block_buf(page_size, node, altmap);
234 pr_debug("altmap bloc
202 __vmemmap_populate(unsigned long start, unsigned long end, int node, struct vmem_altmap *altmap) argument
276 vmemmap_populate(unsigned long start, unsigned long end, int node, struct vmem_altmap *altmap) argument
319 __vmemmap_free(unsigned long start, unsigned long end, struct vmem_altmap *altmap) argument
378 vmemmap_free(unsigned long start, unsigned long end, struct vmem_altmap *altmap) argument
[all...]
H A Dmem.c160 void __ref arch_remove_memory(u64 start, u64 size, struct vmem_altmap *altmap) argument
165 __remove_pages(start_pfn, nr_pages, altmap);
/linux-master/arch/s390/mm/
H A Dvmem.c39 static void vmem_free_pages(unsigned long addr, int order, struct vmem_altmap *altmap) argument
41 if (altmap) {
42 vmem_altmap_free(altmap, 1 << order);
167 struct vmem_altmap *altmap)
183 vmem_free_pages((unsigned long)pfn_to_virt(pte_pfn(*pte)), get_order(PAGE_SIZE), altmap);
187 void *new_page = vmemmap_alloc_block_buf(PAGE_SIZE, NUMA_NO_NODE, altmap);
225 struct vmem_altmap *altmap)
246 vmem_free_pages(pmd_deref(*pmd), get_order(PMD_SIZE), altmap);
250 vmem_free_pages(pmd_deref(*pmd), get_order(PMD_SIZE), altmap);
273 new_page = vmemmap_alloc_block_buf(PMD_SIZE, NUMA_NO_NODE, altmap);
165 modify_pte_table(pmd_t *pmd, unsigned long addr, unsigned long end, bool add, bool direct, struct vmem_altmap *altmap) argument
223 modify_pmd_table(pud_t *pud, unsigned long addr, unsigned long end, bool add, bool direct, struct vmem_altmap *altmap) argument
318 modify_pud_table(p4d_t *p4d, unsigned long addr, unsigned long end, bool add, bool direct, struct vmem_altmap *altmap) argument
386 modify_p4d_table(pgd_t *pgd, unsigned long addr, unsigned long end, bool add, bool direct, struct vmem_altmap *altmap) argument
431 modify_pagetable(unsigned long start, unsigned long end, bool add, bool direct, struct vmem_altmap *altmap) argument
470 add_pagetable(unsigned long start, unsigned long end, bool direct, struct vmem_altmap *altmap) argument
476 remove_pagetable(unsigned long start, unsigned long end, bool direct, struct vmem_altmap *altmap) argument
503 vmemmap_populate(unsigned long start, unsigned long end, int node, struct vmem_altmap *altmap) argument
519 vmemmap_free(unsigned long start, unsigned long end, struct vmem_altmap *altmap) argument
[all...]
H A Dinit.c297 void arch_remove_memory(u64 start, u64 size, struct vmem_altmap *altmap) argument
302 __remove_pages(start_pfn, nr_pages, altmap);
/linux-master/arch/powerpc/mm/book3s64/
H A Dradix_pgtable.c691 struct vmem_altmap *altmap,
696 if (altmap) {
703 * used altmap.
705 alt_start = altmap->base_pfn;
706 alt_end = altmap->base_pfn + altmap->reserve + altmap->free;
709 vmem_altmap_free(altmap, nr_pages);
724 struct vmem_altmap *altmap)
740 free_vmemmap_pages(pte_page(*pte), altmap,
690 free_vmemmap_pages(struct page *page, struct vmem_altmap *altmap, int order) argument
722 remove_pte_table(pte_t *pte_start, unsigned long addr, unsigned long end, bool direct, struct vmem_altmap *altmap) argument
755 remove_pmd_table(pmd_t *pmd_start, unsigned long addr, unsigned long end, bool direct, struct vmem_altmap *altmap) argument
795 remove_pud_table(pud_t *pud_start, unsigned long addr, unsigned long end, bool direct, struct vmem_altmap *altmap) argument
830 remove_pagetable(unsigned long start, unsigned long end, bool direct, struct vmem_altmap *altmap) argument
916 vmemmap_can_optimize(struct vmem_altmap *altmap, struct dev_pagemap *pgmap) argument
949 radix__vmemmap_pte_populate(pmd_t *pmdp, unsigned long addr, int node, struct vmem_altmap *altmap, struct page *reuse) argument
1048 radix__vmemmap_populate(unsigned long start, unsigned long end, int node, struct vmem_altmap *altmap) argument
1134 radix__vmemmap_populate_address(unsigned long addr, int node, struct vmem_altmap *altmap, struct page *reuse) argument
1334 radix__vmemmap_free(unsigned long start, unsigned long end, struct vmem_altmap *altmap) argument
[all...]
/linux-master/include/linux/
H A Dmemory.h80 struct vmem_altmap *altmap; member in struct:memory_block
105 * specifying the altmap range and are exclusively intended for use in
156 struct vmem_altmap *altmap,
H A Dmemory_hotplug.h115 * because the altmap cannot be written (e.g., poisoned) when adding
118 * This allows for adding memory with an altmap that is not currently
128 * altmap: alternative allocator for memmap array (optional)
133 struct vmem_altmap *altmap; member in struct:mhp_params
204 extern void arch_remove_memory(u64 start, u64 size, struct vmem_altmap *altmap);
206 struct vmem_altmap *altmap);
364 struct vmem_altmap *altmap, int migratetype);
369 unsigned long nr_pages, struct vmem_altmap *altmap,
372 struct vmem_altmap *altmap);
H A Dmemremap.h109 * @altmap: pre-allocated/reserved memory for vmemmap allocations
128 struct vmem_altmap altmap; member in struct:dev_pagemap
151 return &pgmap->altmap;
H A Dmm.h3922 unsigned long nr_pages, int nid, struct vmem_altmap *altmap,
3931 struct vmem_altmap *altmap, struct page *reuse);
3935 struct vmem_altmap *altmap);
3942 int node, struct vmem_altmap *altmap);
3944 int node, struct vmem_altmap *altmap);
3946 struct vmem_altmap *altmap);
3950 struct vmem_altmap *altmap);
3954 static inline unsigned long vmem_altmap_offset(struct vmem_altmap *altmap) argument
3957 if (altmap)
3958 return altmap
3962 vmem_altmap_free(struct vmem_altmap *altmap, unsigned long nr_pfns) argument
3968 vmem_altmap_offset(struct vmem_altmap *altmap) argument
3973 vmem_altmap_free(struct vmem_altmap *altmap, unsigned long nr_pfns) argument
3981 __vmemmap_can_optimize(struct vmem_altmap *altmap, struct dev_pagemap *pgmap) argument
4006 vmemmap_can_optimize(struct vmem_altmap *altmap, struct dev_pagemap *pgmap) argument
[all...]
/linux-master/arch/loongarch/mm/
H A Dinit.c109 void arch_remove_memory(u64 start, u64 size, struct vmem_altmap *altmap) argument
115 /* With altmap the first mapped page is offset from @start */
116 if (altmap)
117 page += vmem_altmap_offset(altmap);
118 __remove_pages(start_pfn, nr_pages, altmap);
153 int node, struct vmem_altmap *altmap)
163 void vmemmap_free(unsigned long start, unsigned long end, struct vmem_altmap *altmap) argument
152 vmemmap_populate(unsigned long start, unsigned long end, int node, struct vmem_altmap *altmap) argument
/linux-master/arch/arm64/mm/
H A Dmmu.c818 struct vmem_altmap *altmap)
820 if (altmap) {
821 vmem_altmap_free(altmap, size >> PAGE_SHIFT);
854 struct vmem_altmap *altmap)
869 PAGE_SIZE, altmap); local
875 struct vmem_altmap *altmap)
898 PMD_SIZE, altmap); local
902 unmap_hotplug_pte_range(pmdp, addr, next, free_mapped, altmap);
908 struct vmem_altmap *altmap)
931 PUD_SIZE, altmap); local
817 free_hotplug_page_range(struct page *page, size_t size, struct vmem_altmap *altmap) argument
852 unmap_hotplug_pte_range(pmd_t *pmdp, unsigned long addr, unsigned long end, bool free_mapped, struct vmem_altmap *altmap) argument
873 unmap_hotplug_pmd_range(pud_t *pudp, unsigned long addr, unsigned long end, bool free_mapped, struct vmem_altmap *altmap) argument
906 unmap_hotplug_pud_range(p4d_t *p4dp, unsigned long addr, unsigned long end, bool free_mapped, struct vmem_altmap *altmap) argument
939 unmap_hotplug_p4d_range(pgd_t *pgdp, unsigned long addr, unsigned long end, bool free_mapped, struct vmem_altmap *altmap) argument
958 unmap_hotplug_range(unsigned long addr, unsigned long end, bool free_mapped, struct vmem_altmap *altmap) argument
1173 vmemmap_populate(unsigned long start, unsigned long end, int node, struct vmem_altmap *altmap) argument
1185 vmemmap_free(unsigned long start, unsigned long end, struct vmem_altmap *altmap) argument
1365 arch_remove_memory(u64 start, u64 size, struct vmem_altmap *altmap) argument
[all...]
/linux-master/arch/x86/mm/
H A Dinit_64.c997 struct vmem_altmap *altmap)
999 if (altmap)
1000 vmem_altmap_free(altmap, PMD_SIZE / PAGE_SIZE);
1104 bool direct, struct vmem_altmap *altmap)
1122 altmap);
1132 altmap);
1153 struct vmem_altmap *altmap, bool direct)
1177 remove_pmd_table(pmd_base, addr, next, direct, altmap);
1187 struct vmem_altmap *altmap, bool direct)
1203 remove_pud_table(pud_base, addr, next, altmap, direc
996 free_hugepage_table(struct page *page, struct vmem_altmap *altmap) argument
1103 remove_pmd_table(pmd_t *pmd_start, unsigned long addr, unsigned long end, bool direct, struct vmem_altmap *altmap) argument
1152 remove_pud_table(pud_t *pud_start, unsigned long addr, unsigned long end, struct vmem_altmap *altmap, bool direct) argument
1186 remove_p4d_table(p4d_t *p4d_start, unsigned long addr, unsigned long end, struct vmem_altmap *altmap, bool direct) argument
1219 remove_pagetable(unsigned long start, unsigned long end, bool direct, struct vmem_altmap *altmap) argument
1241 vmemmap_free(unsigned long start, unsigned long end, struct vmem_altmap *altmap) argument
1259 arch_remove_memory(u64 start, u64 size, struct vmem_altmap *altmap) argument
1533 vmemmap_populate(unsigned long start, unsigned long end, int node, struct vmem_altmap *altmap) argument
[all...]
/linux-master/drivers/base/
H A Dmemory.c108 /* Verify that the altmap is freed */
109 WARN_ON(mem->altmap);
208 if (mem->altmap)
209 nr_vmemmap_pages = mem->altmap->free;
223 zone, mem->altmap->inaccessible);
272 if (mem->altmap)
273 nr_vmemmap_pages = mem->altmap->free;
779 struct vmem_altmap *altmap,
797 mem->altmap = altmap;
778 add_memory_block(unsigned long block_id, unsigned long state, struct vmem_altmap *altmap, struct memory_group *group) argument
839 add_hotplug_memory_block(unsigned long block_id, struct vmem_altmap *altmap, struct memory_group *group) argument
870 create_memory_block_devices(unsigned long start, unsigned long size, struct vmem_altmap *altmap, struct memory_group *group) argument
[all...]
/linux-master/arch/powerpc/include/asm/book3s/64/
H A Dradix.h334 int node, struct vmem_altmap *altmap);
336 struct vmem_altmap *altmap);
367 bool vmemmap_can_optimize(struct vmem_altmap *altmap, struct dev_pagemap *pgmap);
/linux-master/arch/powerpc/include/asm/
H A Dpgtable.h189 bool altmap_cross_boundary(struct vmem_altmap *altmap, unsigned long start,
195 * alignment requirement is met using altmap->reserve blocks.
/linux-master/arch/sh/mm/
H A Dinit.c418 void arch_remove_memory(u64 start, u64 size, struct vmem_altmap *altmap) argument
423 __remove_pages(start_pfn, nr_pages, altmap);
/linux-master/drivers/nvdimm/
H A Dpfn_devs.c685 struct vmem_altmap *altmap = &pgmap->altmap; local
717 memcpy(altmap, &__altmap, sizeof(*altmap));
718 altmap->free = PHYS_PFN(offset - reserve);
719 altmap->alloc = 0;
789 * The altmap should be padded out to the block size used
/linux-master/arch/riscv/mm/
H A Dinit.c1433 struct vmem_altmap *altmap)
1432 vmemmap_populate(unsigned long start, unsigned long end, int node, struct vmem_altmap *altmap) argument
/linux-master/arch/sparc/mm/
H A Dinit_64.c2596 int node, struct vmem_altmap *altmap)
2595 vmemmap_populate(unsigned long vstart, unsigned long vend, int node, struct vmem_altmap *altmap) argument

Completed in 233 milliseconds