Merge tag 'v3.3.7' into 3.3/master
[zen-stable.git] / arch / tile / kernel / init_task.c
blob928b31870669bf6d425990d021c9739365b5b0b5
1 /*
2 * Copyright 2010 Tilera Corporation. All Rights Reserved.
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License
6 * as published by the Free Software Foundation, version 2.
8 * This program is distributed in the hope that it will be useful, but
9 * WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE, GOOD TITLE or
11 * NON INFRINGEMENT. See the GNU General Public License for
12 * more details.
15 #include <linux/mm.h>
16 #include <linux/fs.h>
17 #include <linux/init_task.h>
18 #include <linux/mqueue.h>
19 #include <linux/module.h>
20 #include <linux/start_kernel.h>
21 #include <linux/uaccess.h>
23 static struct signal_struct init_signals = INIT_SIGNALS(init_signals);
24 static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
27 * Initial thread structure.
29 * We need to make sure that this is THREAD_SIZE aligned due to the
30 * way process stacks are handled. This is done by having a special
31 * "init_task" linker map entry..
33 union thread_union init_thread_union __init_task_data = {
34 INIT_THREAD_INFO(init_task)
38 * Initial task structure.
40 * All other task structs will be allocated on slabs in fork.c
42 struct task_struct init_task = INIT_TASK(init_task);
43 EXPORT_SYMBOL(init_task);
46 * per-CPU stack and boot info.
48 DEFINE_PER_CPU(unsigned long, boot_sp) =
49 (unsigned long)init_stack + THREAD_SIZE;
51 #ifdef CONFIG_SMP
52 DEFINE_PER_CPU(unsigned long, boot_pc) = (unsigned long)start_kernel;
53 #else
55 * The variable must be __initdata since it references __init code.
56 * With CONFIG_SMP it is per-cpu data, which is exempt from validation.
58 unsigned long __initdata boot_pc = (unsigned long)start_kernel;
59 #endif