git://git.onelab.eu
/
linux-2.6.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
vserver 1.9.3
[linux-2.6.git]
/
drivers
/
usb
/
net
/
usbnet.c
diff --git
a/drivers/usb/net/usbnet.c
b/drivers/usb/net/usbnet.c
index
2d68cb0
..
cca6e72
100644
(file)
--- a/
drivers/usb/net/usbnet.c
+++ b/
drivers/usb/net/usbnet.c
@@
-166,7
+166,7
@@
#define CONTROL_TIMEOUT_JIFFIES ((CONTROL_TIMEOUT_MS * HZ)/1000)
// between wakeups
#define CONTROL_TIMEOUT_JIFFIES ((CONTROL_TIMEOUT_MS * HZ)/1000)
// between wakeups
-#define UNLINK_TIMEOUT_
JIFFIES ((3 /*ms*/ * HZ)/1000)
+#define UNLINK_TIMEOUT_
MS 3
/*-------------------------------------------------------------------------*/
/*-------------------------------------------------------------------------*/
@@
-268,7
+268,7
@@
static const char driver_name [] = "usbnet";
/* use ethtool to change the level for any given device */
static int msg_level = 1;
/* use ethtool to change the level for any given device */
static int msg_level = 1;
-
MODULE_PARM (msg_level, "i"
);
+
module_param (msg_level, int, 0
);
MODULE_PARM_DESC (msg_level, "Initial message level (default = 1)");
MODULE_PARM_DESC (msg_level, "Initial message level (default = 1)");
@@
-937,8
+937,8
@@
struct ether_desc {
u8 iMACAddress;
u32 bmEthernetStatistics;
u8 iMACAddress;
u32 bmEthernetStatistics;
-
u16
wMaxSegmentSize;
-
u16
wNumberMCFilters;
+
__le16
wMaxSegmentSize;
+
__le16
wNumberMCFilters;
u8 bNumberPowerFilters;
} __attribute__ ((packed));
u8 bNumberPowerFilters;
} __attribute__ ((packed));
@@
-1074,7
+1074,7
@@
static int generic_cdc_bind (struct usbnet *dev, struct usb_interface *intf)
info->u->bLength);
goto bad_desc;
}
info->u->bLength);
goto bad_desc;
}
- dev->net->mtu =
cpu_to_le16
p (
+ dev->net->mtu =
le16_to_cpu
p (
&info->ether->wMaxSegmentSize)
- ETH_HLEN;
/* because of Zaurus, we may be ignoring the host
&info->ether->wMaxSegmentSize)
- ETH_HLEN;
/* because of Zaurus, we may be ignoring the host
@@
-2591,8
+2591,7
@@
static int usbnet_stop (struct net_device *net)
while (skb_queue_len (&dev->rxq)
&& skb_queue_len (&dev->txq)
&& skb_queue_len (&dev->done)) {
while (skb_queue_len (&dev->rxq)
&& skb_queue_len (&dev->txq)
&& skb_queue_len (&dev->done)) {
- set_current_state (TASK_UNINTERRUPTIBLE);
- schedule_timeout (UNLINK_TIMEOUT_JIFFIES);
+ msleep(UNLINK_TIMEOUT_MS);
devdbg (dev, "waited for %d urb completions", temp);
}
dev->wait = NULL;
devdbg (dev, "waited for %d urb completions", temp);
}
dev->wait = NULL;