-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Greg,
As discussed at LCA 2003, I'm transfering maintainership of the CDC Ethernet driver to you. I've attached three patches to see it on its way: cdc-181002.patch is a really old 2.4. series patch, not sure if it still compiles, but a few people reported it helped. cdc-ether-zerolength.patch is the same for 2.5.65 - compile tested, but not even installed, since you now have the software testing. cdc-ether-maint.patch is the official transfer documentation :=) I enjoyed working on Linux USB development, but time is getting very tight for me, so I have to pass this on, and wish it, and you, the best. Brad -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (GNU/Linux) Comment: For info see http://www.gnupg.org iD8DBQE+fApQW6pHgIdAuOMRAl5iAJwMt+UVEPA/7p4nBqyDBr7pOzTIuwCfU4ld yI9l/UUIx7MavUcLKGAbUfA= =hm+W -----END PGP SIGNATURE-----
diff -Naur -X dontdiff linux-2.5.65-clean/CREDITS linux-2.5.65/CREDITS --- linux-2.5.65-clean/CREDITS 2003-03-18 08:44:21.000000000 +1100 +++ linux-2.5.65/CREDITS 2003-03-22 17:39:54.000000000 +1100 @@ -1210,6 +1210,10 @@ S: Atlanta, Georgia 30332 S: USA +N: Brad Hards +E: [EMAIL PROTECTED] +D: Various USB bits, other minor patches + N: Angelo Haritsis E: [EMAIL PROTECTED] D: kernel patches (serial, watchdog) diff -Naur -X dontdiff linux-2.5.65-clean/MAINTAINERS linux-2.5.65/MAINTAINERS --- linux-2.5.65-clean/MAINTAINERS 2003-03-18 08:44:09.000000000 +1100 +++ linux-2.5.65/MAINTAINERS 2003-03-22 17:38:09.000000000 +1100 @@ -1862,11 +1862,12 @@ W: http://www.kroah.com/linux-usb/ USB CDC ETHERNET DRIVER -P: Brad Hards -M: [EMAIL PROTECTED] +P: Greg Kroah-Hartman +M: [EMAIL PROTECTED] L: [EMAIL PROTECTED] L: [EMAIL PROTECTED] S: Maintained +W: http://www.kroah.com/linux-usb/ USB EHCI DRIVER P: David Brownell
diff -Naur -X dontdiff linux-2.5.65/drivers/usb/net/cdc-ether.c linux-2.5.65-cdcfixup/drivers/usb/net/cdc-ether.c --- linux-2.5.65/drivers/usb/net/cdc-ether.c 2003-03-18 08:43:39.000000000 +1100 +++ linux-2.5.65-cdcfixup/drivers/usb/net/cdc-ether.c 2003-03-22 17:55:22.000000000 +1100 @@ -269,22 +269,8 @@ static int CDCEther_start_xmit( struct sk_buff *skb, struct net_device *net ) { ether_dev_t *ether_dev = net->priv; - int count; int res; - // 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; - } - // Tell the kernel, "No more frames 'til we are done // with this one.' netif_stop_queue( net ); @@ -299,7 +285,10 @@ write_bulk_callback, ether_dev ); // Tell the URB how much it will be transporting today - ether_dev->tx_urb->transfer_buffer_length = count; + ether_dev->tx_urb->transfer_buffer_length = skb->len; + + /* Deal with the zero length problem, I hope */ + ether_dev->tx_urb.transfer_flags |= USB_ZERO_PACKET; // Send the URB on its merry way. if ((res = usb_submit_urb(ether_dev->tx_urb, GFP_ATOMIC))) {
diff -Naur -X dontdiff linux-2.4.20-pre11-clean/drivers/usb/CDCEther.c linux-2.4.20-pre11/drivers/usb/CDCEther.c --- linux-2.4.20-pre11-clean/drivers/usb/CDCEther.c 2002-10-18 09:57:03.000000000 +1000 +++ linux-2.4.20-pre11/drivers/usb/CDCEther.c 2002-10-18 09:23:48.000000000 +1000 @@ -306,22 +306,8 @@ static int CDCEther_start_xmit( struct sk_buff *skb, struct net_device *net ) { ether_dev_t *ether_dev = net->priv; - int count; int res; - // 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; - } - // Tell the kernel, "No more frames 'til we are done // with this one.' netif_stop_queue( net ); @@ -336,7 +322,10 @@ write_bulk_callback, ether_dev ); // Tell the URB how much it will be transporting today - ether_dev->tx_urb.transfer_buffer_length = count; + ether_dev->tx_urb.transfer_buffer_length = skb->len; + + /* Deal with the Zero Length packet problem, I hope */ + ether_dev->tx_urb.transfer_flags |= USB_ZERO_PACKET; // Send the URB on its merry way. if ((res = usb_submit_urb(ðer_dev->tx_urb))) {