xenomai 3.0.2 -任务切换《xnarch_switch_to》
来源:互联网 发布:淘宝登录注册流程 编辑:程序博客网 时间:2024/06/06 03:21
1.xnarch_switch_to
void xnarch_switch_to(struct xnthread *out, struct xnthread *in){ struct xnarchtcb *out_tcb = &out->tcb, *in_tcb = &in->tcb; struct mm_struct *prev_mm, *next_mm; struct task_struct *next; next = in_tcb->core.host_task; prev_mm = out_tcb->core.active_mm; next_mm = in_tcb->core.mm; //首先,检查是否为内核线程还是用户进程 if (next_mm == NULL) { //kernel thread,copy mm from previous process. in_tcb->core.active_mm = prev_mm; enter_lazy_tlb(prev_mm, next); } else { ipipe_switch_mm_head(prev_mm, next_mm, next); /* * We might be switching back to the root thread, * which we preempted earlier, shortly after "current" * dropped its mm context in the do_exit() path * (next->mm == NULL). In that particular case, the * kernel expects a lazy TLB state for leaving the mm. */ if (next->mm == NULL) enter_lazy_tlb(prev_mm, next); } __asm_thread_s.witch(out_tcb->core.tip, in_tcb->core.tip);}
0 0
- xenomai 3.0.2 -任务切换《xnarch_switch_to》
- Xenomai 的模式切换浅析
- xenomai-3.0 初始化
- xenomai
- Xenomai 检测某一线程从Xenomai域切换到Linux域
- 任务切换
- 任务切换
- 任务切换
- 任务切换
- 编译 linux kernel & xenomai 2/3
- 任务,任务的切换,(TCB)
- FreeRTOS 任务调度 任务切换
- 任务间切换
- ucos(一) 任务切换
- ucos的任务切换
- 任务切换过程。
- UCOS_STM32的任务切换
- FreeRTOS任务切换解析
- 原 GCC一些有用的技巧
- 利用proguard对java web工程代码混淆
- Spring Data MongoDB 查询指定字段
- MySQL5.5.42 主从复制架构搭建
- LINQ表达式实例复习
- xenomai 3.0.2 -任务切换《xnarch_switch_to》
- Android 百度地图打包后获取不到地址问题
- 【NOIP2015提高组Day1】信息传递
- “三个月就是一年”——程序员的时间观念
- Oracle 使用spool导出 sqlldr导入后少数据情况
- 第二周项目3-两种排序算法的运行时间
- iOS arm64 armv7 i386 架构
- 正则表达式反斜杠匹配问题
- 数组前移