青青草原综合久久大伊人导航_色综合久久天天综合_日日噜噜夜夜狠狠久久丁香五月_热久久这里只有精品

小默

【LKD】進程管理

linux-2.6.10

--------------------

x86上,thread_info結構定義,在asm/thread_info.h中
struct thread_info {
    
struct task_struct    *task;        /* main task structure */
    
struct exec_domain    *exec_domain;    /* execution domain */
    unsigned 
long        flags;        /* low level flags */
    unsigned 
long        status;        /* thread-synchronous flags */
    __u32            cpu;        
/* current CPU */
    __s32            preempt_count; 
/* 0 => preemptable, <0 => BUG */


    mm_segment_t        addr_limit;    
/* thread address space:
                            0-0xBFFFFFFF for user-thead
                           0-0xFFFFFFFF for kernel-thread
                        
*/
    
struct restart_block    restart_block;

    unsigned 
long           previous_esp;   /* ESP of the previous stack in case
                           of nested (IRQ) stacks
                        
*/
    __u8            supervisor_stack[
0];
};
thread_info結構在進程棧尾端分配

---------------------------------------
//???
/* how to get the thread information struct from C */
static inline struct thread_info *current_thread_info(void)
{
    
struct thread_info *ti;
    __asm__(
"andl %%esp,%0; ":"=r" (ti) : "0" (~(THREAD_SIZE - 1)));
    
return ti;
}

---------------------------------------
進程描述符
struct task_struct {
    
volatile long state;    /* -1 unrunnable, 0 runnable, >0 stopped */
    
struct thread_info *thread_info;
    atomic_t usage;
    unsigned 
long flags;    /* per process flags, defined below */
    unsigned 
long ptrace;

    
int lock_depth;        /* Lock depth */

    
int prio, static_prio;
    
struct list_head run_list;
    prio_array_t 
*array;

    unsigned 
long sleep_avg;
    
long interactive_credit;
    unsigned 
long long timestamp, last_ran;
    
int activated;

    unsigned 
long policy;
    cpumask_t cpus_allowed;
    unsigned 
int time_slice, first_time_slice;

#ifdef CONFIG_SCHEDSTATS
    
struct sched_info sched_info;
#endif

    
struct list_head tasks;
    
/*
     * ptrace_list/ptrace_children forms the list of my children
     * that were stolen by a ptracer.
     
*/
    
struct list_head ptrace_children;
    
struct list_head ptrace_list;

    
struct mm_struct *mm, *active_mm;

/* task state */
    
struct linux_binfmt *binfmt;
    
long exit_state;
    
int exit_code, exit_signal;
    
int pdeath_signal;  /*  The signal sent when the parent dies  */
    
/* ??? */
    unsigned 
long personality;
    unsigned did_exec:
1;
    pid_t pid;
    pid_t tgid;
    
/* 
     * pointers to (original) parent process, youngest child, younger sibling,
     * older sibling, respectively.  (p->father can be replaced with 
     * p->parent->pid)
     
*/
    
struct task_struct *real_parent; /* real parent process (when being debugged) */
    
struct task_struct *parent;    /* parent process */
    
/*
     * children/sibling forms the list of my children plus the
     * tasks I'm ptracing.
     
*/
    
struct list_head children;    /* list of my children */
    
struct list_head sibling;    /* linkage in my parent's children list */
    
struct task_struct *group_leader;    /* threadgroup leader */

    
/* PID/PID hash table linkage. */
    
struct pid pids[PIDTYPE_MAX];

    wait_queue_head_t wait_chldexit;    
/* for wait4() */
    
struct completion *vfork_done;        /* for vfork() */
    
int __user *set_child_tid;        /* CLONE_CHILD_SETTID */
    
int __user *clear_child_tid;        /* CLONE_CHILD_CLEARTID */

