]>
Commit | Line | Data |
---|---|---|
1e57a462 | 1 | /** @file\r |
2 | \r | |
3 | Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>\r | |
4 | \r | |
5 | This program and the accompanying materials\r | |
6 | are licensed and made available under the terms and conditions of the BSD License\r | |
7 | which accompanies this distribution. The full text of the license may be found at\r | |
8 | http://opensource.org/licenses/bsd-license.php\r | |
9 | \r | |
10 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r | |
11 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r | |
12 | \r | |
13 | **/\r | |
14 | \r | |
15 | #ifndef __EMBEDDED_EXTERNAL_DEVICE_H__\r | |
16 | #define __EMBEDDED_EXTERNAL_DEVICE_H__\r | |
17 | \r | |
18 | //\r | |
19 | // Protocol GUID\r | |
20 | //\r | |
21 | #define EMBEDDED_EXTERNAL_DEVICE_PROTOCOL_GUID { 0x735F8C64, 0xD696, 0x44D0, { 0xBD, 0xF2, 0x44, 0x7F, 0xD0, 0x5A, 0x54, 0x06 }}\r | |
22 | \r | |
23 | //\r | |
24 | // Protocol interface structure\r | |
25 | //\r | |
26 | typedef struct _EMBEDDED_EXTERNAL_DEVICE EMBEDDED_EXTERNAL_DEVICE;\r | |
27 | \r | |
28 | //\r | |
29 | // Function Prototypes\r | |
30 | //\r | |
31 | typedef\r | |
32 | EFI_STATUS\r | |
33 | (EFIAPI *EMBEDDED_EXTERNAL_DEVICE_READ) (\r | |
34 | IN EMBEDDED_EXTERNAL_DEVICE *This,\r | |
35 | IN UINTN Register,\r | |
36 | IN UINTN Length,\r | |
37 | OUT VOID *Buffer\r | |
38 | )\r | |
39 | /*++\r | |
40 | \r | |
41 | Routine Description:\r | |
42 | \r | |
43 | Read a set of contiguous external device registers.\r | |
44 | \r | |
45 | Arguments:\r | |
46 | \r | |
47 | This - pointer to protocol\r | |
48 | Offset - starting register number\r | |
49 | Length - number of bytes to read\r | |
50 | Buffer - destination buffer\r | |
3402aac7 | 51 | \r |
1e57a462 | 52 | Returns:\r |
53 | \r | |
54 | EFI_SUCCESS - registers read successfully\r | |
55 | \r | |
56 | --*/\r | |
57 | ;\r | |
58 | \r | |
59 | typedef\r | |
60 | EFI_STATUS\r | |
61 | (EFIAPI *EMBEDDED_EXTERNAL_DEVICE_WRITE) (\r | |
62 | IN EMBEDDED_EXTERNAL_DEVICE *This,\r | |
63 | IN UINTN Register,\r | |
64 | IN UINTN Length,\r | |
65 | IN VOID *Buffer\r | |
66 | )\r | |
67 | /*++\r | |
68 | \r | |
69 | Routine Description:\r | |
70 | \r | |
71 | Write to a set of contiguous external device registers.\r | |
72 | \r | |
73 | Arguments:\r | |
74 | \r | |
75 | This - pointer to protocol\r | |
76 | Offset - starting register number\r | |
77 | Length - number of bytes to write\r | |
78 | Buffer - source buffer\r | |
3402aac7 | 79 | \r |
1e57a462 | 80 | Returns:\r |
81 | \r | |
82 | EFI_SUCCESS - registers written successfully\r | |
83 | \r | |
84 | --*/\r | |
85 | ;\r | |
86 | \r | |
87 | struct _EMBEDDED_EXTERNAL_DEVICE {\r | |
88 | EMBEDDED_EXTERNAL_DEVICE_READ Read;\r | |
89 | EMBEDDED_EXTERNAL_DEVICE_WRITE Write;\r | |
90 | };\r | |
91 | \r | |
92 | extern EFI_GUID gEmbeddedExternalDeviceProtocolGuid;\r | |
93 | \r | |
91c38d4e | 94 | #endif // __EMBEDDED_EXTERNAL_DEVICE_H__\r |