2011年12月29日

container_of()宏解析

摘要: 在内核中很多地方都会使用到宏container_of()。 都知道宏container_of()的作用是:根据结构体中一个域成员变量的指针获取指向整个结构体的指针、现在来分析这个宏是如何实现的; 内核中container_of()代码如下: /**... 阅读全文

posted @ 2011-12-29 23:05 YoungerChina 阅读(286) 评论(0) 推荐(0) 编辑

导航