[En-Nut-Discussion] NicOverflow Bug?

tyou tyou at i-da.co.jp
Fri Aug 22 08:11:42 CEST 2003


Hi ,
    Network of H8 port will be down after one day or so.
After reboot, ping time will be less than 10ms, but after
running for one day or so, the ping time will be very big even
no response.  And I really don't know how to debug it
except that let printf output informations all over the program.
:( However by now, still no result. it is really time killing. ^_^
    Today I'v tested with following steps :
1. Let Thread Nic NicRx print out the info:
#ifdef _DEBUG_NIC_      
        printf("::: NIC infor :::\n");
        printf("packet overruns.%lu\n", ((NICINFO 
*)dev->dev_dcb)->ni_overruns        );
        printf("frame errors. %lu\n", ((NICINFO 
*)dev->dev_dcb)->ni_rx_frame_errors );
        printf("CRC errors.%lu\n", ((NICINFO 
*)dev->dev_dcb)->ni_rx_crc_errors   );
        printf("missed packets.%lu\n\n", ((NICINFO 
*)dev->dev_dcb)->ni_rx_missed_errors);
2. Start Nut/OS, and open dozens of "ping 192.168.1.20 -t -l 1024" 
cmd.exe windows , 
until ping time gets big or reuqestd time out is displayed. At the same 
time, I see that
packet overruns became non-zero value on serial stdio. After overrun 
occurs, seems
network will not recover. Ping will be time out for ever.
3.  Try to edit the code.
    In fuction NicOverflow :
    /* Finally clear the overflow flag. */   
    nic_write(NIC_PG0_ISR, NIC_ISR_OVW);
    to:
    nic_write(NIC_PG0_ISR, 0xFF);
4.  Do step 2 again. Ping will be OK again at last, network will recover 
after overrun.

But I am Sorry that I don't know whether other codes should be edited 
after step 3.
And I don't know this bug only happen on my H8 port .

Regards,
Tyou





More information about the En-Nut-Discussion mailing list