TianoCore EDK2 master
Loading...
Searching...
No Matches
Qemu.h File Reference

Go to the source code of this file.

Data Structures

struct  QEMU_VIDEO_MODE_DATA
 
struct  QEMU_VIDEO_CARD
 
struct  QEMU_VIDEO_PRIVATE_DATA
 
struct  QEMU_VIDEO_CIRRUS_MODES
 
struct  QEMU_VIDEO_BOCHS_MODES
 

Macros

#define CIRRUS_LOGIC_VENDOR_ID   0x1013
 
#define CIRRUS_LOGIC_5430_DEVICE_ID   0x00a8
 
#define CIRRUS_LOGIC_5430_ALTERNATE_DEVICE_ID   0x00a0
 
#define CIRRUS_LOGIC_5446_DEVICE_ID   0x00b8
 
#define PIXEL_RED_SHIFT   0
 
#define PIXEL_GREEN_SHIFT   3
 
#define PIXEL_BLUE_SHIFT   6
 
#define PIXEL_RED_MASK   (BIT7 | BIT6 | BIT5)
 
#define PIXEL_GREEN_MASK   (BIT4 | BIT3 | BIT2)
 
#define PIXEL_BLUE_MASK   (BIT1 | BIT0)
 
#define PIXEL_TO_COLOR_BYTE(pixel, mask, shift)   ((UINT8) ((pixel & mask) << shift))
 
#define PIXEL_TO_RED_BYTE(pixel)   PIXEL_TO_COLOR_BYTE(pixel, PIXEL_RED_MASK, PIXEL_RED_SHIFT)
 
#define PIXEL_TO_GREEN_BYTE(pixel)   PIXEL_TO_COLOR_BYTE(pixel, PIXEL_GREEN_MASK, PIXEL_GREEN_SHIFT)
 
#define PIXEL_TO_BLUE_BYTE(pixel)   PIXEL_TO_COLOR_BYTE(pixel, PIXEL_BLUE_MASK, PIXEL_BLUE_SHIFT)
 
#define RGB_BYTES_TO_PIXEL(Red, Green, Blue)
 
#define PIXEL24_RED_MASK   0x00ff0000
 
#define PIXEL24_GREEN_MASK   0x0000ff00
 
#define PIXEL24_BLUE_MASK   0x000000ff
 
#define GRAPHICS_OUTPUT_INVALIDE_MODE_NUMBER   0xffff
 
#define QEMU_VIDEO_PRIVATE_DATA_SIGNATURE   SIGNATURE_32 ('Q', 'V', 'I', 'D')
 
#define QEMU_VIDEO_PRIVATE_DATA_FROM_GRAPHICS_OUTPUT_THIS(a)    CR(a, QEMU_VIDEO_PRIVATE_DATA, GraphicsOutput, QEMU_VIDEO_PRIVATE_DATA_SIGNATURE)
 
#define CRTC_ADDRESS_REGISTER   0x3d4
 
#define CRTC_DATA_REGISTER   0x3d5
 
#define SEQ_ADDRESS_REGISTER   0x3c4
 
#define SEQ_DATA_REGISTER   0x3c5
 
#define GRAPH_ADDRESS_REGISTER   0x3ce
 
#define GRAPH_DATA_REGISTER   0x3cf
 
#define ATT_ADDRESS_REGISTER   0x3c0
 
#define MISC_OUTPUT_REGISTER   0x3c2
 
#define INPUT_STATUS_1_REGISTER   0x3da
 
#define DAC_PIXEL_MASK_REGISTER   0x3c6
 
#define PALETTE_INDEX_REGISTER   0x3c8
 
#define PALETTE_DATA_REGISTER   0x3c9
 
#define VBE_DISPI_IOPORT_INDEX   0x01CE
 
#define VBE_DISPI_IOPORT_DATA   0x01D0
 
#define VBE_DISPI_INDEX_ID   0x0
 
#define VBE_DISPI_INDEX_XRES   0x1
 
#define VBE_DISPI_INDEX_YRES   0x2
 
#define VBE_DISPI_INDEX_BPP   0x3
 
#define VBE_DISPI_INDEX_ENABLE   0x4
 
#define VBE_DISPI_INDEX_BANK   0x5
 
#define VBE_DISPI_INDEX_VIRT_WIDTH   0x6
 
