博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
中断API之__tasklet_schedule
阅读量:4213 次
发布时间:2019-05-26

本文共 572 字,大约阅读时间需要 1 分钟。

void __tasklet_schedule(struct tasklet_struct *t)数的主要作用是将参数t代表的软中断  添加到向量tasklet_vec的尾部,并触发一个软中断void __tasklet_schedule(struct tasklet_struct *t){	unsigned long flags;	#禁止本地中断	local_irq_save(flags);	#由于t要被加入tasklet_vec的尾部,因此t->next要被置null	t->next = NULL;	#将t添加到tasklet_vec.tail的尾部	*__this_cpu_read(tasklet_vec.tail) = t;	__this_cpu_write(tasklet_vec.tail, &(t->next));	#触发软件中断	raise_softirq_irqoff(TASKLET_SOFTIRQ);	#使能本地中断	local_irq_restore(flags);}这里的tasklet_vec是一个percpu变量.其定义如下:从禁止本地中断也可以推出来tasklet_vec 应该是一个本地变量static DEFINE_PER_CPU(struct tasklet_head, tasklet_vec);

转载地址:http://frjmi.baihongyu.com/

你可能感兴趣的文章
【ReactNative】真机上无法调试 could not connect to development server
查看>>
【XCode 4.6】常用快捷键 特别是格式化代码ctrl+i
查看>>
【iOS游戏开发】icon那点事 之 图标设计(三)
查看>>
【IOS游戏开发】之测试发布(Distribution)
查看>>
【IOS游戏开发】之IPA破解原理
查看>>
【一天一道LeetCode】#45. Jump Game II
查看>>
【一天一道LeetCode】#56. Merge Intervals
查看>>
【一天一道LeetCode】#58. Length of Last Word
查看>>
【一天一道LeetCode】#59. Spiral Matrix II
查看>>
【一天一道LeetCode】#30. Substring with Concatenation of All Words
查看>>
【一天一道LeetCode】#60. Permutation Sequence.
查看>>
【unix网络编程第三版】阅读笔记(二):套接字编程简介
查看>>
【一天一道LeetCode】#116. Populating Next Right Pointers in Each Node
查看>>
【一天一道LeetCode】#118. Pascal's Triangle
查看>>
JAVA实现文件树
查看>>
ebay api - GetUserDisputes 函数
查看>>
ebay api GetMyMessages 函数
查看>>
手动12 - 安装php加速器 Zend OPcache
查看>>
set theme -yii2
查看>>
yii2 - controller
查看>>