staging: ft1000: Check return value when init net device.
authorMarek Belisko <marek.belisko@gmail.com>
Fri, 15 Oct 2010 06:57:24 +0000 (08:57 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Fri, 15 Oct 2010 19:41:34 +0000 (12:41 -0700)
Signed-off-by: Marek Belisko <marek.belisko@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/ft1000/ft1000-usb/ft1000_usb.c

index 44c475b3505d14d8a7ceb24de56cf8d93deed8f4..a2c415e1b8f7268120f55a76067a3401b1096ad0 100644 (file)
@@ -159,7 +159,11 @@ static int ft1000_probe(struct usb_interface *interface,
        release_firmware(dsp_fw);
 
        DEBUG("ft1000_probe: start downloading dsp image...\n");
-       init_ft1000_netdev(ft1000dev);
+
+       ret = init_ft1000_netdev(ft1000dev);
+       if (ret)
+               goto err_load;
+
        pft1000info = (FT1000_INFO *) netdev_priv(ft1000dev->net);
 
        DEBUG("In probe: pft1000info=%p\n", pft1000info);