[PATCH 309] Macintosh 8390 Ethernet update
From: Geert Uytterhoeven
Date: Sun Sep 28 2003 - 15:46:32 EST
Mac8390: Update for netdevice/8390 core changes in 2.5.8
--- linux-2.6.0-test6/drivers/net/mac8390.c Tue Jul 29 18:18:58 2003
+++ linux-m68k-2.6.0-test6/drivers/net/mac8390.c Fri Sep 19 14:21:17 2003
@@ -442,14 +442,14 @@
ei_status.tx_start_page = CABLETRON_TX_START_PG;
ei_status.rx_start_page = CABLETRON_RX_START_PG;
ei_status.stop_page = CABLETRON_RX_STOP_PG;
- dev->rmem_start = dev->mem_start;
- dev->rmem_end = dev->mem_start + CABLETRON_RX_STOP_PG*256;
+ ei_status.rmem_start = dev->mem_start;
+ ei_status.rmem_end = dev->mem_start + CABLETRON_RX_STOP_PG*256;
} else {
ei_status.tx_start_page = WD_START_PG;
ei_status.rx_start_page = WD_START_PG + TX_PAGES;
ei_status.stop_page = (dev->mem_end - dev->mem_start)/256;
- dev->rmem_start = dev->mem_start + TX_PAGES*256;
- dev->rmem_end = dev->mem_end;
+ ei_status.rmem_start = dev->mem_start + TX_PAGES*256;
+ ei_status.rmem_end = dev->mem_end;
}
/* Fill in model-specific information and functions */
@@ -621,12 +621,12 @@
unsigned long xfer_base = ring_offset - (WD_START_PG<<8);
unsigned long xfer_start = xfer_base + dev->mem_start;
- if (xfer_start + count > dev->rmem_end) {
+ if (xfer_start + count > ei_status.rmem_end) {
/* We must wrap the input move. */
- int semi_count = dev->rmem_end - xfer_start;
+ int semi_count = ei_status.rmem_end - xfer_start;
memcpy_fromio(skb->data, (char *)dev->mem_start + xfer_base, semi_count);
count -= semi_count;
- memcpy_toio(skb->data + semi_count, (char *)dev->rmem_start, count);
+ memcpy_toio(skb->data + semi_count, (char *)ei_status.rmem_start, count);
} else {
memcpy_fromio(skb->data, (char *)dev->mem_start + xfer_base, count);
}
@@ -657,15 +657,16 @@
/* Note the offset math is done in card memory space which is word
per long onto our space. */
-
- if (xfer_start + count > dev->rmem_end)
+
+ if (xfer_start + count > ei_status.rmem_end)
{
/* We must wrap the input move. */
- int semi_count = dev->rmem_end - xfer_start;
+ int semi_count = ei_status.rmem_end - xfer_start;
dayna_memcpy_fromcard(dev, skb->data, xfer_base, semi_count);
count -= semi_count;
- dayna_memcpy_fromcard(dev, skb->data + semi_count,
- dev->rmem_start - dev->mem_start, count);
+ dayna_memcpy_fromcard(dev, skb->data + semi_count,
+ ei_status.rmem_start - dev->mem_start,
+ count);
}
else
{
@@ -697,15 +698,15 @@
unsigned long xfer_base = ring_offset - (WD_START_PG<<8);
unsigned long xfer_start = xfer_base+dev->mem_start;
- if (xfer_start + count > dev->rmem_end)
+ if (xfer_start + count > ei_status.rmem_end)
{
/* We must wrap the input move. */
- int semi_count = dev->rmem_end - xfer_start;
+ int semi_count = ei_status.rmem_end - xfer_start;
word_memcpy_fromcard(skb->data, (char *)dev->mem_start +
xfer_base, semi_count);
count -= semi_count;
word_memcpy_fromcard(skb->data + semi_count,
- (char *)dev->rmem_start, count);
+ (char *)ei_status.rmem_start, count);
}
else
{
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/