mmu.h 579 字节
Newer Older
L
Linus Torvalds 已提交
1 2 3
#ifndef __ARM_MMU_H
#define __ARM_MMU_H

4 5
#ifdef CONFIG_MMU

L
Linus Torvalds 已提交
6
typedef struct {
7
#ifdef CONFIG_CPU_HAS_ASID
8
	atomic64_t	id;
L
Linus Torvalds 已提交
9
#endif
10
	unsigned int	vmalloc_seq;
L
Linus Torvalds 已提交
11 12
} mm_context_t;

13
#ifdef CONFIG_CPU_HAS_ASID
14 15
#define ASID_BITS	8
#define ASID_MASK	((~0ULL) << ASID_BITS)
16
#define ASID(mm)	((mm)->context.id.counter & ~ASID_MASK)
L
Linus Torvalds 已提交
17 18 19 20
#else
#define ASID(mm)	(0)
#endif

21 22 23 24 25 26 27 28
#else

/*
 * From nommu.h:
 *  Copyright (C) 2002, David McCullough <davidm@snapgear.com>
 *  modified for 2.6 by Hyok S. Choi <hyok.choi@samsung.com>
 */
typedef struct {
29
	unsigned long	end_brk;
30 31 32 33
} mm_context_t;

#endif

L
Linus Torvalds 已提交
34
#endif