patch-2.4.7 linux/drivers/net/epic100.c

Next file: linux/drivers/net/eql.c
Previous file: linux/drivers/net/e2100.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.6/linux/drivers/net/epic100.c linux/drivers/net/epic100.c
@@ -48,13 +48,16 @@
 	* ethtool driver info support (jgarzik)
 
 	LK1.1.9:
-	* MII ioctl support (jgarzik)
+	* ethtool media get/set support (jgarzik)
+
+	LK1.1.10:
+	* revert MII transceiver init change (jgarzik)
 
 */
 
 #define DRV_NAME	"epic100"
-#define DRV_VERSION	"1.11+LK1.1.9"
-#define DRV_RELDATE	"July 2, 2001"
+#define DRV_VERSION	"1.11+LK1.1.10"
+#define DRV_RELDATE	"July 6, 2001"
 
 
 /* The user-configurable values.
@@ -448,7 +451,7 @@
 	outl(0x0008, ioaddr + TEST1);
 
 	/* Turn on the MII transceiver. */
-	outl(dev->if_port == 1 ? 0x13 : 0x12, ioaddr + MIICfg);
+	outl(0x12, ioaddr + MIICfg);
 	if (chip_idx == 1)
 		outl((inl(ioaddr + NVCTL) & ~0x003C) | 0x4800, ioaddr + NVCTL);
 	outl(0x0200, ioaddr + GENCTL);
@@ -670,7 +673,9 @@
 	   required by the details of which bits are reset and the transceiver
 	   wiring on the Ositech CardBus card.
 	*/
+#if 0
 	outl(dev->if_port == 1 ? 0x13 : 0x12, ioaddr + MIICfg);
+#endif
 	if (ep->chip_flags & MII_PWRDWN)
 		outl((inl(ioaddr + NVCTL) & ~0x003C) | 0x4800, ioaddr + NVCTL);
 
@@ -1174,8 +1179,6 @@
 
 			pci_dma_sync_single(ep->pci_dev, ep->rx_ring[entry].bufaddr, 
 					    ep->rx_buf_sz, PCI_DMA_FROMDEVICE);
-			pci_unmap_single(ep->pci_dev, ep->rx_ring[entry].bufaddr, 
-					 ep->rx_buf_sz, PCI_DMA_FROMDEVICE);
 			if (pkt_len > PKT_BUF_SZ - 4) {
 				printk(KERN_ERR "%s: Oversized Ethernet frame, status %x "
 					   "%d bytes.\n",
@@ -1196,6 +1199,9 @@
 					   pkt_len);
 #endif
 			} else {
+				pci_unmap_single(ep->pci_dev, 
+					ep->rx_ring[entry].bufaddr, 
+					ep->rx_buf_sz, PCI_DMA_FROMDEVICE);
 				skb_put(skb = ep->rx_skbuff[entry], pkt_len);
 				ep->rx_skbuff[entry] = NULL;
 			}

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)