summaryrefslogtreecommitdiff
path: root/Include/PPI/AmiKeyCodePpi.h
blob: 0da3b26792b071d23de5cb9f02c5e7937d6ec6a5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
//*************************************************************************
//*************************************************************************
//**                                                                     **
//**        (C)Copyright 1985-2011, American Megatrends, Inc.            **
//**                                                                     **
//**                       All Rights Reserved.                          **
//**                                                                     **
//**      5555 Oakbrook Parkway, Suite 200, Norcross, GA 30093           **
//**                                                                     **
//**                       Phone: (770)-246-8600                         **
//**                                                                     **
//*************************************************************************
//*************************************************************************

//**********************************************************************
// $Header: /Alaska/BIN/Core/Include/PPI/AmiKeycodePpi.h 2     10/07/11 5:03a Rameshr $
//
// $Revision: 2 $
//
// $Date: 10/07/11 5:03a $
//**********************************************************************
// Revision History
// ----------------
// $Log: /Alaska/BIN/Core/Include/PPI/AmiKeycodePpi.h $
// 
// 2     10/07/11 5:03a Rameshr
// [TAG] - EIP 64356
// [Category]- IMPROVEMENT
// [Description]- Check-in the AmiKeyCodePPI.h as a generic PPI
// [Files] - AmiKeycodePpi.h
// 
// 1     8/09/11 4:40p Olegi
// Initial Amikeycode PPI header file check in.
// 
//*************************************************************************

//<AMI_FHDR_START>
//---------------------------------------------------------------------------
//
// Name:	AmiKeycodePpi.h
//
// Description: Interface with the input devices in PEI
//
//---------------------------------------------------------------------------
//<AMI_FHDR_END>

#ifndef __AMI_AMIKEYCODE_PPI_H__
#define __AMI_AMIKEYCODE_PPI_H__
#ifdef __cplusplus
extern "C" {
#endif

#include "KeyboardCommonDefinitions.h"

//
//Guid for Normal AmiKeycodePPI ( Ex: Ps2 and USB)
//
// {20B0F1C2-B0D8-4c5d-AAD9-F44580DFDF8B}
#define EFI_PEI_AMI_KEYCODE_PPI_GUID \
    {0x20b0f1c2, 0xb0d8, 0x4c5d, 0xaa, 0xd9, 0xf4, 0x45, 0x80, 0xdf, 0xdf, 0x8b}

//
// Guid for PEI Consplitter AmiKeyCodePPI
//
// {73DDB5E1-5FB4-4751-AF1E-83CF75BECBB6}
#define EFI_PEI_CONSPLIT_AMI_KEYCODE_PPI_GUID \
    {0x73ddb5e1, 0x5fb4, 0x4751, 0xaf, 0x1e, 0x83, 0xcf, 0x75, 0xbe, 0xcb, 0xb6}

GUID_VARIABLE_DECLARATION(gPeiAmikeycodeInputPpiGuid,EFI_PEI_AMI_KEYCODE_PPI_GUID);

GUID_VARIABLE_DECLARATION(gPeiConsplitAmikeycodeInputPpiGuid,EFI_PEI_CONSPLIT_AMI_KEYCODE_PPI_GUID);

typedef struct {
    EFI_INPUT_KEY       Key;
    EFI_KEY_STATE       KeyState;
    EFI_KEY             EfiKey;
    UINT8               PS2ScanCode;
} EFI_PEI_AMIKEYCODE_DATA;

typedef struct _EFI_PEI_AMIKEYCODE_PPI EFI_PEI_AMIKEYCODE_PPI;

typedef EFI_STATUS (EFIAPI * EFI_PEI_AMIKEYCODE_READKEY) (
    IN  EFI_PEI_SERVICES            **PeiServices,
    IN  EFI_PEI_AMIKEYCODE_PPI      *This,
    OUT EFI_PEI_AMIKEYCODE_DATA     *KeyData
);

typedef EFI_STATUS (EFIAPI * EFI_PEI_AMIKEYCODE_SETLEDSTATE) (
    IN  EFI_PEI_SERVICES            **PeiServices,
    IN  EFI_PEI_AMIKEYCODE_PPI      *This,
    IN  EFI_KEY_TOGGLE_STATE        KeyToggleState
);

struct _EFI_PEI_AMIKEYCODE_PPI {
    EFI_PEI_AMIKEYCODE_READKEY      ReadKey;
    EFI_PEI_AMIKEYCODE_SETLEDSTATE  SetLedState;
};

/****** DO NOT WRITE BELOW THIS LINE *******/
#ifdef __cplusplus
}
#endif
#endif

//*************************************************************************
//*************************************************************************
//**                                                                     **
//**        (C)Copyright 1985-2011, American Megatrends, Inc.            **
//**                                                                     **
//**                       All Rights Reserved.                          **
//**                                                                     **
//**      5555 Oakbrook Parkway, Suite 200, Norcross, GA 30093           **
//**                                                                     **
//**                       Phone: (770)-246-8600                         **
//**                                                                     **
//*************************************************************************
//*************************************************************************