]> git.proxmox.com Git - mirror_edk2.git/blob - EdkCompatibilityPkg/Foundation/Framework/Protocol/PciHotPlugInit/PciHotPlugInit.h
Add in the 1st version of ECP.
[mirror_edk2.git] / EdkCompatibilityPkg / Foundation / Framework / Protocol / PciHotPlugInit / PciHotPlugInit.h
1 /*++
2
3 Copyright (c) 2004, Intel Corporation
4 All rights reserved. This program and the accompanying materials
5 are licensed and made available under the terms and conditions of the BSD License
6 which accompanies this distribution. The full text of the license may be found at
7 http://opensource.org/licenses/bsd-license.php
8
9 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
10 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
11
12 Module Name:
13
14 PciHotPlugInit.h
15
16 Abstract:
17
18 EFI PCI Hot Plug Init Protocol
19
20 Revision History
21
22 --*/
23
24 #ifndef _EFI_PCI_HOT_PLUG_INIT_H
25 #define _EFI_PCI_HOT_PLUG_INIT_H
26
27 //
28 // Global ID for the PCI Hot Plug Protocol
29 //
30 #define EFI_PCI_HOT_PLUG_INIT_PROTOCOL_GUID \
31 { 0xaa0e8bc1, 0xdabc, 0x46b0, 0xa8, 0x44, 0x37, 0xb8, 0x16, 0x9b, 0x2b, 0xea }
32
33
34 EFI_FORWARD_DECLARATION (EFI_PCI_HOT_PLUG_INIT_PROTOCOL);
35
36 #define EFI_HPC_STATE_INITIALIZED 0x01
37 #define EFI_HPC_STATE_ENABLED 0x02
38
39 typedef UINT16 EFI_HPC_STATE;
40
41
42 typedef struct{
43 EFI_DEVICE_PATH_PROTOCOL *HpcDevicePath;
44 EFI_DEVICE_PATH_PROTOCOL *HpbDevicePath;
45 } EFI_HPC_LOCATION;
46
47
48 typedef enum{
49 EfiPaddingPciBus,
50 EfiPaddingPciRootBridge
51 } EFI_HPC_PADDING_ATTRIBUTES;
52
53 typedef
54 EFI_STATUS
55 (EFIAPI *EFI_GET_ROOT_HPC_LIST) (
56 IN EFI_PCI_HOT_PLUG_INIT_PROTOCOL *This,
57 OUT UINTN *HpcCount,
58 OUT EFI_HPC_LOCATION **HpcList
59 );
60
61 typedef
62 EFI_STATUS
63 (EFIAPI *EFI_INITIALIZE_ROOT_HPC) (
64 IN EFI_PCI_HOT_PLUG_INIT_PROTOCOL *This,
65 IN EFI_DEVICE_PATH_PROTOCOL *HpcDevicePath,
66 IN UINT64 HpcPciAddress,
67 IN EFI_EVENT Event, OPTIONAL
68 OUT EFI_HPC_STATE *HpcState
69 );
70
71 typedef
72 EFI_STATUS
73 (EFIAPI *EFI_GET_PCI_HOT_PLUG_PADDING) (
74 IN EFI_PCI_HOT_PLUG_INIT_PROTOCOL *This,
75 IN EFI_DEVICE_PATH_PROTOCOL *HpcDevicePath,
76 IN UINT64 HpcPciAddress,
77 OUT EFI_HPC_STATE *HpcState,
78 OUT VOID **Padding,
79 OUT EFI_HPC_PADDING_ATTRIBUTES *Attributes
80 );
81
82
83 //
84 // Prototypes for the PCI Hot Plug Init Protocol
85 //
86
87
88 typedef struct _EFI_PCI_HOT_PLUG_INIT_PROTOCOL {
89 EFI_GET_ROOT_HPC_LIST GetRootHpcList;
90 EFI_INITIALIZE_ROOT_HPC InitializeRootHpc;
91 EFI_GET_PCI_HOT_PLUG_PADDING GetResourcePadding;
92 } EFI_PCI_HOT_PLUG_INIT_PROTOCOL;
93
94
95 extern EFI_GUID gEfiPciHotPlugInitProtocolGuid;
96
97 #endif