summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--linux/src/drivers/net/ne2k-pci.c15
2 files changed, 13 insertions, 7 deletions
diff --git a/ChangeLog b/ChangeLog
index e717a8f..7124a1e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2006-01-22 Thomas Schwinge <tschwinge@gnu.org>
+
+ * linux/src/drivers/net/ne2k-pci.c (ne_block_input, ne_block_output):
+ Fix previous patch.
+
2005-07-12 Guillem Jover <guillem@hadrons.org>
* configure: Regenerated.
diff --git a/linux/src/drivers/net/ne2k-pci.c b/linux/src/drivers/net/ne2k-pci.c
index bdc3e74..280fb72 100644
--- a/linux/src/drivers/net/ne2k-pci.c
+++ b/linux/src/drivers/net/ne2k-pci.c
@@ -541,11 +541,10 @@ ne_block_input(struct device *dev, int count, struct sk_buff *skb, int ring_offs
insl(NE_BASE + NE_DATAPORT, buf, count>>2);
if (count & 3) {
buf += count & ~3;
- if (count & 2)
- {
- *buf = *(u16 *) buf + 1;
- *buf = inw(NE_BASE + NE_DATAPORT);
- }
+ if (count & 2) {
+ *((u16 *) buf) = inw(NE_BASE + NE_DATAPORT);
+ buf = (void *) buf + sizeof (u16);
+ }
if (count & 1)
*buf = inb(NE_BASE + NE_DATAPORT);
}
@@ -607,8 +606,10 @@ ne_block_output(struct device *dev, int count,
outsl(NE_BASE + NE_DATAPORT, buf, count>>2);
if (count & 3) {
buf += count & ~3;
- if (count & 2)
- outw(*buf++, NE_BASE + NE_DATAPORT);
+ if (count & 2) {
+ outw(*((u16 *) buf), NE_BASE + NE_DATAPORT);
+ buf = (void *) buf + sizeof (u16);
+ }
}
#else