\r
Abstraction of a very simple graphics device.\r
\r
- Copyright (c) 2006 - 2007, Intel Corporation\r
+ Copyright (c) 2006 - 2008, Intel Corporation \r
All rights reserved. This program and the accompanying materials \r
are licensed and made available under the terms and conditions of the BSD License \r
which accompanies this distribution. The full text of the license may be found at \r
UgaDtOutputController,\r
UgaDtOutputPort,\r
UgaDtOther\r
-}\r
-UGA_DEVICE_TYPE, *PUGA_DEVICE_TYPE;\r
+} UGA_DEVICE_TYPE, *PUGA_DEVICE_TYPE;\r
\r
typedef UINT32 UGA_DEVICE_ID, *PUGA_DEVICE_ID;\r
\r
UGA_DEVICE_ID deviceId;\r
UINT32 ui32DeviceContextSize;\r
UINT32 ui32SharedContextSize;\r
-}\r
-UGA_DEVICE_DATA, *PUGA_DEVICE_DATA;\r
+} UGA_DEVICE_DATA, *PUGA_DEVICE_DATA;\r
\r
typedef struct _UGA_DEVICE {\r
VOID *pvDeviceContext;\r
VOID *pvBusIoServices;\r
VOID *pvStdIoServices;\r
UGA_DEVICE_DATA deviceData;\r
-}\r
-UGA_DEVICE, *PUGA_DEVICE;\r
+} UGA_DEVICE, *PUGA_DEVICE;\r
\r
-#ifndef UGA_IO_REQUEST_CODE\r
-//\r
-// Prevent conflicts with UGA typedefs.\r
-//\r
typedef enum {\r
UgaIoGetVersion = 1,\r
UgaIoGetChildDevice,\r
UgaIoGetDevicePropertySize,\r
UgaIoGetDeviceProperty,\r
UgaIoBtPrivateInterface\r
-}\r
-UGA_IO_REQUEST_CODE, *PUGA_IO_REQUEST_CODE;\r
-\r
-#endif\r
+} UGA_IO_REQUEST_CODE, *PUGA_IO_REQUEST_CODE;\r
\r
typedef struct {\r
IN UGA_IO_REQUEST_CODE ioRequestCode;\r
} UGA_IO_REQUEST, *PUGA_IO_REQUEST;\r
\r
\r
-/**
- Dynamically allocate storage for a child UGA_DEVICE .\r
-
- @param[in] This The EFI_UGA_IO_PROTOCOL instance. Type EFI_UGA_IO_PROTOCOL is \r
- defined in Section 10.7.
- @param[in] ParentDevice ParentDevice specifies a pointer to the parent device of Device.
+/**\r
+ Dynamically allocate storage for a child UGA_DEVICE.\r
+\r
+ @param[in] This The EFI_UGA_IO_PROTOCOL instance. \r
+ @param[in] ParentDevice ParentDevice specifies a pointer to the parent device of Device.\r
@param[in] DeviceData A pointer to UGA_DEVICE_DATA returned from a call to DispatchService()\r
- with a UGA_DEVICE of Parent and an IoRequest of type UgaIoGetChildDevice.
- @param[in] RunTimeContext Context to associate with Device.
+ with a UGA_DEVICE of Parent and an IoRequest of type UgaIoGetChildDevice. \r
+ @param[in] RunTimeContext Context to associate with Device. \r
@param[out] Device The Device returns a dynamically allocated child UGA_DEVICE object\r
- for ParentDevice. The caller is responsible for deleting Device.
-
+ for ParentDevice. The caller is responsible for deleting Device.\r
+\r
\r
@retval EFI_SUCCESS Device was returned.\r
@retval EFI_INVALID_PARAMETER One of the arguments was not valid.\r
**/\r
typedef\r
EFI_STATUS\r
-(EFIAPI *EFI_UGA_IO_PROTOCOL_CREATE_DEVICE) (\r
+(EFIAPI *EFI_UGA_IO_PROTOCOL_CREATE_DEVICE)(\r
IN EFI_UGA_IO_PROTOCOL *This,\r
IN UGA_DEVICE *ParentDevice,\r
IN UGA_DEVICE_DATA *DeviceData,\r
);\r
\r
\r
-/**
- Delete a dynamically allocated child UGA_DEVICE object that was allocated via CreateDevice() .\r
-
+/**\r
+ Delete a dynamically allocated child UGA_DEVICE object that was allocated via CreateDevice().\r
+\r
@param[in] This The EFI_UGA_IO_PROTOCOL instance. Type EFI_UGA_IO_PROTOCOL is \r
- defined in Section 10.7.
+ defined in Section 10.7.\r
@param[in] Device The Device points to a UGA_DEVICE object that was dynamically\r
allocated via a CreateDevice() call.\r
-
+\r
\r
@retval EFI_SUCCESS Device was returned.\r
@retval EFI_INVALID_PARAMETER The Device was not allocated via CreateDevice().\r
**/\r
typedef\r
EFI_STATUS\r
-(EFIAPI *EFI_UGA_IO_PROTOCOL_DELETE_DEVICE) (\r
+(EFIAPI *EFI_UGA_IO_PROTOCOL_DELETE_DEVICE)(\r
IN EFI_UGA_IO_PROTOCOL * This,\r
IN UGA_DEVICE * Device\r
);\r
\r
-\r
-typedef UGA_STATUS (EFIAPI *PUGA_FW_SERVICE_DISPATCH) (IN PUGA_DEVICE pDevice, IN OUT PUGA_IO_REQUEST pIoRequest);\r
-\r
/**\r
+ This is the main UGA service dispatch routine for all UGA_IO_REQUEST s.\r
\r
- Routine Description:\r
-\r
- This is the main UGA service dispatch routine for all UGA_IO_REQUEST s.\r
-\r
- Arguments:\r
-\r
- pDevice - pDevice specifies a pointer to a device object associated with a \r
+ @param pDevice pDevice specifies a pointer to a device object associated with a \r
device enumerated by a pIoRequest->ioRequestCode of type \r
UgaIoGetChildDevice. The root device for the EFI_UGA_IO_PROTOCOL \r
is represented by pDevice being set to NULL.\r
\r
- pIoRequest - pIoRequest points to a caller allocated buffer that contains data\r
+ @param pIoRequest \r
+ pIoRequest points to a caller allocated buffer that contains data\r
defined by pIoRequest->ioRequestCode. See Related Definitions for\r
a definition of UGA_IO_REQUEST_CODE s and their associated data \r
structures.\r
\r
- Returns:\r
-\r
- Varies depending on pIoRequest.\r
+ @return UGA_STATUS\r
\r
**/\r
+typedef UGA_STATUS \r
+(EFIAPI *PUGA_FW_SERVICE_DISPATCH)(\r
+ IN PUGA_DEVICE pDevice, \r
+ IN OUT PUGA_IO_REQUEST pIoRequest\r
+ );\r
+\r
+///\r
+/// Provides a basic abstraction to send I/O requests to the graphics device and any of its children.\r
+///\r
struct _EFI_UGA_IO_PROTOCOL {\r
EFI_UGA_IO_PROTOCOL_CREATE_DEVICE CreateDevice;\r
EFI_UGA_IO_PROTOCOL_DELETE_DEVICE DeleteDevice;\r