tools/mtd-utils: update to mtd-utils-20101001, fix FreeBSD (and hopefully Darwin...
[openwrt/staging/chunkeey.git] / tools / mtd-utils / patches / 110-portability.patch
index d35b44658713bce48fad05776c137add4e5399f9..43b4faaca6aa60535ce455a62d6429452c0f5a83 100644 (file)
  
  struct rb_node
  {
-@@ -131,7 +130,9 @@ static inline void rb_set_color(struct r
- #define RB_ROOT       (struct rb_root) { NULL, }
-+#ifndef offsetof
- #define offsetof(TYPE, MEMBER) ((size_t) &((TYPE *)0)->MEMBER)
-+#endif
- #define container_of(ptr, type, member) ({                      \
-         const typeof( ((type *)0)->member ) *__mptr = (ptr);    \
 --- a/include/mtd/ubi-media.h
 +++ b/include/mtd/ubi-media.h
 @@ -30,7 +30,15 @@