]> git.proxmox.com Git - mirror_edk2.git/blame - EdkModulePkg/Core/Dxe/DebugImageInfo.h
Add folder for common PcdTools classes.
[mirror_edk2.git] / EdkModulePkg / Core / Dxe / DebugImageInfo.h
CommitLineData
878ddf1f 1/*++\r
2\r
3Copyright (c) 2006, Intel Corporation \r
4All rights reserved. This program and the accompanying materials \r
5are licensed and made available under the terms and conditions of the BSD License \r
6which accompanies this distribution. The full text of the license may be found at \r
7http://opensource.org/licenses/bsd-license.php \r
8 \r
9THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
10WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
11\r
12Module Name:\r
13\r
14 DebugImageInfo.h\r
15 \r
16Abstract:\r
17\r
18 Support functions for managing debug image info table when loading and unloading\r
19 images.\r
20\r
21--*/\r
22\r
23#ifndef __DEBUG_IMAGE_INFO_H__\r
24#define __DEBUG_IMAGE_INFO_H__\r
25\r
26#define FOUR_MEG_PAGES 0x400 \r
27#define FOUR_MEG_MASK ((FOUR_MEG_PAGES * EFI_PAGE_SIZE) - 1)\r
28\r
29#define EFI_DEBUG_TABLE_ENTRY_SIZE (sizeof (VOID *))\r
30\r
31VOID\r
32CoreInitializeDebugImageInfoTable (\r
33 VOID\r
34 )\r
35/*++\r
36\r
37Routine Description:\r
38\r
39 Creates and initializes the DebugImageInfo Table. Also creates the configuration\r
40 table and registers it into the system table.\r
41\r
42Arguments:\r
43 None\r
44\r
45Returns:\r
46 NA\r
47\r
48Notes:\r
49 This function allocates memory, frees it, and then allocates memory at an\r
50 address within the initial allocation. Since this function is called early\r
51 in DXE core initialization (before drivers are dispatched), this should not\r
52 be a problem.\r
53\r
54--*/\r
55;\r
56\r
57VOID\r
58CoreUpdateDebugTableCrc32 (\r
59 VOID\r
60 )\r
61/*++\r
62\r
63Routine Description:\r
64\r
65 Update the CRC32 in the Debug Table.\r
66 Since the CRC32 service is made available by the Runtime driver, we have to\r
67 wait for the Runtime Driver to be installed before the CRC32 can be computed.\r
68 This function is called elsewhere by the core when the runtime architectural\r
69 protocol is produced.\r
70\r
71Arguments:\r
72 None\r
73\r
74Returns:\r
75 NA\r
76\r
77--*/\r
78;\r
79\r
80VOID\r
81CoreNewDebugImageInfoEntry (\r
82 UINTN ImageInfoType,\r
83 EFI_LOADED_IMAGE_PROTOCOL *LoadedImage,\r
84 EFI_HANDLE ImageHandle\r
85 )\r
86/*++\r
87\r
88Routine Description:\r
89\r
90 Adds a new DebugImageInfo structure to the DebugImageInfo Table. Re-Allocates\r
91 the table if it's not large enough to accomidate another entry.\r
92\r
93Arguments:\r
94\r
95 ImageInfoType - type of debug image information\r
96 LoadedImage - pointer to the loaded image protocol for the image being loaded\r
97 ImageHandle - image handle for the image being loaded\r
98\r
99Returns:\r
100 NA\r
101\r
102--*/\r
103;\r
104\r
105VOID\r
106CoreRemoveDebugImageInfoEntry (\r
107 EFI_HANDLE ImageHandle\r
108 )\r
109/*++\r
110\r
111Routine Description:\r
112\r
113 Removes and frees an entry from the DebugImageInfo Table.\r
114\r
115Arguments:\r
116\r
117 ImageHandle - image handle for the image being unloaded\r
118\r
119Returns:\r
120\r
121 NA\r
122\r
123--*/\r
124;\r
125\r
126#endif\r