Messages in this thread Patch in this message | | | Date | Sat, 18 Dec 1999 19:03:22 -0600 | From | Bill Wendling <> | Subject | [patch] Another read[bwl] and ioremap "fix" |
| |
Okay, so I've donned my asbestos suit in preparation for making yet another fool of myself :).
Here's another patch. I think this one is correct, however I'm not so sure about the changes starting at 251...
Bill diff -Naur linux-2.3.33/drivers/net/3c503.c linux/drivers/net/3c503.c --- linux-2.3.33/drivers/net/3c503.c Thu Oct 28 18:13:20 1999 +++ linux/drivers/net/3c503.c Sat Dec 18 19:02:00 1999 @@ -103,7 +103,7 @@ for (addr = addrs; *addr; addr++) { int i; - unsigned int base_bits = readb(*addr); + unsigned int base_bits = isa_readb(*addr); /* Find first set bit. */ for(i = 7; i >= 0; i--, base_bits >>= 1) if (base_bits & 0x1) @@ -251,18 +251,18 @@ { /* Check the card's memory. */ unsigned long mem_base = dev->mem_start; unsigned int test_val = 0xbbadf00d; - writel(0xba5eba5e, mem_base); + isa_writel(0xba5eba5e, mem_base); for (i = sizeof(test_val); i < EL2_MEMSIZE; i+=sizeof(test_val)) { - writel(test_val, mem_base + i); - if (readl(mem_base) != 0xba5eba5e - || readl(mem_base + i) != test_val) { + isa_writel(test_val, mem_base + i); + if (isa_readl(mem_base) != 0xba5eba5e + || isa_readl(mem_base + i) != test_val) { printk("3c503: memory failure or memory address conflict.\n"); dev->mem_start = 0; ei_status.name = "3c503-PIO"; break; } test_val += 0x55555555; - writel(0, mem_base + i); + isa_writel(0, mem_base + i); } } #endif /* EL2MEMTEST */ | |