#define VBE_DISPI_INDEX_VIRT_HEIGHT   0x7
 
#define VBE_DISPI_INDEX_X_OFFSET   0x8
 
#define VBE_DISPI_INDEX_Y_OFFSET   0x9
 
#define VBE_DISPI_INDEX_VIDEO_MEMORY_64K   0xa
 
#define VBE_DISPI_ID0   0xB0C0
 
#define VBE_DISPI_ID1   0xB0C1
 
#define VBE_DISPI_ID2   0xB0C2
 
#define VBE_DISPI_ID3   0xB0C3
 
#define VBE_DISPI_ID4   0xB0C4
 
#define VBE_DISPI_ID5   0xB0C5
 
#define VBE_DISPI_DISABLED   0x00
 
#define VBE_DISPI_ENABLED   0x01
 
#define VBE_DISPI_GETCAPS   0x02
 
#define VBE_DISPI_8BIT_DAC   0x20
 
#define VBE_DISPI_LFB_ENABLED   0x40
 
#define VBE_DISPI_NOCLEARMEM   0x80
 

Enumerations

enum  QEMU_VIDEO_VARIANT {
  QEMU_VIDEO_CIRRUS_5430 = 1 , QEMU_VIDEO_CIRRUS_5446 , QEMU_VIDEO_BOCHS , QEMU_VIDEO_BOCHS_MMIO ,
  QEMU_VIDEO_VMWARE_SVGA
}
 

Functions

EFI_STATUS QemuVideoGraphicsOutputConstructor (QEMU_VIDEO_PRIVATE_DATA *Private)
 
EFI_STATUS QemuVideoGraphicsOutputDestructor (QEMU_VIDEO_PRIVATE_DATA *Private)
 
EFI_STATUS EFIAPI QemuVideoControllerDriverSupported (IN EFI_DRIVER_BINDING_PROTOCOL *This, IN EFI_HANDLE Controller, IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath)
 
EFI_STATUS EFIAPI QemuVideoControllerDriverStart (IN EFI_DRIVER_BINDING_PROTOCOL *This, IN EFI_HANDLE Controller, IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath)
 
EFI_STATUS EFIAPI QemuVideoControllerDriverStop (IN EFI_DRIVER_BINDING_PROTOCOL *This, IN EFI_HANDLE Controller, IN UINTN NumberOfChildren, IN EFI_HANDLE *ChildHandleBuffer)
 
EFI_STATUS EFIAPI QemuVideoComponentNameGetDriverName (IN EFI_COMPONENT_NAME_PROTOCOL *This, IN CHAR8 *Language, OUT CHAR16 **DriverName)
 
EFI_STATUS EFIAPI QemuVideoComponentNameGetControllerName (IN EFI_COMPONENT_NAME_PROTOCOL *This, IN EFI_HANDLE ControllerHandle, IN EFI_HANDLE ChildHandle OPTIONAL, IN CHAR8 *Language, OUT CHAR16 **ControllerName)
 
VOID InitializeCirrusGraphicsMode (QEMU_VIDEO_PRIVATE_DATA *Private, QEMU_VIDEO_CIRRUS_MODES *ModeData)
 
VOID InitializeBochsGraphicsMode (QEMU_VIDEO_PRIVATE_DATA *Private, QEMU_VIDEO_MODE_DATA *ModeData)
 
VOID SetPaletteColor (QEMU_VIDEO_PRIVATE_DATA *Private, UINTN Index, UINT8 Red, UINT8 Green, UINT8 Blue)
 
VOID SetDefaultPalette (QEMU_VIDEO_PRIVATE_DATA *Private)
 
VOID DrawLogo (QEMU_VIDEO_PRIVATE_DATA *Private, UINTN ScreenWidth, UINTN ScreenHeight)
 
VOID outb (QEMU_VIDEO_PRIVATE_DATA *Private, UINTN Address, UINT8 Data)
 
VOID outw (QEMU_VIDEO_PRIVATE_DATA *Private, UINTN Address, UINT16 Data)
 
UINT8 inb (QEMU_VIDEO_PRIVATE_DATA *Private, UINTN Address)
 
UINT16 inw (QEMU_VIDEO_PRIVATE_DATA *Private, UINTN Address)
 
VOID BochsWrite (QEMU_VIDEO_PRIVATE_DATA *Private, UINT16 Reg, UINT16 Data)
 
