Bluetooth: ath3k: Avoid duplication of code
[cascardo/linux.git] / drivers / bluetooth / ath3k.c
index 333c212..41dadac 100644 (file)
@@ -108,6 +108,7 @@ static int ath3k_probe(struct usb_interface *intf,
 {
        const struct firmware *firmware;
        struct usb_device *udev = interface_to_usbdev(intf);
+       int ret;
 
        BT_DBG("intf %p id %p", intf, id);
 
@@ -118,13 +119,10 @@ static int ath3k_probe(struct usb_interface *intf,
                return -EIO;
        }
 
-       if (ath3k_load_firmware(udev, firmware)) {
-               release_firmware(firmware);
-               return -EIO;
-       }
+       ret = ath3k_load_firmware(udev, firmware);
        release_firmware(firmware);
 
-       return 0;
+       return ret;
 }
 
 static void ath3k_disconnect(struct usb_interface *intf)