Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions | Variables
thread_info.h File Reference
#include <linux/compiler.h>
#include <asm/page.h>
#include <asm/types.h>
#include <asm/processor.h>
#include <asm/ftrace.h>
#include <linux/atomic.h>
#include <asm/percpu.h>

Go to the source code of this file.

Data Structures

struct  thread_info
 

Macros

#define INIT_THREAD_INFO(tsk)
 
#define init_thread_info   (init_thread_union.thread_info)
 
#define init_stack   (init_thread_union.stack)
 
#define TIF_SYSCALL_TRACE   0 /* syscall trace active */
 
#define TIF_NOTIFY_RESUME   1 /* callback before returning to user */
 
#define TIF_SIGPENDING   2 /* signal pending */
 
#define TIF_NEED_RESCHED   3 /* rescheduling necessary */
 
#define TIF_SINGLESTEP   4 /* reenable singlestep on user return*/
 
#define TIF_SYSCALL_EMU   6 /* syscall emulation active */
 
#define TIF_SYSCALL_AUDIT   7 /* syscall auditing active */
 
#define TIF_SECCOMP   8 /* secure computing */
 
#define TIF_MCE_NOTIFY   10 /* notify userspace of an MCE */
 
#define TIF_USER_RETURN_NOTIFY   11 /* notify kernel of userspace return */
 
#define TIF_UPROBE   12 /* breakpointed or singlestepping */
 
#define TIF_NOTSC   16 /* TSC is not accessible in userland */
 
#define TIF_IA32   17 /* IA32 compatibility process */
 
#define TIF_FORK   18 /* ret_from_fork */
 
#define TIF_NOHZ   19 /* in adaptive nohz mode */
 
#define TIF_MEMDIE   20 /* is terminating due to OOM killer */
 
#define TIF_DEBUG   21 /* uses debug registers */
 
#define TIF_IO_BITMAP   22 /* uses I/O bitmap */
 
#define TIF_FORCED_TF   24 /* true if TF in eflags artificially */
 
#define TIF_BLOCKSTEP   25 /* set when we want DEBUGCTLMSR_BTF */
 
#define TIF_LAZY_MMU_UPDATES   27 /* task is updating the mmu lazily */
 
#define TIF_SYSCALL_TRACEPOINT   28 /* syscall tracepoint instrumentation */
 
#define TIF_ADDR32   29 /* 32-bit address space on 64 bits */
 
#define TIF_X32   30 /* 32-bit native x86-64 binary */
 
#define _TIF_SYSCALL_TRACE   (1 << TIF_SYSCALL_TRACE)
 
#define _TIF_NOTIFY_RESUME   (1 << TIF_NOTIFY_RESUME)
 
#define _TIF_SIGPENDING   (1 << TIF_SIGPENDING)
 
#define _TIF_SINGLESTEP   (1 << TIF_SINGLESTEP)
 
#define _TIF_NEED_RESCHED   (1 << TIF_NEED_RESCHED)
 
#define _TIF_SYSCALL_EMU   (1 << TIF_SYSCALL_EMU)
 
#define _TIF_SYSCALL_AUDIT   (1 << TIF_SYSCALL_AUDIT)
 
#define _TIF_SECCOMP   (1 << TIF_SECCOMP)
 
#define _TIF_MCE_NOTIFY   (1 << TIF_MCE_NOTIFY)
 
#define _TIF_USER_RETURN_NOTIFY   (1 << TIF_USER_RETURN_NOTIFY)
 
#define _TIF_UPROBE   (1 << TIF_UPROBE)
 
#define _TIF_NOTSC   (1 << TIF_NOTSC)
 
#define _TIF_IA32   (1 << TIF_IA32)
 
#define _TIF_FORK   (1 << TIF_FORK)
 
#define _TIF_NOHZ   (1 << TIF_NOHZ)
 
#define _TIF_DEBUG   (1 << TIF_DEBUG)
 
#define _TIF_IO_BITMAP   (1 << TIF_IO_BITMAP)
 
#define _TIF_FORCED_TF   (1 << TIF_FORCED_TF)
 
#define _TIF_BLOCKSTEP   (1 << TIF_BLOCKSTEP)
 
#define _TIF_LAZY_MMU_UPDATES   (1 << TIF_LAZY_MMU_UPDATES)
 
#define _TIF_SYSCALL_TRACEPOINT   (1 << TIF_SYSCALL_TRACEPOINT)
 
#define _TIF_ADDR32   (1 << TIF_ADDR32)
 
#define _TIF_X32   (1 << TIF_X32)
 
#define _TIF_WORK_SYSCALL_ENTRY
 
#define _TIF_WORK_SYSCALL_EXIT
 
#define _TIF_WORK_MASK
 
#define _TIF_ALLWORK_MASK
 
#define _TIF_DO_NOTIFY_MASK
 
#define _TIF_WORK_CTXSW   (_TIF_IO_BITMAP|_TIF_NOTSC|_TIF_BLOCKSTEP)
 
#define _TIF_WORK_CTXSW_PREV   (_TIF_WORK_CTXSW|_TIF_USER_RETURN_NOTIFY)
 
