PageRenderTime 21ms CodeModel.GetById 17ms app.highlight 2ms RepoModel.GetById 1ms app.codeStats 0ms

/arch/arm/include/asm/mmu.h

https://bitbucket.org/sammyz/iscream_thunderc-2.6.35-rebase
C++ Header | 37 lines | 23 code | 8 blank | 6 comment | 0 complexity | 0fdf0d4b9ba90ca3e8e1d89ec9afd381 MD5 | raw file
Possible License(s): GPL-2.0, LGPL-2.0, AGPL-1.0
 1#ifndef __ARM_MMU_H
 2#define __ARM_MMU_H
 3
 4#ifdef CONFIG_MMU
 5
 6typedef struct {
 7#ifdef CONFIG_CPU_HAS_ASID
 8	unsigned int id;
 9	spinlock_t id_lock;
10#endif
11	unsigned int kvm_seq;
12} mm_context_t;
13
14#ifdef CONFIG_CPU_HAS_ASID
15#define ASID(mm)	((mm)->context.id & 255)
16
17/* init_mm.context.id_lock should be initialized. */
18#define INIT_MM_CONTEXT(name)                                                 \
19	.context.id_lock    = __SPIN_LOCK_UNLOCKED(name.context.id_lock),
20#else
21#define ASID(mm)	(0)
22#endif
23
24#else
25
26/*
27 * From nommu.h:
28 *  Copyright (C) 2002, David McCullough <davidm@snapgear.com>
29 *  modified for 2.6 by Hyok S. Choi <hyok.choi@samsung.com>
30 */
31typedef struct {
32	unsigned long		end_brk;
33} mm_context_t;
34
35#endif
36
37#endif