UINT16 BochsRead (QEMU_VIDEO_PRIVATE_DATA *Private, UINT16 Reg)
 
VOID VgaOutb (QEMU_VIDEO_PRIVATE_DATA *Private, UINTN Reg, UINT8 Data)
 
EFI_STATUS QemuVideoCirrusModeSetup (QEMU_VIDEO_PRIVATE_DATA *Private)
 
EFI_STATUS QemuVideoBochsModeSetup (QEMU_VIDEO_PRIVATE_DATA *Private, BOOLEAN IsQxl)
 

Variables

UINT8 AttributeController []
 
UINT8 GraphicsController []
 
UINT8 Crtc_640_480_256_60 []
 
UINT16 Seq_640_480_256_60 []
 
UINT8 Crtc_800_600_256_60 []
 
UINT16 Seq_800_600_256_60 []
 
UINT8 Crtc_1024_768_256_60 []
 
UINT16 Seq_1024_768_256_60 []
 
QEMU_VIDEO_CIRRUS_MODES QemuVideoCirrusModes []
 
EFI_DRIVER_BINDING_PROTOCOL gQemuVideoDriverBinding
 
EFI_COMPONENT_NAME_PROTOCOL gQemuVideoComponentName
 
EFI_COMPONENT_NAME2_PROTOCOL gQemuVideoComponentName2
 

Detailed Description

QEMU Video Controller Driver

Copyright (c) 2006 - 2019, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent

Definition in file Qemu.h.

Macro Definition Documentation

◆ ATT_ADDRESS_REGISTER

#define ATT_ADDRESS_REGISTER   0x3c0

Definition at line 167 of file Qemu.h.

◆ CIRRUS_LOGIC_5430_ALTERNATE_DEVICE_ID

#define CIRRUS_LOGIC_5430_ALTERNATE_DEVICE_ID   0x00a0

Definition at line 41 of file Qemu.h.

◆ CIRRUS_LOGIC_5430_DEVICE_ID

#define CIRRUS_LOGIC_5430_DEVICE_ID   0x00a8

Definition at line 40 of file Qemu.h.

◆ CIRRUS_LOGIC_5446_DEVICE_ID

#define CIRRUS_LOGIC_5446_DEVICE_ID   0x00b8

Definition at line 42 of file Qemu.h.

◆ CIRRUS_LOGIC_VENDOR_ID

#define CIRRUS_LOGIC_VENDOR_ID   0x1013

Definition at line 39 of file Qemu.h.

◆ CRTC_ADDRESS_REGISTER

#define CRTC_ADDRESS_REGISTER   0x3d4

Definition at line 161 of file Qemu.h.

◆ CRTC_DATA_REGISTER

#define CRTC_DATA_REGISTER   0x3d5

Definition at line 162 of file Qemu.h.

◆ DAC_PIXEL_MASK_REGISTER

#define DAC_PIXEL_MASK_REGISTER   0x3c6

Definition at line 170 of file Qemu.h.

◆ GRAPH_ADDRESS_REGISTER

#define GRAPH_ADDRESS_REGISTER   0x3ce

Definition at line 165 of file Qemu.h.

◆ GRAPH_DATA_REGISTER

#define GRAPH_DATA_REGISTER   0x3cf

Definition at line 166 of file Qemu.h.

◆ GRAPHICS_OUTPUT_INVALIDE_MODE_NUMBER

#define GRAPHICS_OUTPUT_INVALIDE_MODE_NUMBER   0xffff

Definition at line 76 of file Qemu.h.

◆ INPUT_STATUS_1_REGISTER

#define INPUT_STATUS_1_REGISTER   0x3da

Definition at line 169 of file Qemu.h.

◆ MISC_OUTPUT_REGISTER

#define MISC_OUTPUT_REGISTER   0x3c2

Definition at line 168 of file Qemu.h.

◆ PALETTE_DATA_REGISTER

#define PALETTE_DATA_REGISTER   0x3c9

Definition at line 172 of file Qemu.h.

◆ PALETTE_INDEX_REGISTER

#define PALETTE_INDEX_REGISTER   0x3c8

Definition at line 171 of file Qemu.h.

◆ PIXEL24_BLUE_MASK

#define PIXEL24_BLUE_MASK   0x000000ff

Definition at line 74 of file Qemu.h.

◆ PIXEL24_GREEN_MASK

