Skip to content

Commit

Permalink
Input: kxtj9 - fix bug in probe()
Browse files Browse the repository at this point in the history
We are testing the wrong variable here.  I believe tj9->input_dev
is always NULL at this point, so probe() will fail.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
  • Loading branch information
Dan Carpenter authored and Dmitry Torokhov committed Jul 20, 2011
1 parent e449edb commit 4fd9fcf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/input/misc/kxtj9.c
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ static int __devinit kxtj9_setup_input_device(struct kxtj9_data *tj9)
int err;

input_dev = input_allocate_device();
if (!tj9->input_dev) {
if (!input_dev) {
dev_err(&tj9->client->dev, "input device allocate failed\n");
return -ENOMEM;
}
Expand Down

0 comments on commit 4fd9fcf

Please sign in to comment.