]> git.proxmox.com Git - mirror_edk2.git/blob - IntelFrameworkModulePkg/Universal/Console/VgaClassDxe/VgaClass.h
Correct all header files for doxygen format and correct the license issue for VgaClas...
[mirror_edk2.git] / IntelFrameworkModulePkg / Universal / Console / VgaClassDxe / VgaClass.h
1 /**@file
2
3 Copyright (c) 2006, Intel Corporation
4 All rights reserved. This program and the accompanying materials
5 are licensed and made available under the terms and conditions of the BSD License
6 which accompanies this distribution. The full text of the license may be found at
7 http://opensource.org/licenses/bsd-license.php
8
9 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
10 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
11
12 **/
13
14
15 #ifndef _VGA_CLASS_H
16 #define _VGA_CLASS_H
17
18 #include <PiDxe.h>
19 #include <FrameworkDxe.h>
20
21 #include <Protocol/SimpleTextIn.h>
22 #include <Protocol/SimpleTextOut.h>
23 #include <Protocol/PciIo.h>
24 #include <Protocol/VgaMiniPort.h>
25 #include <Protocol/DevicePath.h>
26
27 #include <Library/DebugLib.h>
28 #include <Library/UefiDriverEntryPoint.h>
29 #include <Library/BaseLib.h>
30 #include <Library/UefiLib.h>
31 #include <Library/DevicePathLib.h>
32 #include <Library/BaseMemoryLib.h>
33 #include <Library/MemoryAllocationLib.h>
34 #include <Library/UefiBootServicesTableLib.h>
35 #include <Library/ReportStatusCodeLib.h>
36
37
38 #include <IndustryStandard/Pci22.h>
39 #include "ComponentName.h"
40 #include <Protocol/VgaMiniPort.h>
41
42 //
43 // VGA specific registers
44 //
45 #define CRTC_CURSOR_START 0xA
46 #define CRTC_CURSOR_END 0xB
47
48 #define CRTC_CURSOR_LOCATION_HIGH 0xE
49 #define CRTC_CURSOR_LOCATION_LOW 0xF
50
51 #define EFI_MAX_ATTRIBUTE 0x7f
52
53 //
54 // VGA Class Device Structure
55 //
56 #define VGA_CLASS_DEV_SIGNATURE EFI_SIGNATURE_32 ('V', 'G', 'A', 'C')
57
58 typedef struct {
59 UINTN Signature;
60 EFI_HANDLE Handle;
61 EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL SimpleTextOut;
62 EFI_SIMPLE_TEXT_OUTPUT_MODE SimpleTextOutputMode;
63 EFI_VGA_MINI_PORT_PROTOCOL *VgaMiniPort;
64 EFI_PCI_IO_PROTOCOL *PciIo;
65 EFI_DEVICE_PATH_PROTOCOL *DevicePath;
66 } VGA_CLASS_DEV;
67
68 #define VGA_CLASS_DEV_FROM_THIS(a) CR (a, VGA_CLASS_DEV, SimpleTextOut, VGA_CLASS_DEV_SIGNATURE)
69
70 //
71 // Global Variables
72 //
73 extern EFI_DRIVER_BINDING_PROTOCOL gVgaClassDriverBinding;
74
75 //
76 // Driver Binding Protocol functions
77 //
78 EFI_STATUS
79 EFIAPI
80 VgaClassDriverBindingSupported (
81 IN EFI_DRIVER_BINDING_PROTOCOL *This,
82 IN EFI_HANDLE Controller,
83 IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
84 )
85 /*++
86
87 Routine Description:
88
89 GC_TODO: Add function description
90
91 Arguments:
92
93 This - GC_TODO: add argument description
94 Controller - GC_TODO: add argument description
95 RemainingDevicePath - GC_TODO: add argument description
96
97 Returns:
98
99 GC_TODO: add return values
100
101 --*/
102 ;
103
104 EFI_STATUS
105 EFIAPI
106 VgaClassDriverBindingStart (
107 IN EFI_DRIVER_BINDING_PROTOCOL *This,
108 IN EFI_HANDLE Controller,
109 IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
110 )
111 /*++
112
113 Routine Description:
114
115 GC_TODO: Add function description
116
117 Arguments:
118
119 This - GC_TODO: add argument description
120 Controller - GC_TODO: add argument description
121 RemainingDevicePath - GC_TODO: add argument description
122
123 Returns:
124
125 GC_TODO: add return values
126
127 --*/
128 ;
129
130 EFI_STATUS
131 EFIAPI
132 VgaClassDriverBindingStop (
133 IN EFI_DRIVER_BINDING_PROTOCOL *This,
134 IN EFI_HANDLE Controller,
135 IN UINTN NumberOfChildren,
136 IN EFI_HANDLE *ChildHandleBuffer
137 )
138 /*++
139
140 Routine Description:
141
142 GC_TODO: Add function description
143
144 Arguments:
145
146 This - GC_TODO: add argument description
147 Controller - GC_TODO: add argument description
148 NumberOfChildren - GC_TODO: add argument description
149 ChildHandleBuffer - GC_TODO: add argument description
150
151 Returns:
152
153 GC_TODO: add return values
154
155 --*/
156 ;
157
158 //
159 // Simple Text Output Protocol functions
160 //
161 EFI_STATUS
162 EFIAPI
163 VgaClassReset (
164 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,
165 IN BOOLEAN ExtendedVerification
166 )
167 /*++
168
169 Routine Description:
170
171 GC_TODO: Add function description
172
173 Arguments:
174
175 This - GC_TODO: add argument description
176 ExtendedVerification - GC_TODO: add argument description
177
178 Returns:
179
180 GC_TODO: add return values
181
182 --*/
183 ;
184
185 EFI_STATUS
186 EFIAPI
187 VgaClassOutputString (
188 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,
189 IN CHAR16 *WString
190 )
191 /*++
192
193 Routine Description:
194
195 GC_TODO: Add function description
196
197 Arguments:
198
199 This - GC_TODO: add argument description
200 WString - GC_TODO: add argument description
201
202 Returns:
203
204 GC_TODO: add return values
205
206 --*/
207 ;
208
209 EFI_STATUS
210 EFIAPI
211 VgaClassTestString (
212 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,
213 IN CHAR16 *WString
214 )
215 /*++
216
217 Routine Description:
218
219 GC_TODO: Add function description
220
221 Arguments:
222
223 This - GC_TODO: add argument description
224 WString - GC_TODO: add argument description
225
226 Returns:
227
228 GC_TODO: add return values
229
230 --*/
231 ;
232
233 EFI_STATUS
234 EFIAPI
235 VgaClassClearScreen (
236 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This
237 )
238 /*++
239
240 Routine Description:
241
242 GC_TODO: Add function description
243
244 Arguments:
245
246 This - GC_TODO: add argument description
247
248 Returns:
249
250 GC_TODO: add return values
251
252 --*/
253 ;
254
255 EFI_STATUS
256 EFIAPI
257 VgaClassSetAttribute (
258 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,
259 IN UINTN Attribute
260 )
261 /*++
262
263 Routine Description:
264
265 GC_TODO: Add function description
266
267 Arguments:
268
269 This - GC_TODO: add argument description
270 Attribute - GC_TODO: add argument description
271
272 Returns:
273
274 GC_TODO: add return values
275
276 --*/
277 ;
278
279 EFI_STATUS
280 EFIAPI
281 VgaClassSetCursorPosition (
282 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,
283 IN UINTN Column,
284 IN UINTN Row
285 )
286 /*++
287
288 Routine Description:
289
290 GC_TODO: Add function description
291
292 Arguments:
293
294 This - GC_TODO: add argument description
295 Column - GC_TODO: add argument description
296 Row - GC_TODO: add argument description
297
298 Returns:
299
300 GC_TODO: add return values
301
302 --*/
303 ;
304
305 EFI_STATUS
306 EFIAPI
307 VgaClassEnableCursor (
308 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,
309 IN BOOLEAN Visible
310 )
311 /*++
312
313 Routine Description:
314
315 GC_TODO: Add function description
316
317 Arguments:
318
319 This - GC_TODO: add argument description
320 Visible - GC_TODO: add argument description
321
322 Returns:
323
324 GC_TODO: add return values
325
326 --*/
327 ;
328
329 EFI_STATUS
330 EFIAPI
331 VgaClassQueryMode (
332 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,
333 IN UINTN ModeNumber,
334 OUT UINTN *Columns,
335 OUT UINTN *Rows
336 )
337 /*++
338
339 Routine Description:
340
341 GC_TODO: Add function description
342
343 Arguments:
344
345 This - GC_TODO: add argument description
346 ModeNumber - GC_TODO: add argument description
347 Columns - GC_TODO: add argument description
348 Rows - GC_TODO: add argument description
349
350 Returns:
351
352 GC_TODO: add return values
353
354 --*/
355 ;
356
357 EFI_STATUS
358 EFIAPI
359 VgaClassSetMode (
360 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,
361 IN UINTN ModeNumber
362 )
363 /*++
364
365 Routine Description:
366
367 GC_TODO: Add function description
368
369 Arguments:
370
371 This - GC_TODO: add argument description
372 ModeNumber - GC_TODO: add argument description
373
374 Returns:
375
376 GC_TODO: add return values
377
378 --*/
379 ;
380
381 #endif