EDK2 doxygen online documents - Firmware Encoding Index 1
EDK2 doxygen online documents - Firmware Encoding Index
Functions | Variables

IntelFrameworkModulePkg/Universal/BdsDxe/Hotkey.c File Reference

#include "Hotkey.h"

Go to the source code of this file.

Functions

BOOLEAN IsKeyOptionValid (IN EFI_KEY_OPTION *KeyOption)
EFI_STATUS RegisterHotkey (IN EFI_KEY_OPTION *KeyOption, OUT UINT16 *KeyOptionNumber)
EFI_STATUS UnregisterHotkey (IN UINT16 KeyOptionNumber)
VOID HotkeyBoot (VOID)
EFI_STATUS EFIAPI HotkeyCallback (IN EFI_KEY_DATA *KeyData)
EFI_STATUS HotkeyRegisterNotify (IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *SimpleTextInEx)
VOID EFIAPI HotkeyEvent (IN EFI_EVENT Event, IN VOID *Context)
EFI_STATUS HotkeyInsertList (IN EFI_KEY_OPTION *KeyOption)
EFI_STATUS InitializeHotkeyService (VOID)

Variables

LIST_ENTRY mHotkeyList = INITIALIZE_LIST_HEAD_VARIABLE (mHotkeyList)
BDS_COMMON_OPTIONmHotkeyBootOption = NULL
EFI_EVENT mHotkeyEvent
VOID * mHotkeyRegistration

Detailed Description

Provides a way for 3rd party applications to register themselves for launch by the Boot Manager based on hot key

Copyright (c) 2007 - 2011, Intel Corporation. All rights reserved.
This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at http://opensource.org/licenses/bsd-license.php

THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.

Definition in file Hotkey.c.


Function Documentation

VOID HotkeyBoot ( VOID  )

Try to boot the boot option triggered by hotkey.

Definition at line 307 of file Hotkey.c.

EFI_STATUS EFIAPI HotkeyCallback ( IN EFI_KEY_DATA KeyData)

This is the common notification function for HotKeys, it will be registered with SimpleTextInEx protocol interface - RegisterKeyNotify() of ConIn handle.

Parameters:
KeyDataA pointer to a buffer that is filled in with the keystroke information for the key that was pressed.
Return values:
EFI_SUCCESSKeyData is successfully processed.
Returns:
EFI_NOT_FOUND Fail to find boot option variable.

Definition at line 360 of file Hotkey.c.

VOID EFIAPI HotkeyEvent ( IN EFI_EVENT  Event,
IN VOID *  Context 
)

Callback function for SimpleTextInEx protocol install events

Parameters:
Eventthe event that is signaled.
Contextnot used here.

Definition at line 495 of file Hotkey.c.

EFI_STATUS HotkeyInsertList ( IN EFI_KEY_OPTION KeyOption)

Insert Key Option to hotkey list.

Parameters:
KeyOptionThe Hot Key Option to be added to hotkey list.
Return values:
EFI_SUCCESSAdd to hotkey list success.
EFI_OUT_OF_RESOURCESFail to allocate memory resource.

Definition at line 541 of file Hotkey.c.

EFI_STATUS HotkeyRegisterNotify ( IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL SimpleTextInEx)

Register the common HotKey notify function to given SimpleTextInEx protocol instance.

Parameters:
SimpleTextInExSimple Text Input Ex protocol instance
Return values:
EFI_SUCCESSRegister hotkey notification function successfully.
EFI_OUT_OF_RESOURCESUnable to allocate necessary data structures.

Definition at line 446 of file Hotkey.c.

EFI_STATUS InitializeHotkeyService ( VOID  )

Process all the "Key####" variables, associate Hotkeys with corresponding Boot Options.

Return values:
EFI_SUCCESSHotkey services successfully initialized.
EFI_NOT_FOUNDCan not find the "KeyOrder" variable

Definition at line 645 of file Hotkey.c.

BOOLEAN IsKeyOptionValid ( IN EFI_KEY_OPTION KeyOption)

Check if the Key Option is valid or not.

Parameters:
KeyOptionThe Hot Key Option to be checked.
Return values:
TRUEThe Hot Key Option is valid.
FALSEThe Hot Key Option is invalid.

Definition at line 35 of file Hotkey.c.

EFI_STATUS RegisterHotkey ( IN EFI_KEY_OPTION KeyOption,
OUT UINT16 KeyOptionNumber 
)

Create Key#### for the given hotkey.

Parameters:
KeyOptionThe Hot Key Option to be added.
KeyOptionNumberThe key option number for Key#### (optional).
Return values:
EFI_SUCCESSRegister hotkey successfully.
EFI_INVALID_PARAMETERThe hotkey option is invalid.
EFI_OUT_OF_RESOURCESFail to allocate memory resource.

Definition at line 79 of file Hotkey.c.

EFI_STATUS UnregisterHotkey ( IN UINT16  KeyOptionNumber)

Delete Key#### for the given Key Option number.

Parameters:
KeyOptionNumberKey option number for Key####
Return values:
EFI_SUCCESSUnregister hotkey successfully.
EFI_NOT_FOUNDNo Key#### is found for the given Key Option number.

Definition at line 236 of file Hotkey.c.


Variable Documentation

Definition at line 20 of file Hotkey.c.

Definition at line 21 of file Hotkey.c.

LIST_ENTRY mHotkeyList = INITIALIZE_LIST_HEAD_VARIABLE (mHotkeyList)

Definition at line 19 of file Hotkey.c.

Definition at line 22 of file Hotkey.c.

 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Defines