看来对softirq的理解还不够深入,呵呵。
注释就没好好看。
/*
- No shared variables, all the data are CPU local.
- If a softirq needs serialization, let it serialize itself
by its own spinlocks.
- Even if softirq is serialized, only local cpu is marked for
execution. Hence, we get something sort of weak cpu binding.
Though it is still not clear, will it result in better locality
or will not.
Examples:
- NET RX softirq. It is multithreaded and does not require
any global serialization.
- NET TX softirq. It kicks software netdevice queues, hence
it is logically serialized per device, but this serialization
is invisible to common code.
- Tasklets: serialized wrt itself.
*/
softirq是每个CPU都有一个独立的softirq,由于数据结构是per cpu的,因而不需要进行复杂的控制。
阅读(1833) | 评论(0) | 转发(0) |