三种 bottom half的实现方式 softirqs, tasklets, work queue 及之间的比较

The following mechanisms are available in the kernel to defer work to a bottom half: softirqs, tasklets, and work queues .

 

 

Softirqs are the basic bottom half mechanism and have strong locking requirements. They are used only by a
few performance-sensitive subsystems such as the networking layer, SCSI layer, and kernel timers.

 

Tasklets are built on top of softirqs and are easier to use. It's recommended to use tasklets unless you have crucial
scalability or speed requirements.

 

A primary difference between a softirq and a tasklet is that the former is reentrant whereas the latter isn't. Different instances of a softirq can run simultaneously on different processors, but that is not the case with tasklets.

 

Work queues are a third way to defer work from interrupt handlers. They execute in process context and are
allowed to sleep , so they can use drowsy functions such as mutexes.

 

 

 

 

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值