[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [lwip-users] Infinite hang in tcp_slowtmr()
From: |
Sylvain Rochet |
Subject: |
Re: [lwip-users] Infinite hang in tcp_slowtmr() |
Date: |
Tue, 13 Oct 2015 11:48:34 +0200 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
Hi Stephen,
On Tue, Oct 13, 2015 at 10:15:42AM +0200, Sylvain Rochet wrote:
> On Mon, Oct 12, 2015 at 04:59:19PM -0500, Stephen Cowell wrote:
> > On 10/12/2015 3:41 PM, Sylvain Rochet wrote:
> > >
> > > On Mon, Oct 12, 2015 at 02:51:14PM -0500, Stephen Cowell wrote:
> > > > I find that I sometimes get an infinite loop when stepping to
> > > > pcb->next...
> > > I didn't have to read further. As usual, it looks like a broken port or
> > > usage which violate lwIP threading model.
> > >
> > > Summary:
> > >
> > > - Do *NOT* call anything in interrupt context, nothing, never,
> > > absolutely never, use your OS semaphore signaling to an
> > > Ethernet/serial/… RX thread
> >
> > I don't think I'm doing that, Sylvain... this is non-OS, so there
> > are no 'threads'. Atmel wrote the port. I'm running sntp and ftpd, they
> > hook in using their own _init() routines that have not been
> > modified.
>
> But there are probably interrupts, which is even worse. Could you first
> check that no lwIP functions are called in interrupts contexts ?
> Probably around the macb driver.
>
> If I have time I will fetch the Atmel port for SAM4E/bare-metal and
> take a short look at it.
It looks sane from a quick look. I don't really understand why there are
not using sys_check_timeouts() and rewrote everything in the ethernet.c
"static timers_info_t gs_timers_table[]" stuff. Since you are having
issue in timers context could you check this part is ok ? Removing all
the Atmel timers stuff and calling sys_check_timeouts() in the main loop
could be an easy check.
Sylvain
- [lwip-users] Is tcp_err()-callback optional?, Karl Karpfen, 2015/10/12
- Re: [lwip-users] Is tcp_err()-callback optional?, Simon Goldschmidt, 2015/10/15
- [lwip-users] Infinite hang in tcp_slowtmr(), Stephen Cowell, 2015/10/15
- Re: [lwip-users] Infinite hang in tcp_slowtmr(), Sylvain Rochet, 2015/10/12
- Re: [lwip-users] Infinite hang in tcp_slowtmr(), Stephen Cowell, 2015/10/15
- Re: [lwip-users] Infinite hang in tcp_slowtmr(), Sylvain Rochet, 2015/10/13
- Re: [lwip-users] Infinite hang in tcp_slowtmr(),
Sylvain Rochet <=
- Re: [lwip-users] Infinite hang in tcp_slowtmr(), Enrico Murador - Research & Development - CET, 2015/10/14
- Re: [lwip-users] Infinite hang in tcp_slowtmr(), Stephen Cowell, 2015/10/14
- Re: [lwip-users] Infinite hang in tcp_slowtmr(), Enrico Murador - Research & Development - CET, 2015/10/14
- Re: [lwip-users] Infinite hang in tcp_slowtmr(), Sylvain Rochet, 2015/10/14
- Re: [lwip-users] Infinite hang in tcp_slowtmr(), Dinesh Pandey, 2015/10/23
- Re: [lwip-users] Infinite hang in tcp_slowtmr(), Dinesh Pandey, 2015/10/29
- Re: [lwip-users] Infinite hang in tcp_slowtmr(), Sylvain Rochet, 2015/10/29