摘要: 00001 #define move_to_user_mode() \00002 __asm__ ("movl %%esp,%%eax\n\t" \00003 "pushl $0x17\n\t" \00004 "pushl %%eax\n\t" \00005 "pushfl\n\t" \00006 "pushl $0x0f\n\t" \00007 "pushl $1f\n\t" \00008 "iret\n" \//特权变换iret00009 " 阅读全文
posted @ 2013-08-13 05:51 caesarxu 阅读(628) 评论(0) 推荐(0) 编辑
摘要: 00053 union task_union {00054 struct task_struct task;00055 char stack[PAGE_SIZE];00056 };00057 00058 static union task_union init_task = {INIT_TASK,};//2013-08-13这里是否确定了???????????,任务0的堆栈空间,开始的内核后来的用户空间//2013-08-13 12:07:25这里确定的是任务o的,内核空间(当特权级从0->3后,任务0的内核态堆栈空间就在这)00059 00060 long volatile ... 阅读全文
posted @ 2013-08-13 05:39 caesarxu 阅读(478) 评论(0) 推荐(0) 编辑