In both 2.4 CDCEther.c and 2.5 cdc-ether.c, there is this bit of
code in the start_xmit function:

// If we are told to transmit an ethernet frame that fits EXACTLY 
// into an integer number of USB packets, we force it to send one 
// more byte so the device will get a runt USB packet signalling the 
// end of the ethernet frame
if ( (skb->len) ^ (ether_dev->data_ep_out_size) ) {
        // It was not an exact multiple
        // no need to add anything extra
        count = skb->len;
} else {
        // Add one to make it NOT an exact multiple
        count = skb->len + 1;
}

The logic seem to be wrong. I suspect the ^ in the test
should actually be a %.
Fixing this appear to fix a packet loss problem with a
device I'm working on.

Also, shouldn't we just complete the frame with a zero-lenght
packet or is this a problem with some hci's

Ben.



-------------------------------------------------------
This sf.net email is sponsored by: 
To learn the basics of securing your web site with SSL, 
click here to get a FREE TRIAL of a Thawte Server Certificate: 
http://www.gothawte.com/rd522.html
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to