ifeq ($(CONFIG_LWIP),y)
# lwIP library
-LWC := $(shell find $(LWIPDIR)/ -type f -name '*.c')
+LWC := $(shell find $(LWIPDIR)/src -type f -name '*.c')
LWC := $(filter-out %6.c %ip6_addr.c %ethernetif.c, $(LWC))
LWO := $(patsubst %.c,%.o,$(LWC))
LWO += $(OBJ_DIR)/lwip-arch.o
- to build it just type make.
-- to build it with TCP/IP support, download LWIP 1.3 source code and type
+- to build it with TCP/IP support, download LWIP 1.3.2 source code and type
make LWIPDIR=/path/to/lwip/source
#include <arch_wordsize.h>
+#define BYTE_ORDER __BYTE_ORDER
+#define BIG_ENDIAN __BIG_ENDIAN
+#define LITTLE_ENDIAN __LITTLE_ENDIAN
+
#endif /* endian.h */
#include <limits.h>
#define DEFAULT_ALIGN (sizeof(unsigned long))
-#define malloc(size) _xmalloc(size, DEFAULT_ALIGN)
-#define free(ptr) xfree(ptr)
-#define realloc(ptr, size) _realloc(ptr, size)
-/* Free any of the above. */
+extern void *malloc(size_t size);
+extern void *realloc(void *ptr, size_t size);
+extern void free(void *ptr);
+
+/* Free memory from any xmalloc*() call. */
extern void xfree(const void *);
/* Underlying functions */
extern void *_xmalloc(size_t size, size_t align);
-extern void *_realloc(void *ptr, size_t size);
#endif
/* spin_unlock_irqrestore(&freelist_lock, flags); */
}
-void *_realloc(void *ptr, size_t size)
+void *malloc(size_t size)
+{
+ return _xmalloc(size, DEFAULT_ALIGN);
+}
+
+void *realloc(void *ptr, size_t size)
{
void *new;
struct xmalloc_hdr *hdr;
return new;
}
+
+void free(void *ptr)
+{
+ xfree(ptr);
+}
#endif
/*