init_task.c 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. // SPDX-License-Identifier: GPL-2.0
  2. #include <linux/init_task.h>
  3. #include <linux/export.h>
  4. #include <linux/mqueue.h>
  5. #include <linux/sched.h>
  6. #include <linux/sched/sysctl.h>
  7. #include <linux/sched/rt.h>
  8. #include <linux/sched/task.h>
  9. #include <linux/init.h>
  10. #include <linux/fs.h>
  11. #include <linux/mm.h>
  12. #include <linux/scs.h>
  13. #include <asm/pgtable.h>
  14. #include <linux/uaccess.h>
  15. static struct signal_struct init_signals = INIT_SIGNALS(init_signals);
  16. static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
  17. /* Initial task structure */
  18. struct task_struct init_task = INIT_TASK(init_task);
  19. EXPORT_SYMBOL(init_task);
  20. #ifdef CONFIG_SHADOW_CALL_STACK
  21. unsigned long init_shadow_call_stack[SCS_SIZE / sizeof(long)] __init_task_data
  22. __aligned(SCS_SIZE) = {
  23. [(SCS_SIZE / sizeof(long)) - 1] = SCS_END_MAGIC
  24. };
  25. #endif
  26. /*
  27. * Initial thread structure. Alignment of this is handled by a special
  28. * linker map entry.
  29. */
  30. union thread_union init_thread_union __init_task_data = {
  31. #ifndef CONFIG_THREAD_INFO_IN_TASK
  32. INIT_THREAD_INFO(init_task)
  33. #endif
  34. };