Lines Matching full:pte
64 extern void __update_cache(pte_t pte);
79 printk("%s:%d: bad pte %08lx.\n", __FILE__, __LINE__, pte_val(e))
104 * done to get usable bits out of the PTE) */
182 /* this defines the shift to the usable bits in the PTE it is set so
187 /* PFN_PTE_SHIFT defines the shift of a PTE value to access the PFN field */
315 static inline int pte_dirty(pte_t pte) { return pte_val(pte) & _PAGE_DIRTY; } in pte_dirty() argument
316 static inline int pte_young(pte_t pte) { return pte_val(pte) & _PAGE_ACCESSED; } in pte_young() argument
317 static inline int pte_write(pte_t pte) { return pte_val(pte) & _PAGE_WRITE; } in pte_write() argument
318 static inline int pte_special(pte_t pte) { return pte_val(pte) & _PAGE_SPECIAL; } in pte_special() argument
320 static inline pte_t pte_mkclean(pte_t pte) { pte_val(pte) &= ~_PAGE_DIRTY; return pte; } in pte_mkclean() argument
321 static inline pte_t pte_mkold(pte_t pte) { pte_val(pte) &= ~_PAGE_ACCESSED; return pte; } in pte_mkold() argument
322 static inline pte_t pte_wrprotect(pte_t pte) { pte_val(pte) &= ~_PAGE_WRITE; return pte; } in pte_wrprotect() argument
323 static inline pte_t pte_mkdirty(pte_t pte) { pte_val(pte) |= _PAGE_DIRTY; return pte; } in pte_mkdirty() argument
324 static inline pte_t pte_mkyoung(pte_t pte) { pte_val(pte) |= _PAGE_ACCESSED; return pte; } in pte_mkyoung() argument
325 static inline pte_t pte_mkwrite_novma(pte_t pte) { pte_val(pte) |= _PAGE_WRITE; return pte; } in pte_mkwrite_novma() argument
326 static inline pte_t pte_mkspecial(pte_t pte) { pte_val(pte) |= _PAGE_SPECIAL; return pte; } in pte_mkspecial() argument
329 * Huge pte definitions.
332 #define pte_huge(pte) (pte_val(pte) & _PAGE_HUGE) argument
333 #define pte_mkhuge(pte) (__pte(pte_val(pte) | \ argument
336 #define pte_huge(pte) (0) argument
337 #define pte_mkhuge(pte) (pte) argument
352 pte_t pte; in pfn_pte() local
353 pte_val(pte) = (pfn << PFN_PTE_SHIFT) | pgprot_val(pgprot); in pfn_pte()
354 return pte; in pfn_pte()
357 static inline pte_t pte_modify(pte_t pte, pgprot_t newprot) in pte_modify() argument
358 { pte_val(pte) = (pte_val(pte) & _PAGE_CHG_MASK) | pgprot_val(newprot); return pte; } in pte_modify()
364 #define pte_page(pte) (pfn_to_page(pte_pfn(pte))) argument
380 pte_t *ptep, pte_t pte, unsigned int nr) in set_ptes() argument
382 if (pte_present(pte) && pte_user(pte)) in set_ptes()
383 __update_cache(pte); in set_ptes()
385 *ptep = pte; in set_ptes()
390 pte_val(pte) += 1 << PFN_PTE_SHIFT; in set_ptes()
395 #define set_pte_at(mm, addr, ptep, pte) set_ptes(mm, addr, ptep, pte, 1) argument
426 #define __pte_to_swp_entry(pte) ((swp_entry_t) { pte_val(pte) }) argument
429 static inline bool pte_swp_exclusive(pte_t pte) in pte_swp_exclusive() argument
431 return pte_val(pte) & _PAGE_SWP_EXCLUSIVE; in pte_swp_exclusive()
434 static inline pte_t pte_swp_mkexclusive(pte_t pte) in pte_swp_mkexclusive() argument
436 pte_val(pte) |= _PAGE_SWP_EXCLUSIVE; in pte_swp_mkexclusive()
437 return pte; in pte_swp_mkexclusive()
440 static inline pte_t pte_swp_clear_exclusive(pte_t pte) in pte_swp_clear_exclusive() argument
442 pte_val(pte) &= ~_PAGE_SWP_EXCLUSIVE; in pte_swp_clear_exclusive()
443 return pte; in pte_swp_clear_exclusive()
454 pte_t pte; in ptep_test_and_clear_young() local
456 pte = ptep_get(ptep); in ptep_test_and_clear_young()
457 if (!pte_young(pte)) { in ptep_test_and_clear_young()
460 set_pte_at(vma->vm_mm, addr, ptep, pte_mkold(pte)); in ptep_test_and_clear_young()