patch-2.2.17 linux/drivers/net/eepro100.c
Next file: linux/drivers/net/ewrk3.c
Previous file: linux/drivers/net/eepro.c
Back to the patch index
Back to the overall index
- Lines: 37
- Date:
Mon Sep 4 18:39:19 2000
- Orig file:
v2.2.16/drivers/net/eepro100.c
- Orig date:
Mon Sep 4 18:37:25 2000
diff -u --recursive --new-file v2.2.16/drivers/net/eepro100.c linux/drivers/net/eepro100.c
@@ -1,3 +1,5 @@
+#define USE_IO
+
/* drivers/net/eepro100.c: An Intel i82557-559 Ethernet driver for Linux. */
/*
NOTICE: this version of the driver is supposed to work with 2.2 kernels.
@@ -53,7 +55,7 @@
/* Set the copy breakpoint for the copy-only-tiny-buffer Rx method.
Lower values use more memory, but are faster. */
-#ifdef __alpha__
+#if defined(__alpha__) || defined(__sparc__)
/* force copying of all packets to avoid unaligned accesses on Alpha */
static int rx_copybreak = 1518;
#else
@@ -611,10 +613,17 @@
ioaddr = pciaddr & ~3UL;
if (check_region(ioaddr, 32))
continue;
- } else if ((ioaddr = (long)ioremap(pciaddr & ~0xfUL, 0x1000)) == 0) {
- printk(KERN_INFO "Failed to map PCI address %#lx.\n",
- pciaddr);
- continue;
+ } else {
+#ifdef __sparc__
+ /* ioremap is hosed in 2.2.x on Sparc. */
+ ioaddr = pciaddr & ~0xfUL;
+#else
+ if ((ioaddr = (long)ioremap(pciaddr & ~0xfUL, 0x1000)) == 0) {
+ printk(KERN_INFO "Failed to map PCI address %#lx.\n",
+ pciaddr);
+ continue;
+ }
+#endif
}
if (speedo_debug > 2)
printk("Found Intel i82557 PCI Speedo at I/O %#lx, IRQ %d.\n",
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)