    unsigned 
long rt_priority;
    unsigned 
long it_real_value, it_prof_value, it_virt_value;
    unsigned 
long it_real_incr, it_prof_incr, it_virt_incr;
    
struct timer_list real_timer;
    unsigned 
long utime, stime;
    unsigned 
long nvcsw, nivcsw; /* context switch counts */
    
struct timespec start_time;
/* mm fault and swap info: this can arguably be seen as either mm-specific or thread-specific */
    unsigned 
long min_flt, maj_flt;
/* process credentials */
    uid_t uid,euid,suid,fsuid;
    gid_t gid,egid,sgid,fsgid;
    
struct group_info *group_info;
    kernel_cap_t   cap_effective, cap_inheritable, cap_permitted;
    unsigned keep_capabilities:
1;
    
struct user_struct *user;
#ifdef CONFIG_KEYS
    
struct key *session_keyring;    /* keyring inherited over fork */
    
struct key *process_keyring;    /* keyring private to this process (CLONE_THREAD) */
    
struct key *thread_keyring;    /* keyring private to this thread */
#endif
    unsigned 
short used_math;
    
char comm[16];
/* file system info */
    
int link_count, total_link_count;
/* ipc stuff */
    
struct sysv_sem sysvsem;
/* CPU-specific state of this task */
    
struct thread_struct thread;
/* filesystem information */
    
struct fs_struct *fs;
/* open file information */
    
struct files_struct *files;
/* namespace */
    
struct namespace *namespace;
/* signal handlers */
    
struct signal_struct *signal;
    
struct sighand_struct *sighand;

    sigset_t blocked, real_blocked;
    
struct sigpending pending;

    unsigned 
long sas_ss_sp;
    size_t sas_ss_size;
    
int (*notifier)(void *priv);
    
void *notifier_data;
    sigset_t 
*notifier_mask;
    
    
void *security;
    
struct audit_context *audit_context;

/* Thread group tracking */
       u32 parent_exec_id;
       u32 self_exec_id;
/* Protection of (de-)allocation: mm, files, fs, tty, keyrings */
    spinlock_t alloc_lock;
/* Protection of proc_dentry: nesting proc_lock, dcache_lock, write_lock_irq(&tasklist_lock); */
    spinlock_t proc_lock;
/* context-switch lock */
    spinlock_t switch_lock;

/* journalling filesystem info */
    
void *journal_info;

/* VM state */
    
struct reclaim_state *reclaim_state;

    
struct dentry *proc_dentry;
    
struct backing_dev_info *backing_dev_info;

    
struct io_context *io_context;

    unsigned 
long ptrace_message;
    siginfo_t 
*last_siginfo; /* For ptrace use.  */
/*
 * current io wait handle: wait queue entry to use for io waits
 * If this thread is processing aio, this points at the waitqueue
 * inside the currently handled kiocb. It may be NULL (i.e. default
 * to a stack based synchronous wait) if its doing sync IO.
 
*/
    wait_queue_t 
*io_wait;
#ifdef CONFIG_NUMA
      
struct mempolicy *mempolicy;
      
short il_next;        /* could be shared with used_math */
#endif
};

posted on 2010-05-16 21:38 小默 閱讀(377) 評論(0)  編輯 收藏 引用 所屬分類: Linux

導航

統計

留言簿(13)

隨筆分類(287)

隨筆檔案(289)

漏洞

搜索

積分與排名

最新評論

閱讀排行榜

