NFC: Remove unneeded pn533 dev NULL check
authorDan Carpenter <dan.carpenter@oracle.com>
Mon, 7 May 2012 10:31:18 +0000 (12:31 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 15 May 2012 21:28:01 +0000 (17:28 -0400)
container_of() works by subtracting the offset of the member.  The math
can't really return a zero here.  Sometimes people check it when they
actually meant to check something else but in this case we can just
remove the check.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/nfc/pn533.c

index 766e0bb5ae53cfb9d67382ec2597bc2d1712a5ca..19110f0eb15f2d0b15bafbdd8109f155004db7f5 100644 (file)
@@ -394,9 +394,6 @@ static void pn533_wq_cmd_complete(struct work_struct *work)
        struct pn533_frame *in_frame;
        int rc;
 
-       if (dev == NULL)
-               return;
-
        in_frame = dev->wq_in_frame;
 
        if (dev->wq_in_error)