} rtl_chip_info[] = {
{"RTL-8169", 0x00, 0xff7e1880,},
{"RTL-8169", 0x04, 0xff7e1880,},
+ {"RTL-8169", 0x00, 0xff7e1880,},
+ {"RTL-8169s/8110s", 0x02, 0xff7e1880,},
+ {"RTL-8169s/8110s", 0x04, 0xff7e1880,},
+ {"RTL-8169sb/8110sb", 0x10, 0xff7e1880,},
+ {"RTL-8169sc/8110sc", 0x18, 0xff7e1880,},
+ {"RTL-8168b/8111sb", 0x30, 0xff7e1880,},
+ {"RTL-8168b/8111sb", 0x38, 0xff7e1880,},
+ {"RTL-8101e", 0x34, 0xff7e1880,},
+ {"RTL-8100e", 0x32, 0xff7e1880,},
};
enum _DescStatusBit {
(RX_FIFO_THRESH << RxCfgFIFOShift) | (RX_DMA_BURST << RxCfgDMAShift);
static struct pci_device_id supported[] = {
+ {PCI_VENDOR_ID_REALTEK, 0x8167},
{PCI_VENDOR_ID_REALTEK, 0x8169},
{}
};
return value;
}
-#define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0]))
-
static int rtl8169_init_board(struct eth_device *dev)
{
int i;
tpc->RxDescArray[cur_rx].status =
cpu_to_le32(OWNbit + RX_BUF_SIZE);
tpc->RxDescArray[cur_rx].buf_addr =
- cpu_to_le32(tpc->RxBufferRing[cur_rx]);
+ cpu_to_le32((unsigned long)tpc->RxBufferRing[cur_rx]);
} else {
puts("Error Rx");
}
tpc->cur_rx = cur_rx;
return 1;
+ } else {
+ ushort sts = RTL_R8(IntrStatus);
+ RTL_W8(IntrStatus, sts & ~(TxErr | RxErr | SYSErr));
+ udelay(100); /* wait */
}
tpc->cur_rx = cur_rx;
return (0); /* initially as this is called to flush the input */
while (len < ETH_ZLEN)
ptxb[len++] = '\0';
- tpc->TxDescArray[entry].buf_addr = cpu_to_le32(ptxb);
+ tpc->TxDescArray[entry].buf_addr = cpu_to_le32((unsigned long)ptxb);
if (entry != (NUM_TX_DESC - 1)) {
tpc->TxDescArray[entry].status =
cpu_to_le32((OWNbit | FSbit | LSbit) |
tpc->cur_rx = 0;
- RTL_W32(TxDescStartAddr, tpc->TxDescArray);
- RTL_W32(RxDescStartAddr, tpc->RxDescArray);
+ RTL_W32(TxDescStartAddr, (unsigned long)tpc->TxDescArray);
+ RTL_W32(RxDescStartAddr, (unsigned long)tpc->RxDescArray);
RTL_W8(Cfg9346, Cfg9346_Lock);
udelay(10);
tpc->RxBufferRing[i] = &rxb[i * RX_BUF_SIZE];
tpc->RxDescArray[i].buf_addr =
- cpu_to_le32(tpc->RxBufferRing[i]);
+ cpu_to_le32((unsigned long)tpc->RxBufferRing[i]);
}
#ifdef DEBUG_RTL8169
/**************************************************************************
RESET - Finish setting up the ethernet interface
***************************************************************************/
-static void rtl_reset(struct eth_device *dev, bd_t *bis)
+static int rtl_reset(struct eth_device *dev, bd_t *bis)
{
int i;
#ifdef DEBUG_RTL8169
printf ("%s elapsed time : %d\n", __FUNCTION__, currticks()-stime);
#endif
+ return 0;
}
/**************************************************************************