]> git.proxmox.com Git - mirror_edk2.git/blob - QuarkSocPkg/QuarkNorthCluster/S3Support/Dxe/QncS3Support.h
a126e38b7f1af803de95797e8fbdb3142d630be0
[mirror_edk2.git] / QuarkSocPkg / QuarkNorthCluster / S3Support / Dxe / QncS3Support.h
1 /** @file
2 Header file for QNC S3 Support driver
3
4 This file includes package header files, library classes and protocol, PPI & GUID definitions.
5
6 Copyright (c) 2013-2015 Intel Corporation.
7
8 SPDX-License-Identifier: BSD-2-Clause-Patent
9 **/
10
11 #ifndef _QNC_S3_SUPPORT_H_
12 #define _QNC_S3_SUPPORT_H_
13
14 //
15 // External include files do NOT need to be explicitly specified in real EDKII
16 // environment
17 //
18 //
19 // Driver Consumed Protocol Prototypes
20 //
21 #include <Protocol/FirmwareVolume2.h>
22 #include <Library/UefiLib.h>
23 #include <Library/IoLib.h>
24 #include <Library/DebugLib.h>
25 #include <Library/DxeServicesLib.h>
26 #include <Library/S3BootScriptLib.h>
27 #include <Library/BaseMemoryLib.h>
28 #include <Library/PeCoffLib.h>
29 #include <Library/LockBoxLib.h>
30 #include <Library/UefiDriverEntryPoint.h>
31 #include <Library/UefiBootServicesTableLib.h>
32 #include <Library/UefiRuntimeServicesTableLib.h>
33 //
34 // Driver Produced Protocol Prototypes
35 //
36 #include <Protocol/LoadedImage.h>
37 #include <Protocol/QncS3Support.h>
38
39 #include <Library/CacheMaintenanceLib.h>
40 #include <Library/IntelQNCLib.h>
41 //
42 // Define the header of the context region.
43 //
44 typedef struct {
45 UINT32 MaxContexts;
46 UINT32 StorePosition;
47 EFI_DISPATCH_CONTEXT_UNION Contexts[1];
48 } QNC_S3_PARAMETER_HEADER;
49 //
50 // Function prototypes
51 //
52 EFI_STATUS
53 EFIAPI
54 QncS3SetDispatchItem (
55 IN EFI_QNC_S3_SUPPORT_PROTOCOL *This,
56 IN EFI_QNC_S3_DISPATCH_ITEM *DispatchItem,
57 OUT VOID **S3DispatchEntryPoint,
58 OUT VOID **Context
59 )
60 /*++
61
62 Routine Description:
63
64 Set an item to be dispatched at S3 resume time. At the same time, the entry point
65 of the QNC S3 support image is returned to be used in subsequent boot script save
66 call
67
68 Arguments:
69
70 This - Pointer to the protocol instance.
71 DispatchItem - The item to be dispatched.
72 S3DispatchEntryPoint - The entry point of the QNC S3 support image.
73
74 Returns:
75
76 EFI_STATUS - Successfully completed.
77 EFI_OUT_OF_RESOURCES - Out of resources.
78
79 --*/
80 ;
81
82 EFI_STATUS
83 LoadQncS3Image (
84 IN EFI_SYSTEM_TABLE *SystemTable
85 )
86 /*++
87
88 Routine Description:
89
90 Load the QNC S3 Image into Efi Reserved Memory below 4G.
91
92 Arguments:
93
94 ImageEntryPoint the ImageEntryPoint after success loading
95
96 Returns:
97
98 EFI_STATUS
99
100 --*/
101 ;
102
103 EFI_STATUS
104 QncS3InitPcieRootPortDownstream (
105 IN EFI_HANDLE ImageHandle,
106 IN VOID *Context
107 );
108
109 VOID
110 EFIAPI
111 QncS3BootEvent (
112 IN EFI_EVENT Event,
113 IN VOID *Context
114 );
115
116
117 #endif