Hello.
Have anyone ever made AX88772 usb ethernet driver working on a big endian
system?
I'm currently working with an embedded-linux-based board with big-endian
MIPS cpu, and the driver does not work for me (usb transactions initiated
in start_xmit method do succeed, but nothing is transmitted or received
over the wire).
I've looked through the code, and found at least one strange point:
ax88772_tx_fixup() does write 32bit words to skb (that is later DMAed to
device) without converting in to little endian - so result will differ
depending on CPU byte order.
So maybe something like the attached patch could be needed (it's against
2.6.18 - although I work with a vendor kernel based on 2.6.10 and try to
port driver there)
However, I still can't make device working even with such fix.
Any hints will be very helpful ...
--- ./asix.c 2006-10-15 16:20:26.000000000 +0400
+++ /tmp/asix.c 2006-11-23 10:40:41.774230433 +0300
@@ -776,9 +776,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));
}
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
linux-usb-devel@lists.sourceforge.net
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel