[media] r820t: precendence bug in r820t_xtal_check()
authorDan Carpenter <dan.carpenter@oracle.com>
Thu, 18 Apr 2013 18:20:40 +0000 (15:20 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Thu, 25 Apr 2013 13:29:56 +0000 (10:29 -0300)
The test as written is always false.  It looks like the intent was to
test that the bit was not set.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/tuners/r820t.c

index 905a10615e520c96a9f27ffd518c96007b162c5c..ba033fd6b7171c974dc0a944811efa0b83c99620 100644 (file)
@@ -1378,7 +1378,7 @@ static int r820t_xtal_check(struct r820t_priv *priv)
                rc = r820t_read(priv, 0x00, data, sizeof(data));
                if (rc < 0)
                        return rc;
-               if ((!data[2]) & 0x40)
+               if (!(data[2] & 0x40))
                        continue;
 
                val = data[2] & 0x3f;