Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions | Variables
processor.h File Reference
#include <linux/cpumask.h>
#include <linux/threads.h>
#include <asm/segment.h>

Go to the source code of this file.

Data Structures

struct  thread_struct
 

Macros

#define current_text_addr()   ({ __label__ _l; _l: &&_l; })
 
#define cpu_relax()   barrier()
 
#define release_thread(thread)   do {} while (0)
 
#define TASK_SIZE   0x7fff8000UL
 
#define TASK_UNMAPPED_BASE   ((TASK_SIZE / 3) & ~(PAGE_SIZE))
 
#define INIT_THREAD
 
#define kstk_tos(tsk)   ((unsigned long)task_stack_page(tsk) + THREAD_SIZE - 32)
 
#define task_pt_regs(tsk)   ((struct pt_regs *)kstk_tos(tsk) - 1)
 
#define KSTK_EIP(tsk)   (task_pt_regs(tsk)->cp0_epc)
 
#define KSTK_ESP(tsk)   (task_pt_regs(tsk)->regs[29])
 

Functions

long kernel_thread (int(*fn)(void *), void *arg, unsigned long flags)
 
unsigned long thread_saved_pc (struct task_struct *tsk)
 
void start_thread (struct pt_regs *regs, unsigned long pc, unsigned long sp)
 
unsigned long get_wchan (struct task_struct *p)
 

Variables

void(* cpu_wait )(void)
 

Macro Definition Documentation

#define cpu_relax (   void)    barrier()

Definition at line 27 of file processor.h.

#define current_text_addr (   void)    ({ __label__ _l; _l: &&_l; })

Definition at line 25 of file processor.h.

#define INIT_THREAD
Value:
{ \
.reg0 = 0, \
.reg2 = 0, \
.reg3 = 0, \
.reg12 = 0, \
.reg13 = 0, \
.reg14 = 0, \
.reg15 = 0, \
.reg16 = 0, \
.reg17 = 0, \
.reg18 = 0, \
.reg19 = 0, \
.reg20 = 0, \
.reg21 = 0, \
.cp0_psr = 0, \
.error_code = 0, \
.trap_no = 0, \
}

Definition at line 79 of file processor.h.

#define KSTK_EIP (   tsk)    (task_pt_regs(tsk)->cp0_epc)

Definition at line 102 of file processor.h.

#define KSTK_ESP (   tsk)    (task_pt_regs(tsk)->regs[29])

Definition at line 103 of file processor.h.

#define kstk_tos (   tsk)    ((unsigned long)task_stack_page(tsk) + THREAD_SIZE - 32)

Definition at line 98 of file processor.h.

#define release_thread (   thread)    do {} while (0)

Definition at line 28 of file processor.h.

#define task_pt_regs (   tsk)    ((struct pt_regs *)kstk_tos(tsk) - 1)

Definition at line 100 of file processor.h.

#define TASK_SIZE   0x7fff8000UL

Definition at line 34 of file processor.h.

#define TASK_UNMAPPED_BASE   ((TASK_SIZE / 3) & ~(PAGE_SIZE))

Definition at line 40 of file processor.h.

Function Documentation

unsigned long get_wchan ( struct task_struct p)

Definition at line 419 of file process.c.

long kernel_thread ( int(*)(void *)  fn,
void arg,
unsigned long  flags 
)

Definition at line 333 of file process.c.

void start_thread ( struct pt_regs regs,
unsigned long  pc,
unsigned long  sp 
)

Definition at line 204 of file process.c.

unsigned long thread_saved_pc ( struct task_struct tsk)

Definition at line 404 of file process.c.

Variable Documentation

void(* cpu_wait)(void)

Definition at line 37 of file cpu-probe.c.