Ignore:
Timestamp:
Apr 15, 2005, 8:13:18 PM (16 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, 5, master
Children:
8523f60
Parents:
933fd06a
Message:

2005-04-15 Joel Sherrill <joel@…>

  • GT64260/GT64260TWSI.c, GT64260/GT64260TWSI.h, irq/GT64260Int.c, network/GT64260eth.c, pci/pci.c, startup/bspclean.c, startup/reboot.c: Fix warnings.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/powerpc/mvme5500/network/GT64260eth.c

    r933fd06a r46a6fa91  
    127127#define ET_MINLEN 64            /* minimum message length */
    128128
    129 static int GTeth_ifioctl(struct ifnet *ifp,unsigned cmd, caddr_t data);
     129static int GTeth_ifioctl(struct ifnet *ifp, int cmd, caddr_t data);
    130130static void GTeth_ifstart (struct ifnet *);
    131131static void GTeth_ifchange(struct GTeth_softc *sc);
     
    153153static int GTeth_MissedFrame_err=0; 
    154154
    155 /* We can hard code the address here if config->hardware_address failed */
    156 static int GTethGet_macaddr(int macno, char *hwaddr)
    157 {
    158   hwaddr[0] = 0x00;
    159   hwaddr[1] = 0x01;
    160   hwaddr[2] = 0xaf;
    161   hwaddr[3] = 0x0b;
    162   hwaddr[4] = 0x75;
    163   hwaddr[5] = 0x36;
    164 
    165   return 0;
    166 }
    167 
    168155static void GT64260eth_irq_on(const rtems_irq_connect_data *irq)
    169156{
     
    537524  printf("     Receive Packets:%-8lu\n", ifp->if_ipackets);
    538525  printf("     Receive  errors:%-8lu\n", ifp->if_ierrors);
    539   printf(" Missed Frame errors:%-8lu\n", GTeth_MissedFrame_err);
     526  printf(" Missed Frame errors:%-8u\n", GTeth_MissedFrame_err);
    540527  printf("      Framing Errors:%-8lu\n", sc->stats.frame_errors);
    541528  printf("          Crc Errors:%-8lu\n", sc->stats.crc_errors);
    542529  printf("    Oversized Frames:%-8lu\n", sc->stats.length_errors);
    543   printf("         Active Rxqs:%-8lu\n", sc->rxq_active);
     530  printf("         Active Rxqs:%-8u\n", sc->rxq_active);
    544531  printf("       Tx Interrupts:%-8lu\n", sc->stats.txInterrupts);
    545532  printf("Multi-Buffer Packets:%-8lu\n", sc->stats.txMultiBuffPacket);
     
    547534  printf("   Transmitt  errors:%-8lu\n", ifp->if_oerrors);
    548535  printf("    Tx/Rx collisions:%-8lu\n", ifp->if_collisions);
    549   printf("         Active Txqs:%-8lu\n", sc->txq_nactive);
     536  printf("         Active Txqs:%-8u\n", sc->txq_nactive);
    550537}
    551538
    552539void GT64260eth_err()
    553540{
    554   printf(" Missed Frame errors:%-8lu\n", GTeth_MissedFrame_err);
    555 }
    556 
    557 static int GTeth_ifioctl(struct ifnet *ifp,unsigned cmd, caddr_t data)
     541  printf(" Missed Frame errors:%-8u\n", GTeth_MissedFrame_err);
     542}
     543
     544static int GTeth_ifioctl(struct ifnet *ifp, int cmd, caddr_t data)
    558545{
    559546  struct GTeth_softc *sc = ifp->if_softc;
     
    652639  rxd = sc->rxq_head_desc;
    653640
    654   sc->rxq_desc_busaddr = sc->rxq_head_desc;
     641  sc->rxq_desc_busaddr = (unsigned long) sc->rxq_head_desc;
    655642#ifdef GT_DEBUG
    656643  printk("rxq_desc_busaddr %x ,&sc->rxq_desc[0] %x\n",
     
    674661
    675662    /* convert mbuf pointer to data pointer of correct type */ 
    676     rxd->ed_bufptr = mtod(m, void *);
     663    rxd->ed_bufptr = (unsigned) mtod(m, void *);
    677664
    678665    /*
     
    721708  struct mbuf *m;
    722709  int nloops=0;
    723   unsigned int intr_status = sc->intr_errsts[sc->intr_err_ptr1];
    724710
    725711  if (GTeth_rx_debug>0) printk("GT64260eth_rx(");
     
    810796     sc->rxq_mbuf[sc->rxq_fi]= m;
    811797     /* convert mbuf pointer to data pointer of correct type */
    812      rxd->ed_bufptr = mtod(m, void*);
     798     rxd->ed_bufptr = (unsigned) mtod(m, void*);
    813799     rxd->ed_lencnt = (unsigned long) sc->rx_buf_sz <<16;
    814800     rxd->ed_cmdsts = RX_CMD_F|RX_CMD_L|RX_CMD_O|RX_CMD_EI;
     
    946932static int GT64260eth_sendpacket(struct GTeth_softc *sc,struct mbuf *m, enum GTeth_txprio txprio)
    947933{
    948   struct ifnet *ifp=&sc->arpcom.ac_if;
    949934  volatile struct GTeth_desc *txd = &sc->txq_desc[sc->txq_lo];
    950935  unsigned intrmask = sc->sc_intrmask;
     
    1001986  if (m->m_len < ET_MINLEN) m->m_len = ET_MINLEN;
    1002987
    1003   txd->ed_bufptr = mtod(m, void*);
     988  txd->ed_bufptr = (unsigned) mtod(m, void*);
    1004989  txd->ed_lencnt = m->m_len << 16;
    1005990  txd->ed_cmdsts = TX_CMD_L|TX_CMD_GC|TX_CMD_P|TX_CMD_O|TX_CMD_F|TX_CMD_EI;
     
    11001085
    11011086  txd = &sc->txq_desc[0];
    1102   sc->txq_desc_busaddr = &sc->txq_desc[0];
     1087  sc->txq_desc_busaddr = (unsigned long) &sc->txq_desc[0];
    11031088#ifdef GT_DEBUG
    11041089  printk("txq_desc_busaddr %x, &sc->txq_desc[0] %x \n",
     
    11401125         sc->txq_epsrbits = ETH_EPSR_TxHigh;
    11411126         /* offset to current tx desc ptr reg */
    1142          sc->txq_ectdp = ETH0_ECTDP1;
     1127         sc->txq_ectdp = (caddr_t)ETH0_ECTDP1;
    11431128         /* Current Tx Desc Pointer 1 */
    11441129         outl(sc->txq_desc_busaddr,ETH0_ECTDP1);
     
    11521137         sc->txq_esdcmrbits = ETH_ESDCMR_TXDL; /* Start TX low */
    11531138         sc->txq_epsrbits = ETH_EPSR_TxLow;
    1154          sc->txq_ectdp = ETH0_ECTDP0;
     1139         sc->txq_ectdp = (caddr_t)ETH0_ECTDP0;
    11551140         /* Current Tx Desc Pointer 0 */
    11561141         outl(sc->txq_desc_busaddr,ETH0_ECTDP0);
Note: See TracChangeset for help on using the changeset viewer.