1 | /** @file
|
---|
2 | Master header file for SecCore.
|
---|
3 |
|
---|
4 | Copyright (c) 2022, Ventana Micro Systems Inc. All rights reserved.<BR>
|
---|
5 | SPDX-License-Identifier: BSD-2-Clause-Patent
|
---|
6 |
|
---|
7 | **/
|
---|
8 |
|
---|
9 | #ifndef SEC_MAIN_H_
|
---|
10 | #define SEC_MAIN_H_
|
---|
11 |
|
---|
12 | #include <PiPei.h>
|
---|
13 | #include <Library/BaseLib.h>
|
---|
14 | #include <Library/BaseMemoryLib.h>
|
---|
15 | #include <Library/DebugAgentLib.h>
|
---|
16 | #include <Library/DebugLib.h>
|
---|
17 | #include <Library/ExtractGuidedSectionLib.h>
|
---|
18 | #include <Library/IoLib.h>
|
---|
19 | #include <Library/HobLib.h>
|
---|
20 | #include <Library/PcdLib.h>
|
---|
21 | #include <Library/PeCoffExtraActionLib.h>
|
---|
22 | #include <Library/PeCoffGetEntryPointLib.h>
|
---|
23 | #include <Library/PeCoffLib.h>
|
---|
24 | #include <Library/PeiServicesLib.h>
|
---|
25 | #include <Library/PeiServicesTablePointerLib.h>
|
---|
26 | #include <Library/DebugPrintErrorLevelLib.h>
|
---|
27 | #include <Library/PrintLib.h>
|
---|
28 | #include <Library/BaseRiscVSbiLib.h>
|
---|
29 | #include <Library/PrePiLib.h>
|
---|
30 | #include <Library/PlatformInitLib.h>
|
---|
31 | #include <Library/PrePiHobListPointerLib.h>
|
---|
32 | #include <Library/SerialPortLib.h>
|
---|
33 | #include <Register/RiscV64/RiscVImpl.h>
|
---|
34 |
|
---|
35 | /**
|
---|
36 | Entry point to the C language phase of SEC. After the SEC assembly
|
---|
37 | code has initialized some temporary memory and set up the stack,
|
---|
38 | the control is transferred to this function.
|
---|
39 |
|
---|
40 | @param SizeOfRam Size of the temporary memory available for use.
|
---|
41 | @param TempRamBase Base address of temporary ram
|
---|
42 | @param BootFirmwareVolume Base address of the Boot Firmware Volume.
|
---|
43 | **/
|
---|
44 | VOID
|
---|
45 | NORETURN
|
---|
46 | EFIAPI
|
---|
47 | SecStartup (
|
---|
48 | IN UINTN BootHartId,
|
---|
49 | IN VOID *DeviceTreeAddress
|
---|
50 | );
|
---|
51 |
|
---|
52 | /**
|
---|
53 | Perform Platform PEIM initialization.
|
---|
54 |
|
---|
55 | @return EFI_SUCCESS The platform initialized successfully.
|
---|
56 | @retval Others - As the error code indicates
|
---|
57 |
|
---|
58 | **/
|
---|
59 | EFI_STATUS
|
---|
60 | EFIAPI
|
---|
61 | PlatformPeimInitialization (
|
---|
62 | VOID
|
---|
63 | );
|
---|
64 |
|
---|
65 | /**
|
---|
66 | Perform Memory PEIM initialization.
|
---|
67 |
|
---|
68 | @return EFI_SUCCESS The platform initialized successfully.
|
---|
69 | @retval Others - As the error code indicates
|
---|
70 |
|
---|
71 | **/
|
---|
72 | EFI_STATUS
|
---|
73 | EFIAPI
|
---|
74 | MemoryPeimInitialization (
|
---|
75 | VOID
|
---|
76 | );
|
---|
77 |
|
---|
78 | /**
|
---|
79 | Perform CPU PEIM initialization.
|
---|
80 |
|
---|
81 | @return EFI_SUCCESS The platform initialized successfully.
|
---|
82 | @retval Others - As the error code indicates
|
---|
83 |
|
---|
84 | **/
|
---|
85 | EFI_STATUS
|
---|
86 | EFIAPI
|
---|
87 | CpuPeimInitialization (
|
---|
88 | VOID
|
---|
89 | );
|
---|
90 |
|
---|
91 | #endif
|
---|