#define _TIF_WORK_CTXSW_NEXT   (_TIF_WORK_CTXSW|_TIF_DEBUG)
 
#define PREEMPT_ACTIVE   0x10000000
 
#define KERNEL_STACK_OFFSET   (5*8)
 
#define TS_COMPAT   0x0002 /* 32bit syscall active (64BIT)*/
 
#define TS_POLLING
 
#define TS_RESTORE_SIGMASK   0x0008 /* restore signal mask in do_signal() */
 
#define tsk_is_polling(t)   (task_thread_info(t)->status & TS_POLLING)
 
#define HAVE_SET_RESTORE_SIGMASK   1
 

Functions

 DECLARE_PER_CPU (unsigned long, kernel_stack)
 
void arch_task_cache_init (void)
 
int arch_dup_task_struct (struct task_struct *dst, struct task_struct *src)
 
void arch_release_task_struct (struct task_struct *tsk)
 

Variables

struct thread_info __attribute__
 

Macro Definition Documentation

#define _TIF_ADDR32   (1 << TIF_ADDR32)

Definition at line 123 of file thread_info.h.

#define _TIF_ALLWORK_MASK
Value:

Definition at line 144 of file thread_info.h.

#define _TIF_BLOCKSTEP   (1 << TIF_BLOCKSTEP)

Definition at line 120 of file thread_info.h.

#define _TIF_DEBUG   (1 << TIF_DEBUG)

Definition at line 117 of file thread_info.h.

#define _TIF_DO_NOTIFY_MASK
Value:
_TIF_USER_RETURN_NOTIFY)

Definition at line 149 of file thread_info.h.

#define _TIF_FORCED_TF   (1 << TIF_FORCED_TF)

Definition at line 119 of file thread_info.h.

#define _TIF_FORK   (1 << TIF_FORK)

Definition at line 115 of file thread_info.h.

#define _TIF_IA32   (1 << TIF_IA32)

Definition at line 114 of file thread_info.h.

#define _TIF_IO_BITMAP   (1 << TIF_IO_BITMAP)

Definition at line 118 of file thread_info.h.

#define _TIF_LAZY_MMU_UPDATES   (1 << TIF_LAZY_MMU_UPDATES)

Definition at line 121 of file thread_info.h.

#define _TIF_MCE_NOTIFY   (1 << TIF_MCE_NOTIFY)

Definition at line 110 of file thread_info.h.

#define _TIF_NEED_RESCHED   (1 << TIF_NEED_RESCHED)

Definition at line 106 of file thread_info.h.

#define _TIF_NOHZ   (1 << TIF_NOHZ)

Definition at line 116 of file thread_info.h.

#define _TIF_NOTIFY_RESUME   (1 << TIF_NOTIFY_RESUME)

Definition at line 103 of file thread_info.h.

#define _TIF_NOTSC   (1 << TIF_NOTSC)

Definition at line 113 of file thread_info.h.

#define _TIF_SECCOMP   (1 << TIF_SECCOMP)

Definition at line 109 of file thread_info.h.

#define _TIF_SIGPENDING   (1 << TIF_SIGPENDING)

Definition at line 104 of file thread_info.h.

#define _TIF_SINGLESTEP   (1 << TIF_SINGLESTEP)

Definition at line 105 of file thread_info.h.

#define _TIF_SYSCALL_AUDIT   (1 << TIF_SYSCALL_AUDIT)

Definition at line 108 of file thread_info.h.

#define _TIF_SYSCALL_EMU   (1 << TIF_SYSCALL_EMU)

Definition at line 107 of file thread_info.h.

#define _TIF_SYSCALL_TRACE   (1 << TIF_SYSCALL_TRACE)

Definition at line 102 of file thread_info.h.

#define _TIF_SYSCALL_TRACEPOINT   (1 << TIF_SYSCALL_TRACEPOINT)

Definition at line 122 of file thread_info.h.

#define _TIF_UPROBE   (1 << TIF_UPROBE)

Definition at line 112 of file thread_info.h.

#define _TIF_USER_RETURN_NOTIFY   (1 << TIF_USER_RETURN_NOTIFY)

Definition at line 111 of file thread_info.h.

#define _TIF_WORK_CTXSW   (_TIF_IO_BITMAP|_TIF_NOTSC|_TIF_BLOCKSTEP)

Definition at line 154 of file thread_info.h.

#define _TIF_WORK_CTXSW_NEXT   (_TIF_WORK_CTXSW|_TIF_DEBUG)

Definition at line 158 of file thread_info.h.

#define _TIF_WORK_CTXSW_PREV   (_TIF_WORK_CTXSW|_TIF_USER_RETURN_NOTIFY)

Definition at line 157 of file thread_info.h.

#define _TIF_WORK_MASK
Value:
(0x0000FFFF & \
_TIF_SINGLESTEP|_TIF_SECCOMP|_TIF_SYSCALL_EMU))

Definition at line 138 of file thread_info.h.

#define _TIF_WORK_SYSCALL_ENTRY
Value:

Definition at line 127 of file thread_info.h.

