]>
Commit | Line | Data |
---|---|---|
d7dec593 | 1 | /*++\r |
2 | \r | |
3 | Copyright (c) 2006 - 2007, Intel Corporation \r | |
4 | All rights reserved. This program and the accompanying materials \r | |
5 | are licensed and made available under the terms and conditions of the BSD License \r | |
6 | which accompanies this distribution. The full text of the license may be found at \r | |
7 | http://opensource.org/licenses/bsd-license.php \r | |
8 | \r | |
9 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r | |
10 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r | |
11 | \r | |
12 | Module Name:\r | |
13 | \r | |
14 | GuidedSection.c\r | |
15 | \r | |
16 | Abstract:\r | |
17 | \r | |
18 | GUIDed section extraction protocol implementation. \r | |
19 | This contains the common constructor of GUIDed section\r | |
20 | extraction protocol. GUID specific implementation of each\r | |
21 | GUIDed section extraction protocol can be found in other\r | |
22 | files under the same directory.\r | |
23 | \r | |
24 | --*/\r | |
25 | \r | |
26 | #include "GuidedSection.h"\r | |
27 | \r | |
28 | EFI_STATUS\r | |
29 | GuidedSectionExtractionProtocolConstructor (\r | |
30 | OUT EFI_GUIDED_SECTION_EXTRACTION_PROTOCOL **GuidedSep,\r | |
31 | IN EFI_EXTRACT_GUIDED_SECTION ExtractSection\r | |
32 | )\r | |
33 | /*++\r | |
34 | \r | |
35 | Routine Description:\r | |
36 | \r | |
37 | Constructor for the GUIDed section extraction protocol. Initializes\r | |
38 | instance data.\r | |
39 | \r | |
40 | Arguments:\r | |
41 | \r | |
42 | This Instance to construct\r | |
43 | \r | |
44 | Returns:\r | |
45 | \r | |
46 | EFI_SUCCESS: Instance initialized.\r | |
47 | \r | |
48 | --*/\r | |
49 | // TODO: GuidedSep - add argument and description to function comment\r | |
50 | // TODO: ExtractSection - add argument and description to function comment\r | |
51 | // TODO: EFI_OUT_OF_RESOURCES - add return value to function comment\r | |
52 | {\r | |
53 | *GuidedSep = AllocatePool (sizeof (EFI_GUIDED_SECTION_EXTRACTION_PROTOCOL));\r | |
54 | if (*GuidedSep == NULL) {\r | |
55 | return EFI_OUT_OF_RESOURCES;\r | |
56 | }\r | |
57 | \r | |
58 | (*GuidedSep)->ExtractSection = ExtractSection;\r | |
59 | \r | |
60 | return EFI_SUCCESS;\r | |
61 | }\r |