]>
Commit | Line | Data |
---|---|---|
3eb9473e | 1 | /*++\r |
f57387d5 HT |
2 | Copyright (c) 2006, Intel Corporation. All rights reserved.<BR>\r |
3 | This program and the accompanying materials \r | |
3eb9473e | 4 | are licensed and made available under the terms and conditions of the BSD License \r |
5 | which accompanies this distribution. The full text of the license may be found at \r | |
6 | http://opensource.org/licenses/bsd-license.php \r | |
7 | \r | |
8 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r | |
9 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r | |
10 | \r | |
11 | Module Name:\r | |
12 | \r | |
13 | IScsiInitatorName.h\r | |
14 | \r | |
15 | Abstract: \r | |
16 | EFI_ISCSI_INITIATOR_NAME_PROTOCOL as defined in UEFI 2.0.\r | |
17 | It rovides the ability to get and set the iSCSI Initiator Name. \r | |
18 | \r | |
19 | Revision History\r | |
20 | \r | |
21 | --*/\r | |
22 | \r | |
23 | #ifndef __ISCSI_INITIATOR_NAME_H__\r | |
24 | #define __ISCSI_INITIATOR_NAME_H__\r | |
25 | \r | |
26 | #define EFI_ISCSI_INITIATOR_NAME_PROTOCOL_GUID \\r | |
27 | { \\r | |
28 | 0x59324945, 0xec44, 0x4c0d, {0xb1, 0xcd, 0x9d, 0xb1, 0x39, 0xdf, 0x7, 0xc } \\r | |
29 | }\r | |
30 | \r | |
31 | typedef struct _EFI_ISCSI_INITIATOR_NAME_PROTOCOL EFI_ISCSI_INITIATOR_NAME_PROTOCOL;\r | |
32 | \r | |
33 | typedef \r | |
34 | EFI_STATUS\r | |
35 | (EFIAPI *EFI_ISCSI_INITIATOR_NAME_GET) (\r | |
36 | IN EFI_ISCSI_INITIATOR_NAME_PROTOCOL *This,\r | |
37 | IN OUT UINTN *BufferSize,\r | |
38 | OUT VOID *Buffer\r | |
39 | )\r | |
40 | /*++\r | |
41 | \r | |
42 | Routine Description:\r | |
43 | Retrieves the current set value of iSCSI Initiator Name.\r | |
44 | \r | |
45 | Arguments:\r | |
46 | This - Pointer to the EFI_ISCSI_INITIATOR_NAME_PROTOCOL instance.\r | |
47 | BufferSize - Size of the buffer in bytes pointed to by Buffer / Actual size of the\r | |
48 | variable data buffer.\r | |
49 | Buffer - Pointer to the buffer for data to be read.\r | |
50 | \r | |
51 | Returns:\r | |
52 | EFI_SUCCESS - Data was successfully retrieved into the provided buffer and the\r | |
53 | BufferSize was sufficient to handle the iSCSI initiator name\r | |
54 | EFI_BUFFER_TOO_SMALL - BufferSize is too small for the result.\r | |
55 | EFI_INVALID_PARAMETER - BufferSize or Buffer is NULL.\r | |
56 | EFI_DEVICE_ERROR - The iSCSI initiator name could not be retrieved due to a hardware error.\r | |
57 | \r | |
58 | --*/\r | |
59 | ;\r | |
60 | \r | |
61 | \r | |
62 | \r | |
63 | typedef EFI_STATUS\r | |
64 | (EFIAPI *EFI_ISCSI_INITIATOR_NAME_SET) (\r | |
65 | IN EFI_ISCSI_INITIATOR_NAME_PROTOCOL *This,\r | |
66 | IN OUT UINTN *BufferSize,\r | |
67 | IN VOID *Buffer\r | |
68 | )\r | |
69 | /*++\r | |
70 | \r | |
71 | Routine Description:\r | |
72 | Sets the iSCSI Initiator Name.\r | |
73 | \r | |
74 | Arguments:\r | |
75 | This - Pointer to the EFI_ISCSI_INITIATOR_NAME_PROTOCOL instance.\r | |
76 | BufferSize - Size of the buffer in bytes pointed to by Buffer.\r | |
77 | Buffer - Pointer to the buffer for data to be written.\r | |
78 | \r | |
79 | Returns:\r | |
80 | EFI_SUCCESS - Data was successfully stored by the protocol.\r | |
81 | EFI_UNSUPPORTED - Platform policies do not allow for data to be written.\r | |
82 | EFI_INVALID_PARAMETER - BufferSize or Buffer is NULL, or BufferSize exceeds the maximum allowed limit.\r | |
83 | EFI_DEVICE_ERROR - The data could not be stored due to a hardware error.\r | |
84 | EFI_OUT_OF_RESOURCES - Not enough storage is available to hold the data.\r | |
85 | EFI_PROTOCOL_ERROR - Input iSCSI initiator name does not adhere to RFC 3720\r | |
86 | (and other related protocols)\r | |
87 | \r | |
88 | --*/\r | |
89 | ; \r | |
90 | \r | |
91 | struct _EFI_ISCSI_INITIATOR_NAME_PROTOCOL {\r | |
92 | EFI_ISCSI_INITIATOR_NAME_GET Get;\r | |
93 | EFI_ISCSI_INITIATOR_NAME_SET Set;\r | |
94 | };\r | |
95 | \r | |
96 | extern EFI_GUID gEfiIScsiInitiatorNameProtocolGuid;\r | |
97 | \r | |
98 | #endif\r |