EDK2 doxygen online documents - Firmware Encoding Index 1
EDK2 doxygen online documents - Firmware Encoding Index

MdePkg/Include/Protocol/UgaIo.h

Go to the documentation of this file.
00001 
00017 #ifndef __UGA_IO_H__
00018 #define __UGA_IO_H__
00019 
00020 #define EFI_UGA_IO_PROTOCOL_GUID \
00021   { 0x61a4d49e, 0x6f68, 0x4f1b, { 0xb9, 0x22, 0xa8, 0x6e, 0xed, 0xb, 0x7, 0xa2 } }
00022 
00023 typedef struct _EFI_UGA_IO_PROTOCOL EFI_UGA_IO_PROTOCOL;
00024 
00025 typedef UINT32                      UGA_STATUS;
00026 
00027 typedef enum {
00028   UgaDtParentBus          = 1,
00029   UgaDtGraphicsController,
00030   UgaDtOutputController,
00031   UgaDtOutputPort,
00032   UgaDtOther
00033 } UGA_DEVICE_TYPE, *PUGA_DEVICE_TYPE;
00034 
00035 typedef UINT32 UGA_DEVICE_ID, *PUGA_DEVICE_ID;
00036 
00037 typedef struct {
00038   UGA_DEVICE_TYPE deviceType;
00039   UGA_DEVICE_ID   deviceId;
00040   UINT32          ui32DeviceContextSize;
00041   UINT32          ui32SharedContextSize;
00042 } UGA_DEVICE_DATA, *PUGA_DEVICE_DATA;
00043 
00044 typedef struct _UGA_DEVICE {
00045   VOID                *pvDeviceContext;
00046   VOID                *pvSharedContext;
00047   VOID                *pvRunTimeContext;
00048   struct _UGA_DEVICE  *pParentDevice;
00049   VOID                *pvBusIoServices;
00050   VOID                *pvStdIoServices;
00051   UGA_DEVICE_DATA     deviceData;
00052 } UGA_DEVICE, *PUGA_DEVICE;
00053 
00054 typedef enum {
00055   UgaIoGetVersion             = 1,
00056   UgaIoGetChildDevice,
00057   UgaIoStartDevice,
00058   UgaIoStopDevice,
00059   UgaIoFlushDevice,
00060   UgaIoResetDevice,
00061   UgaIoGetDeviceState,
00062   UgaIoSetDeviceState,
00063   UgaIoSetPowerState,
00064   UgaIoGetMemoryConfiguration,
00065   UgaIoSetVideoMode,
00066   UgaIoCopyRectangle,
00067   UgaIoGetEdidSegment,
00068   UgaIoDeviceChannelOpen,
00069   UgaIoDeviceChannelClose,
00070   UgaIoDeviceChannelRead,
00071   UgaIoDeviceChannelWrite,
00072   UgaIoGetPersistentDataSize,
00073   UgaIoGetPersistentData,
00074   UgaIoSetPersistentData,
00075   UgaIoGetDevicePropertySize,
00076   UgaIoGetDeviceProperty,
00077   UgaIoBtPrivateInterface
00078 } UGA_IO_REQUEST_CODE, *PUGA_IO_REQUEST_CODE;
00079 
00080 typedef struct {
00081   IN UGA_IO_REQUEST_CODE  ioRequestCode;
00082   IN VOID                 *pvInBuffer;
00083   IN UINT64               ui64InBufferSize;
00084   OUT VOID                *pvOutBuffer;
00085   IN UINT64               ui64OutBufferSize;
00086   OUT UINT64              ui64BytesReturned;
00087 } UGA_IO_REQUEST, *PUGA_IO_REQUEST;
00088 
00089 
00107 typedef
00108 EFI_STATUS
00109 (EFIAPI *EFI_UGA_IO_PROTOCOL_CREATE_DEVICE)(
00110   IN  EFI_UGA_IO_PROTOCOL  *This,
00111   IN  UGA_DEVICE           *ParentDevice,
00112   IN  UGA_DEVICE_DATA      *DeviceData,
00113   IN  VOID                 *RunTimeContext,
00114   OUT UGA_DEVICE           **Device
00115   );
00116 
00117 
00131 typedef
00132 EFI_STATUS
00133 (EFIAPI *EFI_UGA_IO_PROTOCOL_DELETE_DEVICE)(
00134   IN EFI_UGA_IO_PROTOCOL  * This,
00135   IN UGA_DEVICE           * Device
00136   );
00137 
00155 typedef UGA_STATUS 
00156 (EFIAPI *PUGA_FW_SERVICE_DISPATCH)(
00157   IN PUGA_DEVICE pDevice, 
00158   IN OUT PUGA_IO_REQUEST pIoRequest
00159   );
00160 
00164 struct _EFI_UGA_IO_PROTOCOL {
00165   EFI_UGA_IO_PROTOCOL_CREATE_DEVICE CreateDevice;
00166   EFI_UGA_IO_PROTOCOL_DELETE_DEVICE DeleteDevice;
00167   PUGA_FW_SERVICE_DISPATCH          DispatchService;
00168 };
00169 
00170 extern EFI_GUID gEfiUgaIoProtocolGuid;
00171 
00172 //
00173 // Data structure that is stored in the EFI Configuration Table with the
00174 // EFI_UGA_IO_PROTOCOL_GUID.  The option ROMs listed in this table may have
00175 // EBC UGA drivers.
00176 //
00177 typedef struct {
00178   UINT32  Version;
00179   UINT32  HeaderSize;
00180   UINT32  SizeOfEntries;
00181   UINT32  NumberOfEntries;
00182 } EFI_DRIVER_OS_HANDOFF_HEADER;
00183 
00184 typedef enum {
00185   EfiUgaDriverFromPciRom,
00186   EfiUgaDriverFromSystem,
00187   EfiDriverHandoffMax
00188 } EFI_DRIVER_HANOFF_ENUM;
00189 
00190 typedef struct {
00191   EFI_DRIVER_HANOFF_ENUM    Type;
00192   EFI_DEVICE_PATH_PROTOCOL  *DevicePath;
00193   VOID                      *PciRomImage;
00194   UINT64                    PciRomSize;
00195 } EFI_DRIVER_OS_HANDOFF;
00196 
00197 #endif
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Defines