Lines Matching refs:member
168 * xge_container_of - Given a member, return the containing structure.
169 * @ptr: the pointer to the member.
171 * @member: the name of the member within the struct.
173 * Cast a member of a structure out to the containing structure.
175 #define xge_container_of(ptr, type, member) ({ \
176 __typeof( ((type *)0)->member ) *__mptr = (ptr); \
177 (type *)(void *)( (char *)__mptr - ((size_t) &((type *)0)->member) );})
180 #define xge_container_of(ptr, type, member) \
181 ((type*)(void*)((char*)(ptr) - ((size_t) &((type *)0)->member)))
185 * xge_offsetof - Offset of the member in the containing structure.
187 * @m: the name of the member within the struct.
189 * Return the offset of the member @m in the structure @t.