lkml.org 
[lkml]   [2005]   [Mar]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Date
    Subject[PATCH 2.6 IrDA] irda-usb sysfs support
    From
    ir261_irda-usb_sysfs-kill_urb-2.diff :
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    o [CORRECT] Forgot to convert a few usb_unlink_urb() in usb_kill_urb()
    <Patch from John K. Luebs>
    o [FEATURE] Proper sysfs support
    Signed-off-by: John K. Luebs <jkluebs@lu...>
    Signed-off-by: Jean Tourrilhes <jt@hpl.hp.com>



    diff -u -p linux/drivers/net/irda/irda-usb.d0.c linux/drivers/net/irda/irda-usb.c
    --- linux/drivers/net/irda/irda-usb.d0.c Fri Mar 4 15:37:25 2005
    +++ linux/drivers/net/irda/irda-usb.c Fri Mar 4 15:38:38 2005
    @@ -998,7 +998,7 @@ static int irda_usb_net_close(struct net
    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_int
    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 u
    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;
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/
    \
     
     \ /
      Last update: 2005-03-22 14:10    [W:0.043 / U:116.344 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site