#define PIXEL24_GREEN_MASK   0x0000ff00

Definition at line 73 of file Qemu.h.

◆ PIXEL24_RED_MASK

#define PIXEL24_RED_MASK   0x00ff0000

Definition at line 72 of file Qemu.h.

◆ PIXEL_BLUE_MASK

#define PIXEL_BLUE_MASK   (BIT1 | BIT0)

Definition at line 60 of file Qemu.h.

◆ PIXEL_BLUE_SHIFT

#define PIXEL_BLUE_SHIFT   6

Definition at line 56 of file Qemu.h.

◆ PIXEL_GREEN_MASK

#define PIXEL_GREEN_MASK   (BIT4 | BIT3 | BIT2)

Definition at line 59 of file Qemu.h.

◆ PIXEL_GREEN_SHIFT

#define PIXEL_GREEN_SHIFT   3

Definition at line 55 of file Qemu.h.

◆ PIXEL_RED_MASK

#define PIXEL_RED_MASK   (BIT7 | BIT6 | BIT5)

Definition at line 58 of file Qemu.h.

◆ PIXEL_RED_SHIFT

#define PIXEL_RED_SHIFT   0

Definition at line 54 of file Qemu.h.

◆ PIXEL_TO_BLUE_BYTE

#define PIXEL_TO_BLUE_BYTE (   pixel)    PIXEL_TO_COLOR_BYTE(pixel, PIXEL_BLUE_MASK, PIXEL_BLUE_SHIFT)

Definition at line 65 of file Qemu.h.

◆ PIXEL_TO_COLOR_BYTE

#define PIXEL_TO_COLOR_BYTE (   pixel,
  mask,
  shift 
)    ((UINT8) ((pixel & mask) << shift))

Definition at line 62 of file Qemu.h.

◆ PIXEL_TO_GREEN_BYTE

#define PIXEL_TO_GREEN_BYTE (   pixel)    PIXEL_TO_COLOR_BYTE(pixel, PIXEL_GREEN_MASK, PIXEL_GREEN_SHIFT)

Definition at line 64 of file Qemu.h.

◆ PIXEL_TO_RED_BYTE

#define PIXEL_TO_RED_BYTE (   pixel)    PIXEL_TO_COLOR_BYTE(pixel, PIXEL_RED_MASK, PIXEL_RED_SHIFT)

Definition at line 63 of file Qemu.h.

◆ QEMU_VIDEO_PRIVATE_DATA_FROM_GRAPHICS_OUTPUT_THIS

#define QEMU_VIDEO_PRIVATE_DATA_FROM_GRAPHICS_OUTPUT_THIS (   a)     CR(a, QEMU_VIDEO_PRIVATE_DATA, GraphicsOutput, QEMU_VIDEO_PRIVATE_DATA_SIGNATURE)

Definition at line 139 of file Qemu.h.

◆ QEMU_VIDEO_PRIVATE_DATA_SIGNATURE

#define QEMU_VIDEO_PRIVATE_DATA_SIGNATURE   SIGNATURE_32 ('Q', 'V', 'I', 'D')

Definition at line 81 of file Qemu.h.

◆ RGB_BYTES_TO_PIXEL

#define RGB_BYTES_TO_PIXEL (   Red,
  Green,
  Blue 
)
Value:
(UINT8) ( (((Red) >> PIXEL_RED_SHIFT) & PIXEL_RED_MASK) | \
(((Green) >> PIXEL_GREEN_SHIFT) & PIXEL_GREEN_MASK) | \
(((Blue) >> PIXEL_BLUE_SHIFT) & PIXEL_BLUE_MASK) )

Definition at line 67 of file Qemu.h.

◆ SEQ_ADDRESS_REGISTER

#define SEQ_ADDRESS_REGISTER   0x3c4

Definition at line 163 of file Qemu.h.

◆ SEQ_DATA_REGISTER

#define SEQ_DATA_REGISTER   0x3c5

Definition at line 164 of file Qemu.h.

◆ VBE_DISPI_8BIT_DAC

#define VBE_DISPI_8BIT_DAC   0x20

Definition at line 199 of file Qemu.h.

◆ VBE_DISPI_DISABLED

#define VBE_DISPI_DISABLED   0x00

Definition at line 196 of file Qemu.h.

◆ VBE_DISPI_ENABLED

#define VBE_DISPI_ENABLED   0x01

