pgtable.h (05909cd9a0c8811731b38697af13075e8954314f) pgtable.h (05cdf457477d6603b207d91873f0a3d4c7f8c1cd)
1/* SPDX-License-Identifier: GPL-2.0 */
2/*
3 * Copyright (C) 2008-2009 Michal Simek <monstr@monstr.eu>
4 * Copyright (C) 2008-2009 PetaLogix
5 * Copyright (C) 2006 Atmark Techno, Inc.
6 */
7
8#ifndef _ASM_MICROBLAZE_PGTABLE_H
9#define _ASM_MICROBLAZE_PGTABLE_H
10
11#include <asm/setup.h>
12
13#ifndef __ASSEMBLY__
14extern int mem_init_done;
15#endif
16
1/* SPDX-License-Identifier: GPL-2.0 */
2/*
3 * Copyright (C) 2008-2009 Michal Simek <monstr@monstr.eu>
4 * Copyright (C) 2008-2009 PetaLogix
5 * Copyright (C) 2006 Atmark Techno, Inc.
6 */
7
8#ifndef _ASM_MICROBLAZE_PGTABLE_H
9#define _ASM_MICROBLAZE_PGTABLE_H
10
11#include <asm/setup.h>
12
13#ifndef __ASSEMBLY__
14extern int mem_init_done;
15#endif
16
17#ifndef CONFIG_MMU
18
19#define pgd_present(pgd) (1) /* pages are always present on non MMU */
20#define pgd_none(pgd) (0)
21#define pgd_bad(pgd) (0)
22#define pgd_clear(pgdp)
23#define kern_addr_valid(addr) (1)
24
25#define PAGE_NONE __pgprot(0) /* these mean nothing to non MMU */
26#define PAGE_SHARED __pgprot(0) /* these mean nothing to non MMU */
27#define PAGE_COPY __pgprot(0) /* these mean nothing to non MMU */
28#define PAGE_READONLY __pgprot(0) /* these mean nothing to non MMU */
29#define PAGE_KERNEL __pgprot(0) /* these mean nothing to non MMU */
30
31#define pgprot_noncached(x) (x)
32#define pgprot_writecombine pgprot_noncached
33#define pgprot_device pgprot_noncached
34
35#define __swp_type(x) (0)
36#define __swp_offset(x) (0)
37#define __swp_entry(typ, off) ((swp_entry_t) { ((typ) | ((off) << 7)) })
38#define __pte_to_swp_entry(pte) ((swp_entry_t) { pte_val(pte) })
39#define __swp_entry_to_pte(x) ((pte_t) { (x).val })
40
41#define ZERO_PAGE(vaddr) ({ BUG(); NULL; })
42
43#define swapper_pg_dir ((pgd_t *) NULL)
44
45#define arch_enter_lazy_cpu_mode() do {} while (0)
46
47#define pgprot_noncached_wc(prot) prot
48
49/*
50 * All 32bit addresses are effectively valid for vmalloc...
51 * Sort of meaningless for non-VM targets.
52 */
53#define VMALLOC_START 0
54#define VMALLOC_END 0xffffffff
55
56#else /* CONFIG_MMU */
57
58#include <asm-generic/pgtable-nopmd.h>
59
60#ifdef __KERNEL__
61#ifndef __ASSEMBLY__
62
63#include <linux/sched.h>
64#include <linux/threads.h>
65#include <asm/processor.h> /* For TASK_SIZE */

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

486
487asmlinkage void __init mmu_init(void);
488
489void __init *early_get_page(void);
490
491#endif /* __ASSEMBLY__ */
492#endif /* __KERNEL__ */
493
17#include <asm-generic/pgtable-nopmd.h>
18
19#ifdef __KERNEL__
20#ifndef __ASSEMBLY__
21
22#include <linux/sched.h>
23#include <linux/threads.h>
24#include <asm/processor.h> /* For TASK_SIZE */

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

445
446asmlinkage void __init mmu_init(void);
447
448void __init *early_get_page(void);
449
450#endif /* __ASSEMBLY__ */
451#endif /* __KERNEL__ */
452
494#endif /* CONFIG_MMU */
495
496#ifndef __ASSEMBLY__
497extern unsigned long ioremap_bot, ioremap_base;
498
499void setup_memory(void);
500#endif /* __ASSEMBLY__ */
501
502#endif /* _ASM_MICROBLAZE_PGTABLE_H */
453#ifndef __ASSEMBLY__
454extern unsigned long ioremap_bot, ioremap_base;
455
456void setup_memory(void);
457#endif /* __ASSEMBLY__ */
458
459#endif /* _ASM_MICROBLAZE_PGTABLE_H */