network freeze

Mario Vieira Mario.Vieira at
Mon Oct 7 11:32:12 UTC 2002


I'm trying to test the latest netdemo example downloaded from oarcorp in 
rtems 4.5.0 also downloaded from oarcorp. I'm using the i960 processor.

I run the netdemo program and the system freezes after sending 5 UDP 
packets. I see with a packet sniffer that after those 5 packets an ARP 
request is sent too.

It seems that the network stack is wait for the answer to that ARP. 
Shouldn't the stack give some error?

Thanks in advance,
Mário Vieira.

My network driver big picture (based in wd8003 driver from pc386 BSP) 
without sending anything to the network board: 

wd_txDaemon (void *arg)
        struct wd_softc *sc = (struct wd_softc *)arg;
        struct ifnet *ifp = &sc->arpcom.ac_if;
        struct mbuf *m;
        rtems_event_set events;

        for (;;) {
                 * Wait for packet
                rtems_bsdnet_event_receive (START_TRANSMIT_EVENT, 

                 * Send packets till queue is empty
                for (;;) {
                         * Get the next mbuf chain to transmit.
                        IF_DEQUEUE(&ifp->if_snd, m);
                        if (!m)
                        sendpacket (ifp, m);
                ifp->if_flags &= ~IFF_OACTIVE;

static void
sendpacket (struct ifnet *ifp, struct mbuf *m)
        struct wd_softc *dp = ifp->if_softc;
        struct mbuf *n;
        unsigned int len, tport;
        char *shp, txReady;

  len = 0;

  n = m;
  for (;;){
    len += m->m_len;
/*    memcpy(shp, (char *)m->m_data, m->m_len); */
    shp += m->m_len ;
    if ((m = m->m_next) == NULL)


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the users mailing list