lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lwip-users] Cable disconnect and restarting LWIP


From: Trampas Stern
Subject: [lwip-users] Cable disconnect and restarting LWIP
Date: Tue, 5 May 2020 19:25:35 -0400

So when I detect a cable disconnect and reconnect I want to restart LWIP.  I have noticed that several things appear to go wrong, when trying to restart LWIP. 

1. httpd has no way to close the port.  Hence even with an lwip_init() it still thought port was used. 
2. When restarting timeouts with sys_timeouts_init() the next_timeout variable was not set to NULL. which cause the sys_timeout_abs() to sit in for loop forever. 
3. in mem_init() I zero the memory pool as I was getting some double free errors. I think this might have helped mask many other issues in the code. 

It seems that much of the code assumes the processor will be reset  and does not fully initializes variables in the init() routines.  I am sure I did not find all the problems. 

I was wondering how much of the code assumed on reset the memory (variables)  are reset to zero by default?  For example  current_timeout_due_time and tcpip_tcp_timer_active...  


Thanks
Trampas




reply via email to

[Prev in Thread] Current Thread [Next in Thread]