arch/m68k/include/asm/mcf_pgtable.h
Source file repositories/reference/linux-study-clean/arch/m68k/include/asm/mcf_pgtable.h
File Facts
- System
- Linux kernel
- Corpus path
arch/m68k/include/asm/mcf_pgtable.h- Extension
.h- Size
- 7194 bytes
- Lines
- 297
- Domain
- Architecture Layer
- Bucket
- arch/m68k
- Inferred role
- Architecture Layer: implementation source
- Status
- source implementation candidate
Why This File Exists
CPU and platform-specific kernel glue: boot entry, traps, syscall entry, interrupts, page tables, context switch, and low-level barriers.
- CPU and platform-specific kernel glue: boot entry, traps, syscall entry, interrupts, page tables, context switch, and low-level barriers.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
asm/mcfmmu.hasm/page.h
Detected Declarations
function pte_modifyfunction pgd_setfunction pte_nonefunction pte_presentfunction pte_clearfunction pmd_none2function pmd_bad2function pmd_clearfunction pte_presentfunction pte_writefunction pte_execfunction pte_dirtyfunction pte_youngfunction pte_wrprotectfunction pte_rdprotectfunction pte_exprotectfunction pte_mkcleanfunction pte_mkoldfunction pte_mkwrite_novmafunction pte_mkreadfunction pte_mkexecfunction pte_mkdirtyfunction pte_mkyoungfunction pte_mknocachefunction pte_mkcachefunction pte_swp_exclusivefunction pte_swp_mkexclusivefunction pte_swp_clear_exclusive
Annotated Snippet
static inline int pmd_none2(pmd_t *pmd) { return !pmd_val(*pmd); }
#define pmd_none(pmd) pmd_none2(&(pmd))
static inline int pmd_bad2(pmd_t *pmd) { return 0; }
#define pmd_bad(pmd) pmd_bad2(&(pmd))
#define pmd_present(pmd) (!pmd_none2(&(pmd)))
static inline void pmd_clear(pmd_t *pmdp) { pmd_val(*pmdp) = 0; }
#define pte_ERROR(e) \
printk(KERN_ERR "%s:%d: bad pte %08lx.\n", \
__FILE__, __LINE__, pte_val(e))
#define pgd_ERROR(e) \
printk(KERN_ERR "%s:%d: bad pgd %08lx.\n", \
__FILE__, __LINE__, pgd_val(e))
/*
* The following only work if pte_present() is true.
* Undefined behaviour if not...
* [we have the full set here even if they don't change from m68k]
*/
static inline int pte_read(pte_t pte)
{
return pte_val(pte) & CF_PAGE_READABLE;
}
static inline int pte_write(pte_t pte)
{
return pte_val(pte) & CF_PAGE_WRITABLE;
}
static inline int pte_exec(pte_t pte)
{
return pte_val(pte) & CF_PAGE_EXEC;
}
static inline int pte_dirty(pte_t pte)
{
return pte_val(pte) & CF_PAGE_DIRTY;
}
static inline int pte_young(pte_t pte)
{
return pte_val(pte) & CF_PAGE_ACCESSED;
}
static inline pte_t pte_wrprotect(pte_t pte)
{
pte_val(pte) &= ~CF_PAGE_WRITABLE;
return pte;
}
static inline pte_t pte_rdprotect(pte_t pte)
{
pte_val(pte) &= ~CF_PAGE_READABLE;
return pte;
}
static inline pte_t pte_exprotect(pte_t pte)
{
pte_val(pte) &= ~CF_PAGE_EXEC;
return pte;
}
static inline pte_t pte_mkclean(pte_t pte)
{
pte_val(pte) &= ~CF_PAGE_DIRTY;
return pte;
}
static inline pte_t pte_mkold(pte_t pte)
{
pte_val(pte) &= ~CF_PAGE_ACCESSED;
return pte;
}
static inline pte_t pte_mkwrite_novma(pte_t pte)
{
pte_val(pte) |= CF_PAGE_WRITABLE;
return pte;
}
static inline pte_t pte_mkread(pte_t pte)
{
pte_val(pte) |= CF_PAGE_READABLE;
return pte;
}
static inline pte_t pte_mkexec(pte_t pte)
{
pte_val(pte) |= CF_PAGE_EXEC;
return pte;
Annotation
- Immediate include surface: `asm/mcfmmu.h`, `asm/page.h`.
- Detected declarations: `function pte_modify`, `function pgd_set`, `function pte_none`, `function pte_present`, `function pte_clear`, `function pmd_none2`, `function pmd_bad2`, `function pmd_clear`, `function pte_present`, `function pte_write`.
- Atlas domain: Architecture Layer / arch/m68k.
- Implementation status: source implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.