Lines Matching +full:long +full:- +full:ram +full:- +full:code

1 // SPDX-License-Identifier: GPL-2.0-or-later
7 * Copyright (C) 1995-1996 Gary Thomas (gdt@linuxppc.org)
27 #include <asm/code-patching.h>
32 /* The variables below are currently only used on 64-bit Book3E
39 unsigned long linear_map_top; /* Top of linear mapping */
45 * do not modify this SPRG in the TLB miss code; for other TLB miss handlers,
54 void tlb_flush_pgtable(struct mmu_gather *tlb, unsigned long address) in tlb_flush_pgtable()
56 int tsize = mmu_psize_defs[mmu_pte_psize].shift - 10; in tlb_flush_pgtable()
59 unsigned long start = address & PMD_MASK; in tlb_flush_pgtable()
60 unsigned long end = address + PMD_SIZE; in tlb_flush_pgtable()
61 unsigned long size = 1UL << mmu_psize_defs[mmu_pte_psize].shift; in tlb_flush_pgtable()
68 __flush_tlb_page(tlb->mm, start, tsize, 1); in tlb_flush_pgtable()
72 unsigned long rmask = 0xf000000000000000ul; in tlb_flush_pgtable()
73 unsigned long rid = (address & rmask) | 0x1000000000000000ul; in tlb_flush_pgtable()
74 unsigned long vpte = address & ~rmask; in tlb_flush_pgtable()
76 vpte = (vpte >> (PAGE_SHIFT - 3)) & ~0xffful; in tlb_flush_pgtable()
78 __flush_tlb_page(tlb->mm, vpte, tsize, 0); in tlb_flush_pgtable()
102 shift = def->shift; in setup_page_sizes()
108 shift = (shift - 10) >> 1; in setup_page_sizes()
111 def->flags |= MMU_PAGE_SIZE_DIRECT; in setup_page_sizes()
139 if (!def->shift) in setup_page_sizes()
142 if (tlb1ps & (1U << (def->shift - 10))) { in setup_page_sizes()
143 def->flags |= MMU_PAGE_SIZE_DIRECT; in setup_page_sizes()
146 def->flags |= MMU_PAGE_SIZE_INDIRECT; in setup_page_sizes()
163 if (def->flags == 0) { in setup_page_sizes()
164 def->shift = 0; in setup_page_sizes()
167 pr_info(" %8ld KB as %s\n", 1ul << (def->shift - 10), in setup_page_sizes()
168 __page_type_names[def->flags & 0x3]); in setup_page_sizes()
173 * Early initialization of the MMU TLB code
229 /* XXX This code only checks for TLB 0 capabilities and doesn't in early_init_mmu_global()
253 * for use by the TLB miss code in early_init_mmu_global()
267 * do this because highmem is not supported on 64-bit. in early_mmu_set_memory_limit()
291 * On FSL Embedded 64-bit, usually all RAM is bolted, but with in setup_initial_memory_limit()
292 * unusual memory sizes it's possible for some RAM to not be mapped in setup_initial_memory_limit()
293 * (such RAM is not used at all by Linux, since we don't support in setup_initial_memory_limit()
294 * highmem on 64-bit). We limit ppc64_rma_size to what would be in setup_initial_memory_limit()
298 * more. This is due to what the early init code is set up to do. in setup_initial_memory_limit()
303 unsigned long linear_sz; in setup_initial_memory_limit()