[ECOS] RE: Trouble using lwIP (driver crash...)

Gary Thomas gary@chez-thomas.org
Wed Apr 5 14:43:00 GMT 2006


On Wed, 2006-04-05 at 10:34 -0400, Michael Grimard wrote:
> This is the call stack of the recursion:
> 
> input_thread()
> i82559_deliver()
> PacketRxReady()
> eth_drv_recv()
> ecosif_input()
> etharp_arp_input()
> low_level_output()
> eth_drv_send()
> i82559_can_send()
> -->PacketRxReady
> eth_drv_recv()
> ecosif_input()
> ...
> 
> 
> So the recursion happens in i82559_can_send() when it calls PacketRxReady().

I don't see the point of calling PacketRxReady() from i82559_can_send().
The point of "can_send()" is to determine of the device can accept any
more packets *to transmit* - received packets should not be part of that
calculation.

Try removing that call from i82559_can_send()

> 
> This time, it was for the reply of an ARP request.
> 
> 
> Michael
> 
> 
> -----Original Message-----
> From: Andrew Lunn [mailto:andrew@lunn.ch] 
> Sent: April 5, 2006 9:57 AM
> To: Michael Grimard
> Cc: ecos-discuss@sourceware.org
> Subject: Re: [ECOS] RE: Trouble using lwIP (driver crash...)
> 
> On Wed, Apr 05, 2006 at 09:53:25AM -0400, Michael Grimard wrote:
> > 
> > Already done that.
> > 
> > This is what I got:
> > 
> > InitRxRing 0
> > ResetRxRing 0
> > InitTxRing 0
> > ResetTxRing 0
> > Device 0 (eth0), rx descriptor 0:
> > Rx 0 12e160 (status 8000a022): 1 sg's, 60 bytes Device 0 (eth0), rx 
> > descriptor 0:
> > Rx 0 12e160 (status 8000a022): 1 sg's, 60 bytes Device 0 (eth0), rx 
> > descriptor 0:
> > Rx 0 12e160 (status 8000a022): 1 sg's, 60 bytes Device 0 (eth0), rx 
> > descriptor 0:
> > Rx 0 12e160 (status 8000a022): 1 sg's, 60 bytes Device 0 (eth0), rx 
> > descriptor 0:
> > Rx 0 12e160 (status 8000a022): 1 sg's, 60 bytes Device 0 (eth0), rx 
> > descriptor 0:
> > Rx 0 12e160 (status 8000a022): 1 sg's, 60 bytes Device 0 (eth0), rx 
> > descriptor 0:
> > Rx 0 12e160 (status 8000a022): 1 sg's, 60 bytes Device 0 (eth0), rx 
> > descriptor 0:
> > Rx 0 12e160 (status 8000a022): 1 sg's, 60 bytes Device 0 (eth0), rx 
> > descriptor 0:
> > Rx 0 12e160 (status 8000a022): 1 sg's, 60 bytes Device 0 (eth0), rx 
> > descriptor 0:
> > Rx 0 12e160 (status 8000a022): 1 sg's, 60 bytes Device 0 (eth0), rx 
> > descriptor 0:
> > Rx 0 12e160 (status 8000a022): 1 sg's, 60 bytes ASSERT FAIL: 
> > <5>if_i82559.c[2370]i82559_can_send() send: Excess send recursions
> > ASSERT FAIL: <5>if_i82559.c         [2370] i82559_can_send()         
> > 
> > 
> > All I do is ping eCos three times.
> 
> It looks like you will have to debug this further. Try single stepping from
> eth_drv_send() and work out why it goes recursive.
> 
>         Andrew
> 
> 
-- 
Gary Thomas <gary@chez-thomas.org>


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss



More information about the Ecos-discuss mailing list