Input: i8042 - try to get stable CTR value when initializing
authorDmitry Torokhov <dmitry.torokhov@gmail.com>
Tue, 3 Nov 2009 05:57:40 +0000 (21:57 -0800)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Tue, 3 Nov 2009 06:11:43 +0000 (22:11 -0800)
commitee1e82cee5e463a885d3c71acb2c769490e6927f
tree288e9baeae958db78a170e18b8c885699cfbf198
parent7a53c7f56bbfc9b0ef892e68f5cfae3d902544d1
Input: i8042 - try to get stable CTR value when initializing

If user presses keys while i8042 is being initialized there is a chance
that keyboard data will be mistaken for results of Read Control Register
command causing futher troubles. Work around this issue by reading CTR
several times and stop when we get matching results.

Reported-and-tested-by: Dave Young <hidave.darkstar@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
drivers/input/serio/i8042.c