]> git.proxmox.com Git - mirror_edk2.git/blobdiff - IntelFrameworkModulePkg/Universal/BdsDxe/Hotkey.h
The hotkey callback in BDS module should defer loading the boot option until the...
[mirror_edk2.git] / IntelFrameworkModulePkg / Universal / BdsDxe / Hotkey.h
index f2d1c60bf649d652d5cb9f6a741b2a30989e750e..3fd80443a5879cceabe0c52ae28f0661333c559b 100644 (file)
@@ -2,8 +2,8 @@
   Provides a way for 3rd party applications to register themselves for launch by the\r
   Boot Manager based on hot key\r
 \r
-Copyright (c) 2007 - 2008, Intel Corporation. <BR>\r
-All rights reserved. This program and the accompanying materials\r
+Copyright (c) 2007 - 2011, Intel Corporation. All rights reserved.<BR>\r
+This program and the accompanying materials\r
 are licensed and made available under the terms and conditions of the BSD License\r
 which accompanies this distribution.  The full text of the license may be found at\r
 http://opensource.org/licenses/bsd-license.php\r
@@ -19,9 +19,14 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 #include "Bds.h"\r
 #include "String.h"\r
 \r
-#define GET_KEY_CODE_COUNT(KeyOptions)      (((KeyOptions) & EFI_KEY_CODE_COUNT) >> 8)\r
+#define GET_BOOT_OPTION_SUPPORT_KEY_COUNT(a) (((a) & EFI_BOOT_OPTION_SUPPORT_COUNT) >> 8)\r
+#define SET_BOOT_OPTION_SUPPORT_KEY_COUNT(a, c) {  \\r
+      (a) = ((a) & ~EFI_BOOT_OPTION_SUPPORT_COUNT) | (((c) << 8) & EFI_BOOT_OPTION_SUPPORT_COUNT); \\r
+      }\r
 \r
 #define BDS_HOTKEY_OPTION_SIGNATURE SIGNATURE_32 ('B', 'd', 'K', 'O')\r
+\r
+\r
 typedef struct {\r
   UINTN                     Signature;\r
   LIST_ENTRY                Link;\r
@@ -87,4 +92,12 @@ InitializeHotkeyService (
   VOID\r
   );\r
 \r
+/**\r
+  Try to boot the boot option triggered by hotkey.\r
+**/\r
+VOID\r
+HotkeyBoot (\r
+  VOID\r
+  );\r
+\r
 #endif\r