aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net
diff options
context:
space:
mode:
authorDenis Joseph Barrow <D.Barow@option.com>2008-11-25 03:30:48 -0500
committerDavid S. Miller <davem@davemloft.net>2008-11-25 03:30:48 -0500
commit89930b7b5e3e9bfe9c6ec5e19920451c8f5d9088 (patch)
treea2e43106f1b64b0f250223db5ac99f3c4a3fa598 /drivers/net
parent4a3e818181e1baf970e9232ca8b747e233176b87 (diff)
hso: Fix URB submission -EINVAL.
Added check for IFF_UP in hso_resume, this should eliminate -EINVAL (-22) errors caused from urb's being submitted twice, once by hso_resume & once in hso_net_open, if suspend/resume USB power saving mode is enabled Signed-off-by: Denis Joseph Barrow <D.Barow@option.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/usb/hso.c25
1 files changed, 14 insertions, 11 deletions
diff --git a/drivers/net/usb/hso.c b/drivers/net/usb/hso.c
index d5857321979b..2c172435495f 100644
--- a/drivers/net/usb/hso.c
+++ b/drivers/net/usb/hso.c
@@ -2762,18 +2762,21 @@ static int hso_resume(struct usb_interface *iface)
2762 if (network_table[i] && 2762 if (network_table[i] &&
2763 (network_table[i]->interface == iface)) { 2763 (network_table[i]->interface == iface)) {
2764 hso_net = dev2net(network_table[i]); 2764 hso_net = dev2net(network_table[i]);
2765 /* First transmit any lingering data, then restart the 2765 if (hso_net->flags & IFF_UP) {
2766 * device. */ 2766 /* First transmit any lingering data,
2767 if (hso_net->skb_tx_buf) { 2767 then restart the device. */
2768 dev_dbg(&iface->dev, 2768 if (hso_net->skb_tx_buf) {
2769 "Transmitting lingering data\n"); 2769 dev_dbg(&iface->dev,
2770 hso_net_start_xmit(hso_net->skb_tx_buf, 2770 "Transmitting"
2771 hso_net->net); 2771 " lingering data\n");
2772 hso_net->skb_tx_buf = NULL; 2772 hso_net_start_xmit(hso_net->skb_tx_buf,
2773 hso_net->net);
2774 hso_net->skb_tx_buf = NULL;
2775 }
2776 result = hso_start_net_device(network_table[i]);
2777 if (result)
2778 goto out;
2773 } 2779 }
2774 result = hso_start_net_device(network_table[i]);
2775 if (result)
2776 goto out;
2777 } 2780 }
2778 } 2781 }
2779 2782