Definition at line 197 of file Qemu.h.

◆ VBE_DISPI_GETCAPS

#define VBE_DISPI_GETCAPS   0x02

Definition at line 198 of file Qemu.h.

◆ VBE_DISPI_ID0

#define VBE_DISPI_ID0   0xB0C0

Definition at line 189 of file Qemu.h.

◆ VBE_DISPI_ID1

#define VBE_DISPI_ID1   0xB0C1

Definition at line 190 of file Qemu.h.

◆ VBE_DISPI_ID2

#define VBE_DISPI_ID2   0xB0C2

Definition at line 191 of file Qemu.h.

◆ VBE_DISPI_ID3

#define VBE_DISPI_ID3   0xB0C3

Definition at line 192 of file Qemu.h.

◆ VBE_DISPI_ID4

#define VBE_DISPI_ID4   0xB0C4

Definition at line 193 of file Qemu.h.

◆ VBE_DISPI_ID5

#define VBE_DISPI_ID5   0xB0C5

Definition at line 194 of file Qemu.h.

◆ VBE_DISPI_INDEX_BANK

#define VBE_DISPI_INDEX_BANK   0x5

Definition at line 182 of file Qemu.h.

◆ VBE_DISPI_INDEX_BPP

#define VBE_DISPI_INDEX_BPP   0x3

Definition at line 180 of file Qemu.h.

◆ VBE_DISPI_INDEX_ENABLE

#define VBE_DISPI_INDEX_ENABLE   0x4

Definition at line 181 of file Qemu.h.

◆ VBE_DISPI_INDEX_ID

#define VBE_DISPI_INDEX_ID   0x0

Definition at line 177 of file Qemu.h.

◆ VBE_DISPI_INDEX_VIDEO_MEMORY_64K

#define VBE_DISPI_INDEX_VIDEO_MEMORY_64K   0xa

Definition at line 187 of file Qemu.h.

◆ VBE_DISPI_INDEX_VIRT_HEIGHT

#define VBE_DISPI_INDEX_VIRT_HEIGHT   0x7

Definition at line 184 of file Qemu.h.

◆ VBE_DISPI_INDEX_VIRT_WIDTH

#define VBE_DISPI_INDEX_VIRT_WIDTH   0x6

Definition at line 183 of file Qemu.h.

◆ VBE_DISPI_INDEX_X_OFFSET

#define VBE_DISPI_INDEX_X_OFFSET   0x8

Definition at line 185 of file Qemu.h.

◆ VBE_DISPI_INDEX_XRES

#define VBE_DISPI_INDEX_XRES   0x1

Definition at line 178 of file Qemu.h.

◆ VBE_DISPI_INDEX_Y_OFFSET

#define VBE_DISPI_INDEX_Y_OFFSET   0x9

Definition at line 186 of file Qemu.h.

◆ VBE_DISPI_INDEX_YRES

#define VBE_DISPI_INDEX_YRES   0x2

Definition at line 179 of file Qemu.h.

◆ VBE_DISPI_IOPORT_DATA

#define VBE_DISPI_IOPORT_DATA   0x01D0

Definition at line 175 of file Qemu.h.

◆ VBE_DISPI_IOPORT_INDEX

#define VBE_DISPI_IOPORT_INDEX   0x01CE

Definition at line 174 of file Qemu.h.

◆ VBE_DISPI_LFB_ENABLED

#define VBE_DISPI_LFB_ENABLED   0x40

Definition at line 200 of file Qemu.h.

◆ VBE_DISPI_NOCLEARMEM

#define VBE_DISPI_NOCLEARMEM   0x80

Definition at line 201 of file Qemu.h.

Enumeration Type Documentation

◆ QEMU_VIDEO_VARIANT

enum QEMU_VIDEO_VARIANT

Definition at line 83 of file Qemu.h.

Function Documentation

◆ BochsRead()

UINT16 BochsRead ( QEMU_VIDEO_PRIVATE_DATA Private,
UINT16  Reg 
)

Definition at line 928 of file Driver.c.

◆ BochsWrite()

VOID BochsWrite ( QEMU_VIDEO_PRIVATE_DATA Private,
UINT16  Reg,
UINT16  Data 
)

Definition at line 903 of file Driver.c.

◆ DrawLogo()

VOID DrawLogo ( QEMU_VIDEO_PRIVATE_DATA Private,
UINTN  ScreenWidth,
UINTN  ScreenHeight 
)

TODO: Add function description

Parameters
PrivateTODO: add argument description

TODO: add return values

Definition at line 832 of file Driver.c.

◆ inb()

UINT8 inb ( QEMU_VIDEO_PRIVATE_DATA Private,
UINTN  Address 
)

TODO: Add function description

Parameters
PrivateTODO: add argument description
AddressTODO: add argument description

TODO: add return values

Definition at line 695 of file Driver.c.

◆ InitializeBochsGraphicsMode()

VOID InitializeBochsGraphicsMode ( QEMU_VIDEO_PRIVATE_DATA Private,
QEMU_VIDEO_MODE_DATA ModeData 
)

Definition at line 1007 of file Driver.c.

◆ InitializeCirrusGraphicsMode()

VOID InitializeCirrusGraphicsMode ( QEMU_VIDEO_PRIVATE_DATA Private,
QEMU_VIDEO_CIRRUS_MODES ModeData 
)

TODO: Add function description

Parameters
PrivateTODO: add argument description
ModeDataTODO: add argument description

TODO: add return values

Definition at line 850 of file Driver.c.

◆ inw()

UINT16 inw ( QEMU_VIDEO_PRIVATE_DATA Private,
UINTN  Address 
)

TODO: Add function description

Parameters
PrivateTODO: add argument description
AddressTODO: add argument description

TODO: add return values

Definition at line 723 of file Driver.c.

◆ outb()

VOID outb ( QEMU_VIDEO_PRIVATE_DATA Private,
UINTN  Address,
UINT8  Data 
)

TODO: Add function description

Parameters
PrivateTODO: add argument description
AddressTODO: add argument description
DataTODO: add argument description

TODO: add return values

Definition at line 642 of file Driver.c.

◆ outw()

VOID outw ( QEMU_VIDEO_PRIVATE_DATA Private,
UINTN  Address,
UINT16  Data 
)

TODO: Add function description

Parameters
PrivateTODO: add argument description
AddressTODO: add argument description
DataTODO: add argument description

TODO: add return values

Definition at line 669 of file Driver.c.

◆ QemuVideoBochsModeSetup()

EFI_STATUS QemuVideoBochsModeSetup ( QEMU_VIDEO_PRIVATE_DATA Private,
BOOLEAN  IsQxl 
)

Definition at line 380 of file Initialize.c.

◆ QemuVideoCirrusModeSetup()

EFI_STATUS QemuVideoCirrusModeSetup ( QEMU_VIDEO_PRIVATE_DATA Private)

Construct the valid video modes for QemuVideo.

Definition at line 158 of file Initialize.c.

◆ QemuVideoComponentNameGetControllerName()

EFI_STATUS EFIAPI QemuVideoComponentNameGetControllerName ( IN EFI_COMPONENT_NAME_PROTOCOL This,
IN EFI_HANDLE  ControllerHandle,
IN EFI_HANDLE ChildHandle  OPTIONAL,
IN CHAR8 *  Language,
OUT CHAR16 **  ControllerName 
)

Retrieves a Unicode string that is the user readable name of the controller that is being managed by a driver.

This function retrieves the user readable name of the controller specified by ControllerHandle and ChildHandle in the form of a Unicode string. If the driver specified by This has a user readable name in the language specified by Language, then a pointer to the controller name is returned in ControllerName, and EFI_SUCCESS is returned. If the driver specified by This is not currently managing the controller specified by ControllerHandle and ChildHandle, then EFI_UNSUPPORTED is returned. If the driver specified by This does not support the language specified by Language, then EFI_UNSUPPORTED is returned.

Parameters
This[in]A pointer to the EFI_COMPONENT_NAME2_PROTOCOL or EFI_COMPONENT_NAME_PROTOCOL instance.
ControllerHandle[in]The handle of a controller that the driver specified by This is managing. This handle specifies the controller whose name is to be returned.
ChildHandle[in]The handle of the child controller to retrieve the name of. This is an optional parameter that may be NULL. It will be NULL for device drivers. It will also be NULL for a bus drivers that wish to retrieve the name of the bus controller. It will not be NULL for a bus driver that wishes to retrieve the name of a child controller.
Language[in]A pointer to a Null-terminated ASCII string array indicating the language. This is the language of the driver name that the caller is requesting, and it must match one of the languages specified in SupportedLanguages. The number of languages supported by a driver is up to the driver writer. Language is specified in RFC 4646 or ISO 639-2 language code format.
ControllerName[out]A pointer to the Unicode string to return. This Unicode string is the name of the controller specified by ControllerHandle and ChildHandle in the language specified by Language from the point of view of the driver specified by This.
Return values
EFI_SUCCESSThe Unicode string for the user readable name in the language specified by Language for the driver specified by This was returned in DriverName.
EFI_INVALID_PARAMETERControllerHandle is not a valid EFI_HANDLE.
EFI_INVALID_PARAMETERChildHandle is not NULL and it is not a valid EFI_HANDLE.
EFI_INVALID_PARAMETERLanguage is NULL.
EFI_INVALID_PARAMETERControllerName is NULL.
EFI_UNSUPPORTEDThe driver specified by This is not currently managing the controller specified by ControllerHandle and ChildHandle.
EFI_UNSUPPORTEDThe driver specified by This does not support the language specified by Language.

Definition at line 166 of file ComponentName.c.

◆ QemuVideoComponentNameGetDriverName()

EFI_STATUS EFIAPI QemuVideoComponentNameGetDriverName ( IN EFI_COMPONENT_NAME_PROTOCOL This,
IN CHAR8 *  Language,
OUT CHAR16 **  DriverName 
)

Retrieves a Unicode string that is the user readable name of the driver.

This function retrieves the user readable name of a driver in the form of a Unicode string. If the driver specified by This has a user readable name in the language specified by Language, then a pointer to the driver name is returned in DriverName, and EFI_SUCCESS is returned. If the driver specified by This does not support the language specified by Language, then EFI_UNSUPPORTED is returned.

Parameters
This[in]A pointer to the EFI_COMPONENT_NAME2_PROTOCOL or EFI_COMPONENT_NAME_PROTOCOL instance.
Language[in]A pointer to a Null-terminated ASCII string array indicating the language. This is the language of the driver name that the caller is requesting, and it must match one of the languages specified in SupportedLanguages. The number of languages supported by a driver is up to the driver writer. Language is specified in RFC 4646 or ISO 639-2 language code format.
DriverName[out]A pointer to the Unicode string to return. This Unicode string is the name of the driver specified by This in the language specified by Language.
Return values
EFI_SUCCESSThe Unicode string for the Driver specified by This and the language specified by Language was returned in DriverName.
EFI_INVALID_PARAMETERLanguage is NULL.
EFI_INVALID_PARAMETERDriverName is NULL.
EFI_UNSUPPORTEDThe driver specified by This does not support the language specified by Language.

Definition at line 81 of file ComponentName.c.

◆ QemuVideoControllerDriverStart()

EFI_STATUS EFIAPI QemuVideoControllerDriverStart ( IN EFI_DRIVER_BINDING_PROTOCOL This,
IN EFI_HANDLE  Controller,
IN EFI_DEVICE_PATH_PROTOCOL RemainingDevicePath 
)

TODO: Add function description

Parameters
ThisTODO: add argument description
ControllerTODO: add argument description
RemainingDevicePathTODO: add argument description

TODO: add return values

Start to process the controller.

Parameters
ThisThe USB bus driver binding instance.
ControllerThe controller to check.
RemainingDevicePathThe remaining device patch.
Return values
EFI_SUCCESSThe controller is controlled by the usb bus.
EFI_ALREADY_STARTEDThe controller is already controlled by the usb bus.
EFI_OUT_OF_RESOURCESFailed to allocate resources.

Definition at line 193 of file Driver.c.

◆ QemuVideoControllerDriverStop()

EFI_STATUS EFIAPI QemuVideoControllerDriverStop ( IN EFI_DRIVER_BINDING_PROTOCOL This,
IN EFI_HANDLE  Controller,
IN UINTN  NumberOfChildren,
IN EFI_HANDLE ChildHandleBuffer 
)

TODO: Add function description

Parameters
ThisTODO: add argument description
ControllerTODO: add argument description
NumberOfChildrenTODO: add argument description
ChildHandleBufferTODO: add argument description

TODO: add return values

Stop this device

Parameters
ThisThe USB bus driver binding protocol.
ControllerThe controller to release.
NumberOfChildrenThe number of children of this device that opened the controller BY_CHILD.
ChildHandleBufferThe array of child handle.
Return values
EFI_SUCCESSThe controller or children are stopped.
EFI_DEVICE_ERRORFailed to stop the driver.

