mirror of
https://github.com/alsa-project/alsa-lib.git
synced 2025-10-29 05:40:25 -04:00
Encapsulated conf API
This commit is contained in:
parent
8f0cb26fdf
commit
3e091c8822
26 changed files with 473 additions and 404 deletions
|
|
@ -144,4 +144,14 @@ static __inline__ void list_splice(struct list_head *list, struct list_head *hea
|
|||
#define list_for_each(pos, head) \
|
||||
for (pos = (head)->next; pos != (head); pos = pos->next)
|
||||
|
||||
/**
|
||||
* list_entry - get the struct for this entry
|
||||
* @ptr: the &struct list_head pointer.
|
||||
* @type: the type of the struct this is embedded in.
|
||||
* @member: the name of the list_struct within the struct.
|
||||
*/
|
||||
#define list_entry(ptr, type, member) \
|
||||
((type *)((char *)(ptr)-(unsigned long)(&((type *)0)->member)))
|
||||
|
||||
|
||||
#endif /* _LIST_H */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue