VirtualBox

source: vbox/trunk/src/VBox/Devices/EFI/Firmware2/VBoxPkg/VBoxAppleSim/Console.c@ 35072

最後變更 在這個檔案從35072是 29070,由 vboxsync 提交於 15 年 前

EFI: more OSE exports

  • 屬性 svn:eol-style 設為 native
  • 屬性 svn:keywords 設為 Author Date Id Revision
檔案大小: 2.1 KB
 
1/* $Id: Console.c 29070 2010-05-05 12:32:52Z vboxsync $ */
2/** @file
3 * Console.c - VirtualBox Console control emulation
4 */
5
6/*
7 * Copyright (C) 2010 Oracle Corporation
8 *
9 * This file is part of VirtualBox Open Source Edition (OSE), as
10 * available from http://www.alldomusa.eu.org. This file is free software;
11 * you can redistribute it and/or modify it under the terms of the GNU
12 * General Public License (GPL) as published by the Free Software
13 * Foundation, in version 2 as it comes in the "COPYING" file of the
14 * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
15 * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
16 */
17#include <Uefi.h>
18#include <Library/UefiBootServicesTableLib.h>
19#include <Library/DebugLib.h>
20
21#include "VBoxPkg.h"
22#include "ConsoleControl.h"
23
24EFI_STATUS EFIAPI
25GetModeImpl(
26 IN EFI_CONSOLE_CONTROL_PROTOCOL *This,
27 OUT EFI_CONSOLE_CONTROL_SCREEN_MODE *Mode,
28 OUT BOOLEAN *GopUgaExists, OPTIONAL
29 OUT BOOLEAN *StdInLocked OPTIONAL
30 )
31{
32 *Mode = EfiConsoleControlScreenGraphics;
33
34 if (GopUgaExists)
35 *GopUgaExists = TRUE;
36 if (StdInLocked)
37 *StdInLocked = FALSE;
38 return EFI_SUCCESS;
39}
40
41EFI_STATUS EFIAPI
42SetModeImpl(
43 IN EFI_CONSOLE_CONTROL_PROTOCOL *This,
44 IN EFI_CONSOLE_CONTROL_SCREEN_MODE Mode
45 )
46{
47 return EFI_SUCCESS;
48}
49
50EFI_STATUS EFIAPI
51LockStdInImpl(
52 IN EFI_CONSOLE_CONTROL_PROTOCOL *This,
53 IN CHAR16 *Password
54 )
55{
56 return EFI_SUCCESS;
57}
58
59
60EFI_CONSOLE_CONTROL_PROTOCOL gConsoleController =
61{
62 GetModeImpl,
63 SetModeImpl,
64 LockStdInImpl
65};
66
67EFI_GUID gEfiConsoleControlProtocolGuid = EFI_CONSOLE_CONTROL_PROTOCOL_GUID;
68
69EFI_STATUS
70EFIAPI
71InitializeConsoleSim (
72 IN EFI_HANDLE ImageHandle,
73 IN EFI_SYSTEM_TABLE *SystemTable
74 )
75{
76 EFI_STATUS Status;
77
78 Status = gBS->InstallMultipleProtocolInterfaces (
79 &ImageHandle,
80 &gEfiConsoleControlProtocolGuid,
81 &gConsoleController,
82 NULL
83 );
84 ASSERT_EFI_ERROR (Status);
85
86 return Status;
87}
注意: 瀏覽 TracBrowser 來幫助您使用儲存庫瀏覽器

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette