aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/include/usbh/list.h
diff options
context:
space:
mode:
Diffstat (limited to 'os/hal/include/usbh/list.h')
-rw-r--r--os/hal/include/usbh/list.h5
1 files changed, 1 insertions, 4 deletions
diff --git a/os/hal/include/usbh/list.h b/os/hal/include/usbh/list.h
index 4eceacd..317e51b 100644
--- a/os/hal/include/usbh/list.h
+++ b/os/hal/include/usbh/list.h
@@ -7,11 +7,8 @@
#define offsetof(TYPE, MEMBER) ((size_t) &((TYPE *)0)->MEMBER)
#endif
-#define container_of(ptr, type, member) ((type *)(void *)((char *)(ptr) - offsetof(type, member)))
#ifndef container_of
-#define container_of(ptr, type, member) ({ \
- const typeof(((type *)0)->member) * __mptr = (ptr); \
- (type *)((char *)__mptr - offsetof(type, member)); })
+#define container_of(ptr, type, member) ((type *)(void *)((char *)(ptr) - offsetof(type, member)))
#endif
/*