R: [uClinux-dev] debug messages in fec.c

Greg Ungerer gerg at snapgear.com
Thu Aug 4 03:01:44 EDT 2005


Hi Luca,

Luca Cussolotto wrote:
> I introduce other debug trace in different source modules
> (drivers/net/fec.c, net/sched/sch_generic.c, net/core/dev.c)
> and so I have new information:
> 
> 1. during ping execution, I disconnect the cable,
> 
> 2. the <fec_enet_start_xmit> function (testing the fep->link variable) terminate
> calling netif_stop_queue;

I think this logic may be wrong. Just returning if you don't have link
is probably not the right thing to do. I suspect this should be calling
netif_stop_queue() to tell the layers above to stop sending data.

Along with with this the relink code should be calling 
netif_start_queue() too.

Can you make these changes and try this out?

Regards
Greg




> 3. the <dev_watchdog> (a function always running), testing the
> netif_queue_stopped
> (with other variabled always verified), calls the dev_timeout ( > fec_timeout)
> that is responsible for the debug messages, beyond to calling <fec_restart> and
> <netif_wake_queue>
> 
> 4. now the <net_tx_action> tries to retransmit calling the <qdisc_run> then
> <qdisc_restart>
> and <dev->hard_start_xmit> ( > fec_enet_start_xmit ) and then step 2
> 
> 5. when I stop ping execution, the <net_tx_action> comes still recalled (step 4)
> 
> The problem seems to be how to stop <net_tx_action> after ping termination.
> 
> Some suggestion ?
> 
> Regards
> Luca
> 
> 
> -----Messaggio originale-----
> Da: uclinux-dev-bounces at uclinux.org
> [mailto:uclinux-dev-bounces at uclinux.org]Per conto di Luca Cussolotto
> Inviato: lunedì 18 luglio 2005 9.29
> A: 'uClinux development list'
> Oggetto: R: [uClinux-dev] debug messages in fec.c
> 
> 
> 
> Hi Greg,
> 
> Yes, fep->link was 0 when the cable was not connected
> and became 1 when I reconnected it.
> 
> I also tryed with the latest fec.c but the result was the same.
> 
> Other trace suggestion ?
> 
> Regards
> Luca
> 
> 
>>-----Messaggio originale-----
>>Da: uclinux-dev-bounces at uclinux.org
>>[mailto:uclinux-dev-bounces at uclinux.org]Per conto di Greg Ungerer
>>Inviato: venerdi 15 luglio 2005 2.55
>>A: Luca Cussolotto
>>Cc: uClinux development list
>>Oggetto: Re: [uClinux-dev] debug messages in fec.c
>>
>>
>>Hi Luca,
> 
> 
>>Luca Cussolotto wrote:
>>
>>>I found the same problem related by Josef; I'm also
>>>working with a MCF5272 board using the uClinux-dist-20041215.
>>>
>>>I procedeed with the trace suggested from you, and
>>>the result was that the fep->link variable was correctly setted.
> 
> 
>>So fep->link was 0 when the cable was not connected?
> 
> 
>>I would suggest trying the latest fec.c from CVS too.
>>There has been a few fixes over the last few months
>>(I don't recall anything that would neccessarily fix
>>this problem though).
> 
> 
>>Regards
>>Greg
> 
> 
> 
> _______________________________________________
> uClinux-dev mailing list
> uClinux-dev at uclinux.org
> http://mailman.uclinux.org/mailman/listinfo/uclinux-dev
> This message was resent by uclinux-dev at uclinux.org
> 
> 
> _______________________________________________
> uClinux-dev mailing list
> uClinux-dev at uclinux.org
> http://mailman.uclinux.org/mailman/listinfo/uclinux-dev
> This message was resent by uclinux-dev at uclinux.org
> 

-- 
------------------------------------------------------------------------
Greg Ungerer  --  Chief Software Dude       EMAIL:     gerg at snapgear.com
SnapGear -- a CyberGuard Company            PHONE:       +61 7 3435 2888
825 Stanley St,                             FAX:         +61 7 3891 3630
Woolloongabba, QLD, 4102, Australia         WEB: http://www.SnapGear.com



More information about the uClinux-dev mailing list