1 // SPDX-License-Identifier: GPL-2.0
3 * This is where we statically allocate and initialize the initial
6 * Copyright (C) 1999, 2002-2003 Hewlett-Packard Co
7 * David Mosberger-Tang <davidm@hpl.hp.com>
10 #include <linux/init.h>
13 #include <linux/module.h>
14 #include <linux/sched.h>
15 #include <linux/init_task.h>
16 #include <linux/mqueue.h>
18 #include <linux/uaccess.h>
19 #include <asm/pgtable.h>
21 static struct signal_struct init_signals
= INIT_SIGNALS(init_signals
);
22 static struct sighand_struct init_sighand
= INIT_SIGHAND(init_sighand
);
24 * Initial task structure.
26 * We need to make sure that this is properly aligned due to the way process stacks are
27 * handled. This is done by having a special ".data..init_task" section...
29 #define init_thread_info init_task_mem.s.thread_info
30 #define init_stack init_task_mem.stack
34 struct task_struct task
;
35 struct thread_info thread_info
;
37 unsigned long stack
[KERNEL_STACK_SIZE
/sizeof (unsigned long)];
38 } init_task_mem
asm ("init_task") __init_task_data
=
40 .task
= INIT_TASK(init_task_mem
.s
.task
),
41 .thread_info
= INIT_THREAD_INFO(init_task_mem
.s
.task
)
44 EXPORT_SYMBOL(init_task
);