[media] m920x: fix ERROR: do not use assignment in if condition
authorMichael Krufky <mkrufky@kernellabs.com>
Sat, 17 Sep 2011 17:59:54 +0000 (14:59 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Wed, 21 Sep 2011 13:07:32 +0000 (10:07 -0300)
Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/dvb/dvb-usb/m920x.c

index c3e461e9fa71895e0cea7f85404552a410109637..a1e1287c949edcf4f150d2779e3e9f59efcb4531 100644 (file)
@@ -501,9 +501,10 @@ static int m920x_mt352_frontend_attach(struct dvb_usb_adapter *adap)
 {
        deb("%s\n",__func__);
 
-       if ((adap->fe_adap[0].fe = dvb_attach(mt352_attach,
-                                  &m920x_mt352_config,
-                                  &adap->dev->i2c_adap)) == NULL)
+       adap->fe_adap[0].fe = dvb_attach(mt352_attach,
+                                        &m920x_mt352_config,
+                                        &adap->dev->i2c_adap);
+       if ((adap->fe_adap[0].fe) == NULL)
                return -EIO;
 
        return 0;
@@ -513,9 +514,10 @@ static int m920x_tda10046_08_frontend_attach(struct dvb_usb_adapter *adap)
 {
        deb("%s\n",__func__);
 
-       if ((adap->fe_adap[0].fe = dvb_attach(tda10046_attach,
-                                  &m920x_tda10046_08_config,
-                                  &adap->dev->i2c_adap)) == NULL)
+       adap->fe_adap[0].fe = dvb_attach(tda10046_attach,
+                                        &m920x_tda10046_08_config,
+                                        &adap->dev->i2c_adap);
+       if ((adap->fe_adap[0].fe) == NULL)
                return -EIO;
 
        return 0;
@@ -525,9 +527,10 @@ static int m920x_tda10046_0b_frontend_attach(struct dvb_usb_adapter *adap)
 {
        deb("%s\n",__func__);
 
-       if ((adap->fe_adap[0].fe = dvb_attach(tda10046_attach,
-                                  &m920x_tda10046_0b_config,
-                                  &adap->dev->i2c_adap)) == NULL)
+       adap->fe_adap[0].fe = dvb_attach(tda10046_attach,
+                                        &m920x_tda10046_0b_config,
+                                        &adap->dev->i2c_adap);
+       if ((adap->fe_adap[0].fe) == NULL)
                return -EIO;
 
        return 0;