Home
last modified time | relevance | path

Searched refs:old_pte (Results 1 – 25 of 33) sorted by relevance

12

/openbmc/linux/arch/powerpc/mm/book3s64/
H A Dhash_64k.c46 unsigned long old_pte, new_pte, subpg_pte; in __hash_page_4K() local
56 old_pte = pte_val(pte); in __hash_page_4K()
58 if (unlikely(old_pte & H_PAGE_BUSY)) in __hash_page_4K()
61 if (unlikely(!check_pte_access(access, old_pte))) in __hash_page_4K()
68 new_pte = old_pte | H_PAGE_BUSY | _PAGE_ACCESSED | H_PAGE_COMBO; in __hash_page_4K()
71 } while (!pte_xchg(ptep, __pte(old_pte), __pte(new_pte))); in __hash_page_4K()
86 rflags = hash_page_do_lazy_icache(rflags, __pte(old_pte), trap); in __hash_page_4K()
91 rpte = __real_pte(__pte(old_pte), ptep, PTRS_PER_PTE); in __hash_page_4K()
95 if (!(old_pte & H_PAGE_HASHPTE)) in __hash_page_4K()
101 if (!(old_pte & H_PAGE_COMBO)) { in __hash_page_4K()
[all …]
H A Dhugetlbpage.c26 unsigned long old_pte, new_pte; in __hash_page_huge() local
49 old_pte = pte_val(*ptep); in __hash_page_huge()
51 if (unlikely(old_pte & H_PAGE_BUSY)) in __hash_page_huge()
54 if (unlikely(!check_pte_access(access, old_pte))) in __hash_page_huge()
61 new_pte = old_pte | H_PAGE_BUSY | _PAGE_ACCESSED; in __hash_page_huge()
64 } while(!pte_xchg(ptep, __pte(old_pte), __pte(new_pte))); in __hash_page_huge()
67 if (old_pte & (H_PAGE_THP_HUGE | _PAGE_DEVMAP)) in __hash_page_huge()
75 rpte = __real_pte(__pte(old_pte), ptep, offset); in __hash_page_huge()
82 rflags = hash_page_do_lazy_icache(rflags, __pte(old_pte), trap); in __hash_page_huge()
85 if (unlikely(old_pte & H_PAGE_HASHPTE)) { in __hash_page_huge()
[all …]
H A Dhash_4k.c28 unsigned long old_pte, new_pte; in __hash_page_4K() local
38 old_pte = pte_val(pte); in __hash_page_4K()
40 if (unlikely(old_pte & H_PAGE_BUSY)) in __hash_page_4K()
43 if (unlikely(!check_pte_access(access, old_pte))) in __hash_page_4K()
50 new_pte = old_pte | H_PAGE_BUSY | _PAGE_ACCESSED; in __hash_page_4K()
53 } while (!pte_xchg(ptep, __pte(old_pte), __pte(new_pte))); in __hash_page_4K()
60 rpte = __real_pte(__pte(old_pte), ptep, PTRS_PER_PTE); in __hash_page_4K()
64 rflags = hash_page_do_lazy_icache(rflags, __pte(old_pte), trap); in __hash_page_4K()
67 if (unlikely(old_pte & H_PAGE_HASHPTE)) { in __hash_page_4K()
76 old_pte &= ~_PAGE_HPTEFLAGS; in __hash_page_4K()
[all …]
H A Dradix_hugetlbpage.c47 pte_t old_pte, pte_t pte) in radix__huge_ptep_modify_prot_commit() argument
58 is_pte_rw_upgrade(pte_val(old_pte), pte_val(pte)) && in radix__huge_ptep_modify_prot_commit()
H A Dhash_hugepage.c69 rflags = hash_page_do_lazy_icache(rflags, __pte(old_pte), trap); in __hash_page_thp()
H A Dradix_pgtable.c1502 unsigned long old_pte, new_pte; in radix__ptep_set_access_flags() local
1504 old_pte = __radix_pte_update(ptep, _PAGE_PRESENT, _PAGE_INVALID); in radix__ptep_set_access_flags()
1505 new_pte = old_pte | set; in radix__ptep_set_access_flags()
1525 pte_t old_pte, pte_t pte) in radix__ptep_modify_prot_commit() argument
1535 is_pte_rw_upgrade(pte_val(old_pte), pte_val(pte)) && in radix__ptep_modify_prot_commit()
H A Dpgtable.c538 pte_t *ptep, pte_t old_pte, pte_t pte) in ptep_modify_prot_commit() argument
542 ptep, old_pte, pte); in ptep_modify_prot_commit()
/openbmc/linux/arch/powerpc/include/asm/book3s/64/
H A Dradix.h152 pte_t old_pte, pte_t pte);
178 unsigned long old_pte; in radix__pte_update() local
180 old_pte = __radix_pte_update(ptep, clr, set); in radix__pte_update()
184 return old_pte; in radix__pte_update()
191 unsigned long old_pte; in radix__ptep_get_and_clear_full() local
194 old_pte = pte_val(*ptep); in radix__ptep_get_and_clear_full()
197 old_pte = radix__pte_update(mm, addr, ptep, ~0ul, 0, 0); in radix__ptep_get_and_clear_full()
199 return __pte(old_pte); in radix__ptep_get_and_clear_full()
H A Dhugetlb.h17 pte_t old_pte, pte_t pte);
62 pte_t old_pte, pte_t new_pte);
/openbmc/linux/mm/
H A Dmapping_dirty_helpers.c41 pte_t old_pte = ptep_modify_prot_start(walk->vma, addr, pte); in wp_pte() local
43 ptent = pte_wrprotect(old_pte); in wp_pte()
44 ptep_modify_prot_commit(walk->vma, addr, pte, old_pte, ptent); in wp_pte()
99 pte_t old_pte = ptep_modify_prot_start(walk->vma, addr, pte); in clean_record_pte() local
101 ptent = pte_mkclean(old_pte); in clean_record_pte()
102 ptep_modify_prot_commit(walk->vma, addr, pte, old_pte, ptent); in clean_record_pte()
H A Dmremap.c142 pte_t *old_pte, *new_pte, pte; in move_ptes() local
173 old_pte = pte_offset_map_lock(mm, old_pmd, old_addr, &old_ptl); in move_ptes()
174 if (!old_pte) { in move_ptes()
180 pte_unmap_unlock(old_pte, old_ptl); in move_ptes()
189 for (; old_addr < old_end; old_pte++, old_addr += PAGE_SIZE, in move_ptes()
191 if (pte_none(ptep_get(old_pte))) in move_ptes()
194 pte = ptep_get_and_clear(mm, old_addr, old_pte); in move_ptes()
219 pte_unmap_unlock(old_pte - 1, old_ptl); in move_ptes()
H A Dmigrate.c190 pte_t old_pte; in remove_migration_pte() local
213 old_pte = ptep_get(pvmw.pte); in remove_migration_pte()
214 if (pte_swp_soft_dirty(old_pte)) in remove_migration_pte()
217 entry = pte_to_swp_entry(old_pte); in remove_migration_pte()
224 else if (pte_swp_uffd_wp(old_pte)) in remove_migration_pte()
238 if (pte_swp_soft_dirty(old_pte)) in remove_migration_pte()
240 if (pte_swp_uffd_wp(old_pte)) in remove_migration_pte()
/openbmc/linux/arch/arm64/include/asm/
H A Dpgtable.h300 pte_t old_pte; in __check_safe_pte_update() local
305 old_pte = READ_ONCE(*ptep); in __check_safe_pte_update()
307 if (!pte_valid(old_pte) || !pte_valid(pte)) in __check_safe_pte_update()
319 __func__, pte_val(old_pte), pte_val(pte)); in __check_safe_pte_update()
320 VM_WARN_ONCE(pte_write(old_pte) && !pte_dirty(pte), in __check_safe_pte_update()
322 __func__, pte_val(old_pte), pte_val(pte)); in __check_safe_pte_update()
323 VM_WARN_ONCE(!pgattr_change_is_safe(pte_val(old_pte), pte_val(pte)), in __check_safe_pte_update()
325 __func__, pte_val(old_pte), pte_val(pte)); in __check_safe_pte_update()
891 pte_t old_pte, pte; in __ptep_test_and_clear_young() local
895 old_pte = pte; in __ptep_test_and_clear_young()
[all …]
H A Dhugetlb.h60 pte_t old_pte, pte_t new_pte);
/openbmc/linux/arch/powerpc/include/asm/
H A Dkvm_book3s_64.h424 pte_t old_pte, new_pte = __pte(0); in kvmppc_read_update_linux_pte() local
430 old_pte = READ_ONCE(*ptep); in kvmppc_read_update_linux_pte()
434 if (unlikely(pte_val(old_pte) & H_PAGE_BUSY)) { in kvmppc_read_update_linux_pte()
439 if (unlikely(!pte_present(old_pte))) in kvmppc_read_update_linux_pte()
442 new_pte = pte_mkyoung(old_pte); in kvmppc_read_update_linux_pte()
443 if (writing && pte_write(old_pte)) in kvmppc_read_update_linux_pte()
446 if (pte_xchg(ptep, old_pte, new_pte)) in kvmppc_read_update_linux_pte()
/openbmc/linux/arch/parisc/mm/
H A Dhugetlbpage.c164 pte_t old_pte; in huge_ptep_set_wrprotect() local
166 old_pte = *ptep; in huge_ptep_set_wrprotect()
167 __set_huge_pte_at(mm, addr, ptep, pte_wrprotect(old_pte)); in huge_ptep_set_wrprotect()
/openbmc/linux/arch/sparc/include/asm/
H A Dhugetlb.h36 pte_t old_pte = *ptep; in huge_ptep_set_wrprotect() local
37 __set_huge_pte_at(mm, addr, ptep, pte_wrprotect(old_pte)); in huge_ptep_set_wrprotect()
/openbmc/linux/arch/mips/kvm/
H A Dmmu.c452 pte_t old_pte; in kvm_set_spte_gfn() local
458 old_pte = *gpa_pte; in kvm_set_spte_gfn()
459 if (range->slot->flags & KVM_MEM_LOG_DIRTY_PAGES && !pte_dirty(old_pte)) in kvm_set_spte_gfn()
467 if (!pte_present(old_pte) || !pte_young(old_pte)) in kvm_set_spte_gfn()
473 pte_pfn(old_pte) != pte_pfn(hva_pte) || in kvm_set_spte_gfn()
474 (pte_dirty(old_pte) && !pte_dirty(hva_pte)); in kvm_set_spte_gfn()
/openbmc/u-boot/arch/arm/cpu/armv8/
H A Dcache_v8.c172 u64 old_pte = *pte; in split_block() local
181 "mem_map.", pte, old_pte); in split_block()
184 debug("Splitting pte %p (%llx) into %p\n", pte, old_pte, new_table); in split_block()
187 new_table[i] = old_pte | (i << levelshift); in split_block()
/openbmc/linux/arch/x86/mm/pat/
H A Dset_memory.c1630 pte_t *kpte, old_pte; in __change_page_attr() local
1639 old_pte = *kpte; in __change_page_attr()
1640 if (pte_none(old_pte)) in __change_page_attr()
1645 pgprot_t old_prot = pte_pgprot(old_pte); in __change_page_attr()
1646 pgprot_t new_prot = pte_pgprot(old_pte); in __change_page_attr()
1647 unsigned long pfn = pte_pfn(old_pte); in __change_page_attr()
1672 if (pte_val(old_pte) != pte_val(new_pte)) { in __change_page_attr()
/openbmc/linux/arch/ia64/include/asm/
H A Dpgtable.h387 pte_t old_pte = *ptep; in ptep_set_wrprotect()
388 set_pte_at(mm, addr, ptep, pte_wrprotect(old_pte)); in ptep_set_wrprotect()
/openbmc/linux/arch/x86/include/asm/
H A Dpgtable.h1301 pte_t old_pte, new_pte; in ptep_set_wrprotect() local
1303 old_pte = READ_ONCE(*ptep); in ptep_set_wrprotect()
1305 new_pte = pte_wrprotect(old_pte); in ptep_set_wrprotect()
1306 } while (!try_cmpxchg((long *)&ptep->pte, (long *)&old_pte, *(long *)&new_pte)); in ptep_set_wrprotect()
/openbmc/linux/include/linux/
H A Dpgtable.h641 pte_t old_pte = ptep_get(ptep); in ptep_set_wrprotect() local
642 set_pte_at(mm, address, ptep, pte_wrprotect(old_pte)); in ptep_set_wrprotect()
1107 pte_t *ptep, pte_t old_pte, pte_t pte) in ptep_modify_prot_commit() argument
/openbmc/qemu/target/riscv/
H A Dcpu_helper.c1240 target_ulong old_pte; in get_physical_address() local
1242 old_pte = qatomic_cmpxchg((uint32_t *)pte_pa, pte, updated_pte); in get_physical_address()
1244 old_pte = qatomic_cmpxchg(pte_pa, pte, updated_pte); in get_physical_address()
1246 if (old_pte != pte) { in get_physical_address()
/openbmc/linux/arch/arm64/mm/
H A Dmmu.c179 pte_t old_pte = READ_ONCE(*ptep); in init_pte() local
187 BUG_ON(!pgattr_change_is_safe(pte_val(old_pte), in init_pte()
1486 pte_t old_pte, pte_t pte) in ptep_modify_prot_commit() argument

12