青青草原综合久久大伊人导航_色综合久久天天综合_日日噜噜夜夜狠狠久久丁香五月_热久久这里只有精品
  • <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>
            久久久夜精品| 欧美**人妖| 午夜亚洲激情| 欧美在线视频在线播放完整版免费观看| 亚洲专区一区| 久久久亚洲高清| 亚洲国产精品一区二区三区| 韩日在线一区| 91久久在线播放| 午夜精品久久久久久| 亚洲天堂成人| 久久国产婷婷国产香蕉| 欧美福利小视频| 国产精品无人区| 亚洲美女黄网| 久久久久www| 亚洲天堂男人| 狠狠色丁香久久婷婷综合丁香| 美女脱光内衣内裤视频久久影院| 亚洲伦理网站| 另类激情亚洲| 国产亚洲欧美aaaa| 亚洲婷婷综合久久一本伊一区| 久久精品在线播放| 麻豆乱码国产一区二区三区| 国产麻豆精品视频| 亚洲一区二区三区精品在线| 欧美高清视频一区| 久久精品91久久香蕉加勒比| 亚洲黄色在线观看| 女女同性精品视频| 欧美视频在线不卡| 一本色道久久综合亚洲二区三区| 欧美护士18xxxxhd| 久久久精品一区二区三区| 国产日韩综合一区二区性色av| 亚洲欧美日韩人成在线播放| 99精品久久| 欧美高清hd18日本| 久久精品国产77777蜜臀| 亚洲性图久久| 亚洲区国产区| 性久久久久久久久| 国产日韩一区二区| 亚洲每日更新| 亚洲国产一区视频| 亚洲欧美电影院| 国产视频久久网| 日韩视频精品在线| 欧美午夜视频一区二区| 亚洲综合社区| 欧美成人午夜剧场免费观看| 亚洲免费成人av| 久久久久久亚洲精品杨幂换脸| 亚洲一区二区三区中文字幕在线| 美国成人毛片| 美女91精品| 国产精品专区h在线观看| 亚洲日本无吗高清不卡| 国产精品久久久久毛片大屁完整版| 亚洲欧美韩国| 欧美日韩午夜在线视频| 午夜精品美女自拍福到在线| 欧美日韩一区三区四区| 亚洲激精日韩激精欧美精品| 国产精品国产一区二区| 久久精品亚洲乱码伦伦中文 | 久久国产精品一区二区三区四区| 欧美精选一区| 欧美一区二区三区视频| 久久手机精品视频| 99成人在线| 亚洲欧美一区二区视频| 亚洲成人在线网| 最新高清无码专区| 亚洲精品美女在线| 欧美亚洲在线观看| 亚洲激情二区| 欧美波霸影院| 99精品欧美一区二区蜜桃免费| 日韩视频免费在线| 欧美日韩视频| 亚洲无人区一区| 欧美在线视频在线播放完整版免费观看 | 亚洲国产精品一区在线观看不卡| 亚洲日本电影在线| 欧美精品久久久久久久久久| 久久久久久亚洲精品中文字幕| 国产一区二区日韩| 久久人人97超碰国产公开结果| 欧美大片18| 亚洲桃色在线一区| 国产日韩欧美a| 久久久噜噜噜久久中文字幕色伊伊| 欧美激情亚洲激情| 亚洲香蕉视频| 国产综合色产在线精品| 亚洲一区二区黄色| 一个色综合av| 国产欧美一区二区色老头 | 一区二区精品在线| 老鸭窝亚洲一区二区三区| 欧美激情一区二区三区成人 | 国产一区二区三区丝袜| 欧美.com| 亚洲成色999久久网站| 国产麻豆91精品| 久久资源在线| 亚洲欧美另类在线观看| 欧美二区在线观看| 午夜精品久久久久久99热| 亚洲成在人线av| 国产精品久久久久久久久免费樱桃| 欧美一区国产在线| 亚洲美女视频| 久久一区二区三区国产精品| 国产日韩一区二区三区在线播放 | 香蕉av福利精品导航| 91久久在线| 久久一区激情| 亚洲欧美中日韩| 亚洲免费av片| 影音先锋久久| 欧美国产精品v| 久久国产精品第一页| aa级大片欧美| 亚洲国产日韩一区二区| 久久久人成影片一区二区三区| 这里只有精品电影| 亚洲娇小video精品| 国产一区三区三区| 国产精品你懂的在线欣赏| 欧美激情成人在线| 免费中文日韩| 久久精品成人| 久久国产主播| 欧美一区不卡| 欧美一级黄色录像| 亚洲欧美精品在线观看| 亚洲午夜在线视频| 亚洲婷婷在线| 亚洲欧美精品suv| 亚洲一区免费网站| 亚洲欧美日韩国产成人| 亚洲特级毛片| 亚洲一区二区毛片| 亚洲欧美综合国产精品一区| 亚洲已满18点击进入久久| 亚洲视频自拍偷拍| 亚洲女女女同性video| 亚洲欧美精品在线| 欧美在线高清视频| 亚洲精品免费看| 亚洲美女一区| 亚洲无线观看| 午夜日韩电影| 久久精品91| 麻豆av一区二区三区久久| 欧美成年人视频网站| 欧美激情va永久在线播放| 欧美日韩色一区| 国产精品视区| 又紧又大又爽精品一区二区| 亚洲国产欧美精品| 一区二区高清视频| 午夜老司机精品| 玖玖综合伊人| 欧美专区在线观看一区| 久久精品国产一区二区电影| 久久这里有精品视频| 亚洲国产日韩一区| 亚洲天堂免费观看| 久久免费的精品国产v∧| 欧美国产日韩一区| 国产精品九九| 亚洲成色www久久网站| 99精品热视频| 欧美在线啊v| 欧美激情免费在线| 亚洲免费观看| 久久国产高清| 欧美日韩中文| 怡红院av一区二区三区| 这里只有视频精品| 免费日韩精品中文字幕视频在线| 亚洲精品中文字幕有码专区| 午夜精品久久久久久久久| 免费观看日韩| 国产免费亚洲高清| 99精品视频免费在线观看| 久久se精品一区二区| 亚洲精品久久久久中文字幕欢迎你 | 亚洲欧美一区二区在线观看| 麻豆成人91精品二区三区| 亚洲美女中文字幕| 久久综合给合| 国产综合婷婷| 午夜精品美女久久久久av福利| 亚洲第一在线综合在线| 欧美成人国产va精品日本一级|