[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lwip-users] LWIP crashes with memp_sanity
From: |
Konrad, Guido |
Subject: |
[lwip-users] LWIP crashes with memp_sanity |
Date: |
Mon, 7 Apr 2003 11:35:17 +0200 |
Hi all,
I have ported lwip 0.5.3 to PowerPC (MPC8245) with Intel 82559 and uC/OS II.
I thought that all stuff works fine but after a few day of permanent usage,
the
stack crashes with "Assertion "memp_sanity: c < 0" failed at line 144 in
lwip/src/core/memp.c"
Giving out the memory statistic (during runtime, before crash) will result
in the following:
MEMP
Avail Used Max Err
MEMP_NUM_PBUF: 16 0 0 0
MEMP_NUM_UDP_PCB: 8 1 1 0
MEMP_NUM_TCP_PCB: 8 0 8 2796
MEMP_NUM_TCP_PCB_LISTEN: 8 3 3 0
MEMP_NUM_TCP_SEG: 16 0 2 0
MEMP_NUM_NETBUF: 40 0 1 0
MEMP_NUM_NETCONN: 40 4 5 0
MEMP_NUM_API_MSG: 40 0 4 0
MEMP_NUM_TCPIP_MSG: 60 0 7 0
MEMP_NUM_SYS_TIMEOUT: 40 2 2 0
MEM
Avail Used Max Err
50176 593 1745 0
It seems to me that the TCP_PCB blocks are not freed regularily. Freeing is
than
forced in tcp_alloc. Can this cause a problem? (Perhaps because an other
thread is
still accessing the memory?)
I use a multithreaded stack. Therefore I replaced all memp_alloc and
memp_free by
its protected variants memp_allocp and memp_freep. But this did not help.
I really appreciate your help. What can I do to solve this problem?
-- Guido Konrad
- [lwip-users] LWIP crashes with memp_sanity,
Konrad, Guido <=