#include <asm/semaphore.h>
#include <asm/byteorder.h>
-#define DEBUG
+#undef DEBUG
#ifdef DEBUG
#define kaweth_dbg(format, arg...) printk(KERN_DEBUG __FILE__ ": " format "\n" ,##arg)
__u8 reserved2;
eth_addr_t hw_addr;
__u32 statistics_mask;
- __u16 segment_size;
+ __le16 segment_size;
__u16 max_multicast_filters;
__u8 reserved3;
} __attribute__ ((packed));
int count = urb->actual_length;
int count2 = urb->transfer_buffer_length;
- __u16 pkt_len = le16_to_cpup((u16 *)kaweth->rx_buf);
+ __u16 pkt_len = le16_to_cpup((__le16 *)kaweth->rx_buf);
struct sk_buff *skb;
- if(unlikely(urb->status == -ECONNRESET || urb->status == -ECONNABORTED))
+ if(unlikely(urb->status == -ECONNRESET || urb->status == -ECONNABORTED || urb->status == -ESHUTDOWN))
/* we are killed - set a flag and wake the disconnect handler */
{
kaweth->end = 1;
INTBUFFERSIZE,
int_callback,
kaweth,
- HZ/4);
+ 8);
kaweth->irq_urb->transfer_dma = kaweth->intbufferhandle;
kaweth->irq_urb->transfer_flags |= URB_NO_TRANSFER_DMA_MAP;
static int kaweth_start_xmit(struct sk_buff *skb, struct net_device *net)
{
struct kaweth_device *kaweth = net->priv;
- u16 *private_header;
+ __le16 *private_header;
int res;
}
}
- private_header = (u16 *)__skb_push(skb, 2);
+ private_header = (__le16 *)__skb_push(skb, 2);
*private_header = cpu_to_le16(skb->len-2);
kaweth->tx_skb = skb;
return -ENOMEM;
usb_fill_control_urb(urb, usb_dev, pipe, (unsigned char*)cmd, data,
- len, usb_api_blocking_completion,0);
+ len, usb_api_blocking_completion, NULL);
retv = usb_start_wait_urb(urb, timeout, &length);
if (retv < 0) {