From: Wei Yongjun <weiyongj...@huawei.com>

Fix to return error code -ENODEV from the error handling case
instead of 0(err maybe overwrited to 0 in the for loop), as
done elsewhere in this function.

Signed-off-by: Wei Yongjun <weiyongj...@huawei.com>
---
 drivers/media/pci/cx88/cx88-dvb.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/media/pci/cx88/cx88-dvb.c 
b/drivers/media/pci/cx88/cx88-dvb.c
index ac2392d..d76a175 100644
--- a/drivers/media/pci/cx88/cx88-dvb.c
+++ b/drivers/media/pci/cx88/cx88-dvb.c
@@ -1779,6 +1779,7 @@ static int cx8802_dvb_probe(struct cx8802_driver *drv)
                if (fe == NULL) {
                        printk(KERN_ERR "%s() failed to get frontend(%d)\n",
                                        __func__, i);
+                       err = -ENODEV;
                        goto fail_probe;
                }
                q = &fe->dvb.dvbq;

--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to