Commit 7fcf21c6 authored by Jean Tourrilhes's avatar Jean Tourrilhes Committed by David S. Miller

[IRDA]: irda-usb sysfs support

Forgot to convert a few usb_unlink_urb() in usb_kill_urb()
	<Patch from John K. Luebs>
Proper sysfs support
Signed-off-by: default avatarJohn K. Luebs <jkluebs@lu...>
Signed-off-by: default avatarJean Tourrilhes <jt@hpl.hp.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 82058a0a
......@@ -998,7 +998,7 @@ static int irda_usb_net_close(struct net_device *netdev)
struct urb *urb = self->rx_urb[i];
struct sk_buff *skb = (struct sk_buff *) urb->context;
/* Cancel the receive command */
usb_unlink_urb(urb);
usb_kill_urb(urb);
/* The skb is ours, free it */
if(skb) {
dev_kfree_skb(skb);
......@@ -1367,12 +1367,12 @@ static int irda_usb_probe(struct usb_interface *intf,
if (!net)
goto err_out;
SET_MODULE_OWNER(net);
SET_NETDEV_DEV(net, &intf->dev);
self = net->priv;
self->netdev = net;
spin_lock_init(&self->lock);
SET_MODULE_OWNER(net);
/* Create all of the needed urbs */
for (i = 0; i < IU_MAX_RX_URBS; i++) {
self->rx_urb[i] = usb_alloc_urb(0, GFP_KERNEL);
......@@ -1516,7 +1516,7 @@ static void irda_usb_disconnect(struct usb_interface *intf)
netif_stop_queue(self->netdev);
/* Stop all the receive URBs */
for (i = 0; i < IU_MAX_RX_URBS; i++)
usb_unlink_urb(self->rx_urb[i]);
usb_kill_urb(self->rx_urb[i]);
/* Cancel Tx and speed URB.
* Toggle flags to make sure it's synchronous. */
self->tx_urb->transfer_flags &= ~URB_ASYNC_UNLINK;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment