]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
driver/misc/fsa9480.c fix potential null-pointer dereference
authorJonghwan Choi <jhbird.choi@samsung.com>
Wed, 28 Sep 2011 00:50:36 +0000 (10:50 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Tue, 4 Oct 2011 07:41:29 +0000 (18:41 +1100)
Signed-off-by: Jonghwan Choi <jhbird.choi@samsung.com>
Cc: Donggeun Kim <dg77.kim@samsung.com>
Cc: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Andrew Morton <>
drivers/misc/fsa9480.c

index 27dc0d21aafa36b73955105aa6097eb5c7836352..f6586d53e1a3a6d7314fb5c3bdcf34a61e956f7c 100644 (file)
@@ -400,7 +400,8 @@ static int fsa9480_irq_init(struct fsa9480_usbsw *usbsw)
                        return ret;
                }
 
-               device_init_wakeup(&client->dev, pdata->wakeup);
+               if (pdata)
+                       device_init_wakeup(&client->dev, pdata->wakeup);
        }
 
        return 0;