浏览代码

[include] fix comment for rt_container_of

rewine 2 年之前
父节点
当前提交
a638a879fb
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      include/rtservice.h

+ 2 - 2
include/rtservice.h

@@ -27,8 +27,8 @@ extern "C" {
 /**@{*/
 /**@{*/
 
 
 /**
 /**
- * rt_container_of - return the member address of ptr, if the type of ptr is the
- * struct type.
+ * rt_container_of - return the start address of struct type, while ptr is the
+ * member of struct type.
  */
  */
 #define rt_container_of(ptr, type, member) \
 #define rt_container_of(ptr, type, member) \
     ((type *)((char *)(ptr) - (unsigned long)(&((type *)0)->member)))
     ((type *)((char *)(ptr) - (unsigned long)(&((type *)0)->member)))