]> git.proxmox.com Git - mirror_edk2.git/blame - MdeModulePkg/Universal/BdsDxe/DeviceMngr/DeviceManager.h
clean up the un-suitable ';' location when declaring the functions.
[mirror_edk2.git] / MdeModulePkg / Universal / BdsDxe / DeviceMngr / DeviceManager.h
CommitLineData
fd6a62f3 1/** @file\r
2 The platform device manager reference implement\r
93e3992d 3\r
fd6a62f3 4Copyright (c) 2004 - 2008, Intel Corporation. <BR>\r
93e3992d 5All rights reserved. This program and the accompanying materials\r
6are licensed and made available under the terms and conditions of the BSD License\r
7which accompanies this distribution. The full text of the license may be found at\r
8http://opensource.org/licenses/bsd-license.php\r
9\r
10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
11WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
12\r
fd6a62f3 13**/\r
93e3992d 14\r
7b3e2a1b 15#ifndef _DEVICE_MANAGER_H_\r
16#define _DEVICE_MANAGER_H_\r
93e3992d 17\r
18#include "Bds.h"\r
19#include "FrontPage.h"\r
20\r
21//\r
22// These are defined as the same with vfr file\r
23//\r
24#define DEVICE_MANAGER_FORMSET_GUID \\r
25 { \\r
26 0x3ebfa8e6, 0x511d, 0x4b5b, {0xa9, 0x5f, 0xfb, 0x38, 0x26, 0xf, 0x1c, 0x27} \\r
27 }\r
28\r
29#define LABEL_VBIOS 0x0040\r
30\r
31#define DEVICE_MANAGER_FORM_ID 0x1000\r
32\r
33#define DEVICE_KEY_OFFSET 0x1000\r
34#define DEVICE_MANAGER_KEY_VBIOS 0x2000\r
35\r
36//\r
37// These are the VFR compiler generated data representing our VFR data.\r
38//\r
39extern UINT8 DeviceManagerVfrBin[];\r
40\r
41#define DEVICE_MANAGER_CALLBACK_DATA_SIGNATURE EFI_SIGNATURE_32 ('D', 'M', 'C', 'B')\r
42\r
43typedef struct {\r
44 UINTN Signature;\r
45\r
30394aa1 46 ///\r
47 /// HII relative handles\r
48 ///\r
93e3992d 49 EFI_HII_HANDLE HiiHandle;\r
50 EFI_HANDLE DriverHandle;\r
51\r
30394aa1 52 ///\r
53 /// Produced protocols\r
54 ///\r
93e3992d 55 EFI_HII_CONFIG_ACCESS_PROTOCOL ConfigAccess;\r
56\r
30394aa1 57 ///\r
58 /// Configuration data\r
59 ///\r
93e3992d 60 UINT8 VideoBios;\r
61} DEVICE_MANAGER_CALLBACK_DATA;\r
62\r
63#define DEVICE_MANAGER_CALLBACK_DATA_FROM_THIS(a) \\r
64 CR (a, \\r
65 DEVICE_MANAGER_CALLBACK_DATA, \\r
66 ConfigAccess, \\r
67 DEVICE_MANAGER_CALLBACK_DATA_SIGNATURE \\r
68 )\r
93e3992d 69typedef struct {\r
70 EFI_STRING_ID StringId;\r
71 UINT16 Class;\r
72} DEVICE_MANAGER_MENU_ITEM;\r
73\r
b30312ba 74/**\r
30394aa1 75 This function is invoked if user selected a iteractive opcode from Device Manager's\r
76 Formset. The decision by user is saved to gCallbackKey for later processing. If\r
77 user set VBIOS, the new value is saved to EFI variable.\r
b30312ba 78\r
b30312ba 79\r
30394aa1 80 @param This Points to the EFI_HII_CONFIG_ACCESS_PROTOCOL.\r
81 @param Action Specifies the type of action taken by the browser.\r
82 @param QuestionId A unique value which is sent to the original exporting driver\r
83 so that it can identify the type of data to expect.\r
84 @param Type The type of value for the question.\r
85 @param Value A pointer to the data being sent to the original exporting driver.\r
86 @param ActionRequest On return, points to the action requested by the callback function.\r
87\r
88 @retval EFI_SUCCESS The callback successfully handled the action.\r
89 @retval EFI_INVALID_PARAMETER The setup browser call this function with invalid parameters.\r
b30312ba 90\r
91**/\r
93e3992d 92EFI_STATUS\r
93EFIAPI\r
94DeviceManagerCallback (\r
95 IN CONST EFI_HII_CONFIG_ACCESS_PROTOCOL *This,\r
96 IN EFI_BROWSER_ACTION Action,\r
97 IN EFI_QUESTION_ID QuestionId,\r
98 IN UINT8 Type,\r
99 IN EFI_IFR_TYPE_VALUE *Value,\r
100 OUT EFI_BROWSER_ACTION_REQUEST *ActionRequest\r
ed66e1bc 101 );\r
93e3992d 102\r
b30312ba 103/**\r
b30312ba 104\r
30394aa1 105 This function registers HII packages to HII database.\r
b30312ba 106\r
30394aa1 107 @retval EFI_SUCCESS This function complete successfully.\r
108 @return Other value if failed to register HII packages.\r
b30312ba 109\r
110**/\r
93e3992d 111EFI_STATUS\r
112InitializeDeviceManager (\r
113 VOID\r
ed66e1bc 114 );\r
93e3992d 115\r
b30312ba 116/**\r
b30312ba 117\r
30394aa1 118 Call the browser and display the device manager to allow user\r
119 to configure the platform.\r
b30312ba 120\r
30394aa1 121 This function create the dynamic content for device manager. It includes\r
122 section header for all class of devices, one-of opcode to set VBIOS.\r
123 \r
124 @retval EFI_SUCCESS Operation is successful.\r
125 @retval Other values if failed to clean up the dynamic content from HII\r
126 database.\r
b30312ba 127\r
128**/\r
93e3992d 129EFI_STATUS\r
130CallDeviceManager (\r
131 VOID\r
ed66e1bc 132 );\r
93e3992d 133\r
134#endif\r