[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1299422716-29461-3-git-send-email-florian@mickler.org>
Date: Sun, 6 Mar 2011 15:45:16 +0100
From: Florian Mickler <florian@...kler.org>
To: mchehab@...radead.org
Cc: Florian Mickler <florian@...kler.org>, linux-media@...r.kernel.org,
linux-kernel@...r.kernel.org, Greg Kroah-Hartman <greg@...ah.com>,
"Rafael J. Wysocki" <rjw@...k.pl>,
Maciej Rutecki <maciej.rutecki@...il.com>,
Oliver Neukum <oliver@...kum.org>,
Jack Stone <jwjstone@...tmail.fm>
Subject: [PATCH 3/3] [media] dib0700: don't ignore errors in driver probe
Signed-off-by: Florian Mickler <florian@...kler.org>
CC: Mauro Carvalho Chehab <mchehab@...radead.org>
CC: linux-media@...r.kernel.org
CC: linux-kernel@...r.kernel.org
CC: Greg Kroah-Hartman <greg@...ah.com>
CC: Rafael J. Wysocki <rjw@...k.pl>
CC: Maciej Rutecki <maciej.rutecki@...il.com>
CC: Oliver Neukum <oliver@...kum.org>
CC: Jack Stone <jwjstone@...tmail.fm>
---
drivers/media/dvb/dvb-usb/dib0700_core.c | 13 ++++++++++---
1 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/drivers/media/dvb/dvb-usb/dib0700_core.c b/drivers/media/dvb/dvb-usb/dib0700_core.c
index 77a3060..3ad18ce 100644
--- a/drivers/media/dvb/dvb-usb/dib0700_core.c
+++ b/drivers/media/dvb/dvb-usb/dib0700_core.c
@@ -698,6 +698,7 @@ static int dib0700_probe(struct usb_interface *intf,
const struct usb_device_id *id)
{
int i;
+ int ret;
struct dvb_usb_device *dev;
for (i = 0; i < dib0700_device_count; i++)
@@ -706,8 +707,10 @@ static int dib0700_probe(struct usb_interface *intf,
struct dib0700_state *st = dev->priv;
u32 hwversion, romversion, fw_version, fwtype;
- dib0700_get_version(dev, &hwversion, &romversion,
+ ret = dib0700_get_version(dev, &hwversion, &romversion,
&fw_version, &fwtype);
+ if (ret < 0)
+ goto out;
deb_info("Firmware version: %x, %d, 0x%x, %d\n",
hwversion, romversion, fw_version, fwtype);
@@ -721,11 +724,15 @@ static int dib0700_probe(struct usb_interface *intf,
else
dev->props.rc.core.bulk_mode = false;
- dib0700_rc_setup(dev);
+ ret = dib0700_rc_setup(dev);
+ if (ret)
+ goto out;
return 0;
+out:
+ dvb_usb_device_exit();
+ return ret;
}
-
return -ENODEV;
}
--
1.7.4.rc3
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists