pgtable.h (9a87ffc99ec8eb8d35eed7c4f816d75f5cc9662e) pgtable.h (2f0584f3f4bd60bcc8735172981fb0bff86e74e0)
1/* SPDX-License-Identifier: GPL-2.0 */
2#ifndef _ALPHA_PGTABLE_H
3#define _ALPHA_PGTABLE_H
4
5#include <asm-generic/pgtable-nopud.h>
6
7/*
8 * This file contains the functions and defines necessary to modify and use

--- 242 unchanged lines hidden (view full) ---

251 */
252extern inline int pte_write(pte_t pte) { return !(pte_val(pte) & _PAGE_FOW); }
253extern inline int pte_dirty(pte_t pte) { return pte_val(pte) & _PAGE_DIRTY; }
254extern inline int pte_young(pte_t pte) { return pte_val(pte) & _PAGE_ACCESSED; }
255
256extern inline pte_t pte_wrprotect(pte_t pte) { pte_val(pte) |= _PAGE_FOW; return pte; }
257extern inline pte_t pte_mkclean(pte_t pte) { pte_val(pte) &= ~(__DIRTY_BITS); return pte; }
258extern inline pte_t pte_mkold(pte_t pte) { pte_val(pte) &= ~(__ACCESS_BITS); return pte; }
1/* SPDX-License-Identifier: GPL-2.0 */
2#ifndef _ALPHA_PGTABLE_H
3#define _ALPHA_PGTABLE_H
4
5#include <asm-generic/pgtable-nopud.h>
6
7/*
8 * This file contains the functions and defines necessary to modify and use

--- 242 unchanged lines hidden (view full) ---

251 */
252extern inline int pte_write(pte_t pte) { return !(pte_val(pte) & _PAGE_FOW); }
253extern inline int pte_dirty(pte_t pte) { return pte_val(pte) & _PAGE_DIRTY; }
254extern inline int pte_young(pte_t pte) { return pte_val(pte) & _PAGE_ACCESSED; }
255
256extern inline pte_t pte_wrprotect(pte_t pte) { pte_val(pte) |= _PAGE_FOW; return pte; }
257extern inline pte_t pte_mkclean(pte_t pte) { pte_val(pte) &= ~(__DIRTY_BITS); return pte; }
258extern inline pte_t pte_mkold(pte_t pte) { pte_val(pte) &= ~(__ACCESS_BITS); return pte; }
259extern inline pte_t pte_mkwrite(pte_t pte) { pte_val(pte) &= ~_PAGE_FOW; return pte; }
259extern inline pte_t pte_mkwrite_novma(pte_t pte){ pte_val(pte) &= ~_PAGE_FOW; return pte; }
260extern inline pte_t pte_mkdirty(pte_t pte) { pte_val(pte) |= __DIRTY_BITS; return pte; }
261extern inline pte_t pte_mkyoung(pte_t pte) { pte_val(pte) |= __ACCESS_BITS; return pte; }
262
263/*
264 * The smp_rmb() in the following functions are required to order the load of
265 * *dir (the pointer in the top level page table) with any subsequent load of
266 * the returned pmd_t *ret (ret is data dependent on *dir).
267 *

--- 93 unchanged lines hidden ---
260extern inline pte_t pte_mkdirty(pte_t pte) { pte_val(pte) |= __DIRTY_BITS; return pte; }
261extern inline pte_t pte_mkyoung(pte_t pte) { pte_val(pte) |= __ACCESS_BITS; return pte; }
262
263/*
264 * The smp_rmb() in the following functions are required to order the load of
265 * *dir (the pointer in the top level page table) with any subsequent load of
266 * the returned pmd_t *ret (ret is data dependent on *dir).
267 *

--- 93 unchanged lines hidden ---