firedtv: fix registration - adapter number could only be zero
authorHenrik Kurelid <henrik@kurelid.se>
Mon, 15 Dec 2008 07:17:12 +0000 (08:17 +0100)
committerStefan Richter <stefanr@s5r6.in-berlin.de>
Tue, 24 Feb 2009 13:51:28 +0000 (14:51 +0100)
There was a bug causing the initialization to fail if adapter number was
greater than zero. The adapter was however registered which caused the driver
to oops the second time initialization was tried.

Signed-off-by: Henrik Kurelid <henrik@kurelid.se>
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
drivers/media/dvb/firesat/firesat_dvb.c

index cfa3a2e8edd1e573048cfccc0eb62d6fb045164d..cb36c0310199c2ebbf429c607f6856640640ba29 100644 (file)
@@ -206,7 +206,7 @@ int firesat_dvbdev_init(struct firesat *firesat, struct device *dev)
        err = DVB_REGISTER_ADAPTER(&firesat->adapter,
                                   firedtv_model_names[firesat->type],
                                   THIS_MODULE, dev, adapter_nr);
-       if (err)
+       if (err < 0)
                goto fail_log;
 
        /*DMX_TS_FILTERING | DMX_SECTION_FILTERING*/