]> bbs.cooldavid.org Git - net-next-2.6.git/blame - arch/um/kernel/init_task.c
[PATCH] namespaces: add nsproxy
[net-next-2.6.git] / arch / um / kernel / init_task.c
CommitLineData
1da177e4
LT
1/*
2 * Copyright (C) 2000 Jeff Dike (jdike@karaya.com)
3 * Licensed under the GPL
4 */
5
6#include "linux/config.h"
7#include "linux/mm.h"
8#include "linux/module.h"
9#include "linux/sched.h"
10#include "linux/init_task.h"
11#include "linux/mqueue.h"
ab516013 12#include "linux/nsproxy.h"
1da177e4
LT
13#include "asm/uaccess.h"
14#include "asm/pgtable.h"
15#include "user_util.h"
16#include "mem_user.h"
0f80bc85 17#include "os.h"
1da177e4
LT
18
19static struct fs_struct init_fs = INIT_FS;
20struct mm_struct init_mm = INIT_MM(init_mm);
ab516013 21struct nsproxy init_nsproxy = INIT_NSPROXY(init_nsproxy);
1da177e4
LT
22static struct files_struct init_files = INIT_FILES;
23static struct signal_struct init_signals = INIT_SIGNALS(init_signals);
24static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
25EXPORT_SYMBOL(init_mm);
26
27/*
28 * Initial task structure.
29 *
30 * All other task structs will be allocated on slabs in fork.c
31 */
32
33struct task_struct init_task = INIT_TASK(init_task);
34
35EXPORT_SYMBOL(init_task);
36
37/*
38 * Initial thread structure.
39 *
40 * We need to make sure that this is 16384-byte aligned due to the
41 * way process stacks are handled. This is done by having a special
42 * "init_task" linker map entry..
43 */
44
45union thread_union init_thread_union
46__attribute__((__section__(".data.init_task"))) =
47{ INIT_THREAD_INFO(init_task) };
48
49void unprotect_stack(unsigned long stack)
50{
0f80bc85
JD
51 os_protect_memory((void *) stack, (1 << CONFIG_KERNEL_STACK_ORDER) * PAGE_SIZE,
52 1, 1, 0);
1da177e4
LT
53}
54
55/*
56 * Overrides for Emacs so that we follow Linus's tabbing style.
57 * Emacs will notice this stuff at the end of the file and automatically
58 * adjust the settings for this buffer only. This must remain at the end
59 * of the file.
60 * ---------------------------------------------------------------------------
61 * Local variables:
62 * c-file-style: "linux"
63 * End:
64 */