Definition at line 535 of file Driver.c.

◆ QemuVideoControllerDriverSupported()

EFI_STATUS EFIAPI QemuVideoControllerDriverSupported ( IN EFI_DRIVER_BINDING_PROTOCOL This,
IN EFI_HANDLE  Controller,
IN EFI_DEVICE_PATH_PROTOCOL RemainingDevicePath 
)

TODO: Add function description

Parameters
ThisTODO: add argument description
ControllerTODO: add argument description
RemainingDevicePathTODO: add argument description

TODO: add return values

Check if this device is supported.

Parameters
ThisThe driver binding protocol.
ControllerThe controller handle to check.
RemainingDevicePathThe remaining device path.
Return values
EFI_SUCCESSThe bus supports this controller.
EFI_UNSUPPORTEDThis device isn't supported.

Definition at line 113 of file Driver.c.

◆ QemuVideoGraphicsOutputConstructor()

EFI_STATUS QemuVideoGraphicsOutputConstructor ( QEMU_VIDEO_PRIVATE_DATA Private)

Definition at line 361 of file Gop.c.

◆ QemuVideoGraphicsOutputDestructor()

EFI_STATUS QemuVideoGraphicsOutputDestructor ( QEMU_VIDEO_PRIVATE_DATA Private)

Definition at line 426 of file Gop.c.

◆ SetDefaultPalette()

VOID SetDefaultPalette ( QEMU_VIDEO_PRIVATE_DATA Private)

TODO: Add function description

Parameters
PrivateTODO: add argument description

TODO: add return values

Definition at line 777 of file Driver.c.

◆ SetPaletteColor()

VOID SetPaletteColor ( QEMU_VIDEO_PRIVATE_DATA Private,
UINTN  Index,
UINT8  Red,
UINT8  Green,
UINT8  Blue 
)

TODO: Add function description

Parameters
PrivateTODO: add argument description
IndexTODO: add argument description
RedTODO: add argument description
GreenTODO: add argument description
BlueTODO: add argument description

TODO: add return values

Definition at line 754 of file Driver.c.

◆ VgaOutb()

VOID VgaOutb ( QEMU_VIDEO_PRIVATE_DATA Private,
UINTN  Reg,
UINT8  Data 
)

Definition at line 955 of file Driver.c.

Variable Documentation

◆ AttributeController

UINT8 AttributeController[]
extern

Generic Attribute Controller Register Settings

Definition at line 15 of file Initialize.c.

◆ Crtc_1024_768_256_60

UINT8 Crtc_1024_768_256_60[]
extern

Definition at line 97 of file Initialize.c.

◆ Crtc_640_480_256_60

UINT8 Crtc_640_480_256_60[]
extern

Definition at line 31 of file Initialize.c.

◆ Crtc_800_600_256_60

UINT8 Crtc_800_600_256_60[]
extern

Definition at line 58 of file Initialize.c.

◆ gQemuVideoComponentName

EFI_COMPONENT_NAME_PROTOCOL gQemuVideoComponentName
extern

Definition at line 15 of file ComponentName.c.

◆ gQemuVideoComponentName2

EFI_COMPONENT_NAME2_PROTOCOL gQemuVideoComponentName2
extern

Definition at line 24 of file ComponentName.c.

◆ gQemuVideoDriverBinding

EFI_DRIVER_BINDING_PROTOCOL gQemuVideoDriverBinding
extern

Definition at line 14 of file Driver.c.

◆ GraphicsController

UINT8 GraphicsController[]
extern

Generic Graphics Controller Register Settings

Definition at line 24 of file Initialize.c.

◆ QemuVideoCirrusModes

QEMU_VIDEO_CIRRUS_MODES QemuVideoCirrusModes[]
extern

Table of supported video modes

Definition at line 139 of file Initialize.c.

◆ Seq_1024_768_256_60

UINT16 Seq_1024_768_256_60[]
extern

Definition at line 104 of file Initialize.c.

◆ Seq_640_480_256_60

UINT16 Seq_640_480_256_60[]
extern

Definition at line 45 of file Initialize.c.

◆ Seq_800_600_256_60

UINT16 Seq_800_600_256_60[]
extern

Definition at line 72 of file Initialize.c.