From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id E97B48240F for ; Fri, 23 Dec 2016 00:13:19 -0800 (PST) Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga101.fm.intel.com with ESMTP; 23 Dec 2016 00:13:19 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.33,392,1477983600"; d="scan'208";a="915466539" Received: from shwdeopenpsi068.ccr.corp.intel.com ([10.239.9.9]) by orsmga003.jf.intel.com with ESMTP; 23 Dec 2016 00:13:17 -0800 From: Star Zeng To: edk2-devel@lists.01.org Cc: Star Zeng , Ruiyu Ni , Michael Kinney , Feng Tian , Jeff Fan , Michael Zimmermann Date: Fri, 23 Dec 2016 16:13:07 +0800 Message-Id: <1482480792-35264-1-git-send-email-star.zeng@intel.com> X-Mailer: git-send-email 2.7.0.windows.1 Subject: [PATCH V2 0/5] Execute key notify function at TPL_CALLBACK X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 23 Dec 2016 08:13:20 -0000 Current implementation of keyboard driver executes key notify function in TimerHandler at TPL_NOTIFY. The code change is to make key notify function executed at TPL_CALLBACK to reduce the time occupied at TPL_NOTIFY. The code will signal KeyNotify process event if the key pressed matches any key registered and insert the KeyData to the EFI Key queue for notify, then the KeyNotify process handler will invoke key notify functions at TPL_CALLBACK. It can also address the problem raised at https://lists.01.org/pipermail/edk2-devel/2016-December/005644.html V2: Based on the comments from Ruiyu, Ni, add comments before calling Enqueue() to make the code more clear and eliminate the call to IsQueueEmpty() in KeyNotifyProcessHandler(). Cc: Ruiyu Ni Cc: Michael Kinney Cc: Feng Tian Cc: Jeff Fan Cc: Michael Zimmermann Star Zeng (5): MdeModulePkg UsbKbDxe: Execute key notify func at TPL_CALLBACK MdeModulePkg TerminalDxe: Execute key notify func at TPL_CALLBACK MdeModulePkg Ps2KbDxe: Execute key notify func at TPL_CALLBACK IntelFrameworkModulePkg Ps2KbDxe: Execute key notify func at TPL_CALLBACK IntelFrameworkModulePkg KbDxe: Execute key notify func at TPL_CALLBACK .../Bus/Isa/Ps2KeyboardDxe/Ps2KbdCtrller.c | 14 +- .../Bus/Isa/Ps2KeyboardDxe/Ps2KbdTextIn.c | 51 +++++- .../Bus/Isa/Ps2KeyboardDxe/Ps2Keyboard.c | 23 ++- .../Bus/Isa/Ps2KeyboardDxe/Ps2Keyboard.h | 15 ++ .../Csm/BiosThunk/KeyboardDxe/BiosKeyboard.c | 86 +++++++++- .../Csm/BiosThunk/KeyboardDxe/BiosKeyboard.h | 17 +- .../Bus/Isa/Ps2KeyboardDxe/Ps2KbdCtrller.c | 12 +- MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KbdTextIn.c | 49 ++++++ MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2Keyboard.c | 20 +++ MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2Keyboard.h | 15 ++ MdeModulePkg/Bus/Usb/UsbKbDxe/EfiKey.c | 68 +++++++- MdeModulePkg/Bus/Usb/UsbKbDxe/EfiKey.h | 17 +- MdeModulePkg/Bus/Usb/UsbKbDxe/KeyBoard.c | 12 +- .../Universal/Console/TerminalDxe/Terminal.c | 25 ++- .../Universal/Console/TerminalDxe/Terminal.h | 80 ++++++++- .../Universal/Console/TerminalDxe/TerminalConIn.c | 186 ++++++++++++++++++++- 16 files changed, 665 insertions(+), 25 deletions(-) -- 2.7.0.windows.1