Re: ASIX: AX88772 usb ethenet on big-endian system

David Hollis <[email protected]>
Newsgroups gmane.linux.usb.devel
Message-ID <[email protected]>
On Tue, 2007-01-30 at 07:38 -0500, David Hollis wrote:

> If the AX88172 device seemed to work fine, that at least narrows it
> down.  Most of the code is shared between the two except for the bind()
> calls and probably the multicast function.  I'd be interested to know if
> the AX88178 (1GB Ethernet chip) also has issues on big-endian since it
> does use the same multicast setup as well as the tx/rx_fixups().
> 

Can you try the attached patch with the AX88772 device.  It should
resolve the endian issues in tx_fixup.  rx_fixup already seems to handle
endian conversions properly.

-- 
David Hollis <[email protected]>

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642

_______________________________________________
[email protected]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel
asix.c-tx_fixup-endianess.patch (text/x-patch, 479 B)
--- a/drivers/usb/net/asix.c	2007-01-25 07:30:22.000000000 -0500
+++ b/drivers/usb/net/asix.c	2007-02-01 10:30:09.000000000 -0500
@@ -352,9 +352,11 @@
 
 	skb_push(skb, 4);
 	packet_len = (((skb->len - 4) ^ 0x0000ffff) << 16) + (skb->len - 4);
+	cpu_to_le32s(&packet_len);
 	memcpy(skb->data, &packet_len, sizeof(packet_len));
 
 	if ((skb->len % 512) == 0) {
+		cpu_to_le32s(&padbytes);
 		memcpy( skb->tail, &padbytes, sizeof(padbytes));
 		skb_put(skb, sizeof(padbytes));
 	}
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.