From dd9b6aa4fd58b3ac39a696e518a09994e687ba72 Mon Sep 17 00:00:00 2001 From: Marek Belisko Date: Fri, 15 Oct 2010 08:57:24 +0200 Subject: [PATCH] staging: ft1000: Check return value when init net device. Signed-off-by: Marek Belisko Signed-off-by: Greg Kroah-Hartman --- drivers/staging/ft1000/ft1000-usb/ft1000_usb.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/staging/ft1000/ft1000-usb/ft1000_usb.c b/drivers/staging/ft1000/ft1000-usb/ft1000_usb.c index 44c475b3505d..a2c415e1b8f7 100644 --- a/drivers/staging/ft1000/ft1000-usb/ft1000_usb.c +++ b/drivers/staging/ft1000/ft1000-usb/ft1000_usb.c @@ -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); -- 2.39.5