#define _TIF_WORK_SYSCALL_EXIT
Value:
_TIF_SYSCALL_TRACEPOINT | _TIF_NOHZ)

Definition at line 133 of file thread_info.h.

#define _TIF_X32   (1 << TIF_X32)

Definition at line 124 of file thread_info.h.

#define HAVE_SET_RESTORE_SIGMASK   1

Definition at line 247 of file thread_info.h.

#define init_stack   (init_thread_union.stack)

Definition at line 61 of file thread_info.h.

#define INIT_THREAD_INFO (   tsk)
Value:
{ \
.task = &tsk, \
.exec_domain = &default_exec_domain, \
.flags = 0, \
.cpu = 0, \
.preempt_count = INIT_PREEMPT_COUNT, \
.addr_limit = KERNEL_DS, \
.restart_block = { \
}, \
}

Definition at line 47 of file thread_info.h.

#define init_thread_info   (init_thread_union.thread_info)

Definition at line 60 of file thread_info.h.

#define KERNEL_STACK_OFFSET   (5*8)

Definition at line 199 of file thread_info.h.

#define PREEMPT_ACTIVE   0x10000000

Definition at line 160 of file thread_info.h.

#define TIF_ADDR32   29 /* 32-bit address space on 64 bits */

Definition at line 99 of file thread_info.h.

#define TIF_BLOCKSTEP   25 /* set when we want DEBUGCTLMSR_BTF */

Definition at line 96 of file thread_info.h.

#define TIF_DEBUG   21 /* uses debug registers */

Definition at line 93 of file thread_info.h.

#define TIF_FORCED_TF   24 /* true if TF in eflags artificially */

Definition at line 95 of file thread_info.h.

#define TIF_FORK   18 /* ret_from_fork */

Definition at line 90 of file thread_info.h.

#define TIF_IA32   17 /* IA32 compatibility process */

Definition at line 89 of file thread_info.h.

#define TIF_IO_BITMAP   22 /* uses I/O bitmap */

Definition at line 94 of file thread_info.h.

#define TIF_LAZY_MMU_UPDATES   27 /* task is updating the mmu lazily */

Definition at line 97 of file thread_info.h.

#define TIF_MCE_NOTIFY   10 /* notify userspace of an MCE */

Definition at line 85 of file thread_info.h.

#define TIF_MEMDIE   20 /* is terminating due to OOM killer */

Definition at line 92 of file thread_info.h.

#define TIF_NEED_RESCHED   3 /* rescheduling necessary */

Definition at line 80 of file thread_info.h.

#define TIF_NOHZ   19 /* in adaptive nohz mode */

Definition at line 91 of file thread_info.h.

#define TIF_NOTIFY_RESUME   1 /* callback before returning to user */

Definition at line 78 of file thread_info.h.

#define TIF_NOTSC   16 /* TSC is not accessible in userland */

Definition at line 88 of file thread_info.h.

#define TIF_SECCOMP   8 /* secure computing */

Definition at line 84 of file thread_info.h.

#define TIF_SIGPENDING   2 /* signal pending */

Definition at line 79 of file thread_info.h.

#define TIF_SINGLESTEP   4 /* reenable singlestep on user return*/

Definition at line 81 of file thread_info.h.

#define TIF_SYSCALL_AUDIT   7 /* syscall auditing active */

Definition at line 83 of file thread_info.h.

#define TIF_SYSCALL_EMU   6 /* syscall emulation active */

Definition at line 82 of file thread_info.h.

#define TIF_SYSCALL_TRACE   0 /* syscall trace active */

Definition at line 77 of file thread_info.h.

#define TIF_SYSCALL_TRACEPOINT   28 /* syscall tracepoint instrumentation */

Definition at line 98 of file thread_info.h.

#define TIF_UPROBE   12 /* breakpointed or singlestepping */

Definition at line 87 of file thread_info.h.

#define TIF_USER_RETURN_NOTIFY   11 /* notify kernel of userspace return */

Definition at line 86 of file thread_info.h.

#define TIF_X32   30 /* 32-bit native x86-64 binary */

Definition at line 100 of file thread_info.h.

#define TS_COMPAT   0x0002 /* 32bit syscall active (64BIT)*/

Definition at line 240 of file thread_info.h.

#define TS_POLLING
Value:
0x0004 /* idle task polling need_resched,
skip sending interrupt */

Definition at line 241 of file thread_info.h.

#define TS_RESTORE_SIGMASK   0x0008 /* restore signal mask in do_signal() */

Definition at line 242 of file thread_info.h.

#define tsk_is_polling (   t)    (task_thread_info(t)->status & TS_POLLING)

Definition at line 244 of file thread_info.h.

Function Documentation

int arch_dup_task_struct ( struct task_struct dst,
struct task_struct src 
)

Definition at line 227 of file process.c.

void arch_release_task_struct ( struct task_struct tsk)

Definition at line 47 of file process.c.

void arch_task_cache_init ( void  )

Definition at line 52 of file process.c.

DECLARE_PER_CPU ( unsigned  long,
kernel_stack   
)

Variable Documentation