]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/usb/atm/speedtch.c
Merge branch 'i2c-for-linus' of git://jdelvare.pck.nerim.net/jdelvare-2.6
[linux-2.6-omap-h63xx.git] / drivers / usb / atm / speedtch.c
index eb0615abff68a819f4dae10ff2a0010a637dbaaa..3e862401a638e15141460190208270a03aa0a756 100644 (file)
@@ -88,7 +88,7 @@ static const unsigned char DEFAULT_MODEM_OPTION[MODEM_OPTION_LENGTH] = {
 static unsigned int BMaxDSL = DEFAULT_B_MAX_DSL;
 static unsigned char ModemMode = DEFAULT_MODEM_MODE;
 static unsigned char ModemOption[MODEM_OPTION_LENGTH];
-static int num_ModemOption;
+static unsigned int num_ModemOption;
 
 module_param(altsetting, uint, S_IRUGO | S_IWUSR);
 MODULE_PARM_DESC(altsetting,
@@ -251,7 +251,6 @@ static int speedtch_upload_firmware(struct speedtch_instance_data *instance,
 {
        unsigned char *buffer;
        struct usbatm_data *usbatm = instance->usbatm;
-       struct usb_interface *intf;
        struct usb_device *usb_dev = usbatm->usb_dev;
        int actual_length;
        int ret = 0;
@@ -265,7 +264,7 @@ static int speedtch_upload_firmware(struct speedtch_instance_data *instance,
                goto out;
        }
 
-       if (!(intf = usb_ifnum_to_if(usb_dev, 2))) {
+       if (!usb_ifnum_to_if(usb_dev, 2)) {
                ret = -ENODEV;
                usb_dbg(usbatm, "%s: interface not found!\n", __func__);
                goto out_free;
@@ -723,6 +722,16 @@ static void speedtch_atm_stop(struct usbatm_data *usbatm, struct atm_dev *atm_de
        flush_scheduled_work();
 }
 
+static int speedtch_pre_reset(struct usb_interface *intf)
+{
+       return 0;
+}
+
+static int speedtch_post_reset(struct usb_interface *intf)
+{
+       return 0;
+}
+
 
 /**********
 **  USB  **
@@ -741,6 +750,8 @@ static struct usb_driver speedtch_usb_driver = {
        .name           = speedtch_driver_name,
        .probe          = speedtch_usb_probe,
        .disconnect     = usbatm_usb_disconnect,
+       .pre_reset      = speedtch_pre_reset,
+       .post_reset     = speedtch_post_reset,
        .id_table       = speedtch_usb_ids
 };
 
@@ -830,7 +841,6 @@ static int speedtch_bind(struct usbatm_data *usbatm,
        if (use_isoc) {
                const struct usb_host_interface *desc = data_intf->cur_altsetting;
                const __u8 target_address = USB_DIR_IN | usbatm->driver->isoc_in;
-               int i;
 
                use_isoc = 0; /* fall back to bulk if endpoint not found */