]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/commit
Input: keyboard - fix theoretical race on vt switch
authorAlan Jenkins <alan-jenkins@tuffmail.co.uk>
Wed, 18 Nov 2009 08:40:48 +0000 (00:40 -0800)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Fri, 20 Nov 2009 08:52:14 +0000 (00:52 -0800)
commit0c09b2ac35ff7c5f280e5cf8142ad0822f1c93b3
tree91e207b9032e75988613f75fed949c43f60b3c21
parent71bb21b677e89a2b438b804231f92b779beda5d7
Input: keyboard - fix theoretical race on vt switch

A VT switch can theoretically change fg_console between

        vc = vc_cons[fg_console].d
and
        kbd = kbd_table + fg_console

Fix it by replacing the second fg_console with vc->vc_num.

Signed-off-by: Alan Jenkins <alan-jenkins@tuffmail.co.uk>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
drivers/char/keyboard.c