summaryrefslogtreecommitdiff
path: root/modules/sparkler/container.h
blob: a3779e8b625a35a18153dc4a3a3a69bce117f0c4 (plain)
1
2
3
4
5
6
7
8
9
10
11
#ifndef _CONTAINER_H
#define _CONTAINER_H

#include <stddef.h>

#ifndef container_of
#define container_of(_ptr, _type, _member) \
	(_type *)((void *)(_ptr) - offsetof(_type, _member))
#endif

#endif
© All Rights Reserved