]> git.proxmox.com Git - mirror_edk2.git/blame - QuarkPlatformPkg/Pci/Dxe/PciHostBridge/PciRootBridge.h
ArmPkg/CompilerIntrinsicsLib: Add uread, uwrite GCC assembly sources
[mirror_edk2.git] / QuarkPlatformPkg / Pci / Dxe / PciHostBridge / PciRootBridge.h
CommitLineData
b303605e
MK
1/** @file\r
2The PCI Root Bridge header file.\r
3\r
4Copyright (c) 2013-2015 Intel Corporation.\r
5\r
0eb3de2e 6SPDX-License-Identifier: BSD-2-Clause-Patent\r
b303605e
MK
7\r
8\r
9**/\r
10\r
11#ifndef _PCI_ROOT_BRIDGE_H_\r
12#define _PCI_ROOT_BRIDGE_H_\r
13\r
14#include <PiDxe.h>\r
15#include <IndustryStandard/Acpi.h>\r
16#include <IndustryStandard/Pci.h>\r
17#include <PciHostResource.h>\r
18\r
19//\r
20// Driver Consumed Protocol Prototypes\r
21//\r
22#include <Protocol/Metronome.h>\r
23#include <Protocol/CpuIo2.h>\r
24#include <Protocol/DevicePath.h>\r
25#include <Protocol/Runtime.h>\r
26#include <Protocol/PciRootBridgeIo.h>\r
27#include <Library/UefiLib.h>\r
28#include <Library/DebugLib.h>\r
29#include <Library/DevicePathLib.h>\r
30#include <Library/BaseMemoryLib.h>\r
31#include <Library/DxeServicesTableLib.h>\r
32#include <Library/UefiBootServicesTableLib.h>\r
33#include <Library/BaseLib.h>\r
34\r
35\r
36//\r
37// Define the region of memory used for DMA memory\r
38//\r
39#define DMA_MEMORY_TOP 0x0000000001FFFFFFULL\r
40\r
41//\r
42// The number of PCI root bridges\r
43//\r
44#define ROOT_BRIDGE_COUNT 1\r
45\r
46//\r
47// The default latency for controllers\r
48//\r
49#define DEFAULT_PCI_LATENCY 0x20\r
50\r
51//\r
52// Define resource status constant\r
53//\r
54typedef struct {\r
55 EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_OPERATION Operation;\r
56 UINTN NumberOfBytes;\r
57 UINTN NumberOfPages;\r
58 EFI_PHYSICAL_ADDRESS HostAddress;\r
59 EFI_PHYSICAL_ADDRESS MappedHostAddress;\r
60} MAP_INFO;\r
61\r
62typedef struct {\r
63 ACPI_HID_DEVICE_PATH AcpiDevicePath;\r
64 EFI_DEVICE_PATH_PROTOCOL EndDevicePath;\r
65} EFI_PCI_ROOT_BRIDGE_DEVICE_PATH;\r
66\r
67#define PCI_ROOT_BRIDGE_SIGNATURE SIGNATURE_32 ('e', '2', 'p', 'b')\r
68\r
69typedef struct {\r
70 UINT32 Signature;\r
71 EFI_LIST_ENTRY Link;\r
72 EFI_HANDLE Handle;\r
73 UINT64 RootBridgeAllocAttrib;\r
74 UINT64 Attributes;\r
75 UINT64 Supports;\r
76 PCI_RES_NODE ResAllocNode[6];\r
77 PCI_ROOT_BRIDGE_RESOURCE_APERTURE Aperture;\r
78 EFI_LOCK PciLock;\r
79 UINTN PciAddress;\r
80 UINTN PciData;\r
81 UINT32 HecBase;\r
82 UINT32 HecLen;\r
83 UINTN BusScanCount;\r
84 BOOLEAN BusNumberAssigned;\r
85 VOID *ConfigBuffer;\r
86 EFI_DEVICE_PATH_PROTOCOL *DevicePath;\r
87 EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL Io;\r
88} PCI_ROOT_BRIDGE_INSTANCE;\r
89\r
90//\r
91// Driver Instance Data Macros\r
92//\r
93#define DRIVER_INSTANCE_FROM_PCI_ROOT_BRIDGE_IO_THIS(a) CR (a, PCI_ROOT_BRIDGE_INSTANCE, Io, PCI_ROOT_BRIDGE_SIGNATURE)\r
94\r
95#define DRIVER_INSTANCE_FROM_LIST_ENTRY(a) CR (a, PCI_ROOT_BRIDGE_INSTANCE, Link, PCI_ROOT_BRIDGE_SIGNATURE)\r
96\r
97EFI_STATUS\r
98SimpleIioRootBridgeConstructor (\r
99 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *Protocol,\r
100 IN EFI_HANDLE HostBridgeHandle,\r
101 IN PCI_ROOT_BRIDGE_RESOURCE_APERTURE *ResAppeture,\r
102 IN UINT64 AllocAttributes\r
103 )\r
104/*++\r
105\r
106Routine Description:\r
107\r
108 Construct the Pci Root Bridge Io protocol.\r
109\r
110Arguments:\r
111\r
112 Protocol - Protocol to initialize.\r
113 HostBridgeHandle - Handle to the HostBridge.\r
114 ResAppeture - Resource apperture of the root bridge.\r
115 AllocAttributes - Attribute of resouce allocated.\r
116\r
117Returns:\r
118\r
119 EFI_SUCCESS - Success.\r
120 Others - Fail.\r
121\r
122--*/\r
123;\r
124\r
125//\r
126// Protocol Member Function Prototypes\r
127//\r
128EFI_STATUS\r
129EFIAPI\r
130RootBridgeIoPollMem (\r
131 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,\r
132 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width,\r
133 IN UINT64 Address,\r
134 IN UINT64 Mask,\r
135 IN UINT64 Value,\r
136 IN UINT64 Delay,\r
137 OUT UINT64 *Result\r
138 )\r
139/*++\r
140\r
141Routine Description:\r
142\r
143 Poll an address in memory mapped space until an exit condition is met\r
144 or a timeout occurs.\r
145\r
146Arguments:\r
147\r
148 This - Pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL instance.\r
149 Width - Width of the memory operation.\r
150 Address - The base address of the memory operation.\r
151 Mask - Mask used for polling criteria.\r
152 Value - Comparison value used for polling exit criteria.\r
153 Delay - Number of 100ns units to poll.\r
154 Result - Pointer to the last value read from memory location.\r
155\r
156Returns:\r
157\r
158 EFI_SUCCESS - Success.\r
159 EFI_INVALID_PARAMETER - Invalid parameter found.\r
160 EFI_TIMEOUT - Delay expired before a match occurred.\r
161 EFI_OUT_OF_RESOURCES - Fail due to lack of resources.\r
162\r
163--*/\r
164;\r
165\r
166EFI_STATUS\r
167EFIAPI\r
168RootBridgeIoPollIo (\r
169 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,\r
170 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width,\r
171 IN UINT64 Address,\r
172 IN UINT64 Mask,\r
173 IN UINT64 Value,\r
174 IN UINT64 Delay,\r
175 OUT UINT64 *Result\r
176 )\r
177/*++\r
178\r
179Routine Description:\r
180\r
181 Poll an address in I/O space until an exit condition is met\r
182 or a timeout occurs.\r
183\r
184Arguments:\r
185\r
186 This - Pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL instance.\r
187 Width - Width of I/O operation.\r
188 Address - The base address of the I/O operation.\r
189 Mask - Mask used for polling criteria.\r
190 Value - Comparison value used for polling exit criteria.\r
191 Delay - Number of 100ns units to poll.\r
192 Result - Pointer to the last value read from memory location.\r
193\r
194Returns:\r
195\r
196 EFI_SUCCESS - Success.\r
197 EFI_INVALID_PARAMETER - Invalid parameter found.\r
198 EFI_TIMEOUT - Delay expired before a match occurred.\r
199 EFI_OUT_OF_RESOURCES - Fail due to lack of resources.\r
200\r
201--*/\r
202;\r
203\r
204EFI_STATUS\r
205EFIAPI\r
206RootBridgeIoMemRead (\r
207 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,\r
208 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width,\r
209 IN UINT64 Address,\r
210 IN UINTN Count,\r
211 IN OUT VOID *Buffer\r
212 )\r
213/*++\r
214\r
215Routine Description:\r
216\r
217 Allow read from memory mapped I/O space.\r
218\r
219Arguments:\r
220\r
221 This - Pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL instance.\r
222 Width - The width of memory operation.\r
223 Address - Base address of the memory operation.\r
224 Count - Number of memory opeartion to perform.\r
225 Buffer - The destination buffer to store data.\r
226\r
227Returns:\r
228\r
229 EFI_SUCCESS - Success.\r
230 EFI_INVALID_PARAMETER - Invalid parameter found.\r
231 EFI_OUT_OF_RESOURCES - Fail due to lack of resources.\r
232\r
233--*/\r
234;\r
235\r
236EFI_STATUS\r
237EFIAPI\r
238RootBridgeIoMemWrite (\r
239 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,\r
240 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width,\r
241 IN UINT64 Address,\r
242 IN UINTN Count,\r
243 IN OUT VOID *Buffer\r
244 )\r
245/*++\r
246\r
247Routine Description:\r
248\r
249 Allow write to memory mapped I/O space.\r
250\r
251Arguments:\r
252\r
253 This - Pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL instance.\r
254 Width - The width of memory operation.\r
255 Address - Base address of the memory operation.\r
256 Count - Number of memory opeartion to perform.\r
257 Buffer - The source buffer to write data from.\r
258\r
259Returns:\r
260\r
261 EFI_SUCCESS - Success.\r
262 EFI_INVALID_PARAMETER - Invalid parameter found.\r
263 EFI_OUT_OF_RESOURCES - Fail due to lack of resources.\r
264\r
265--*/\r
266;\r
267\r
268EFI_STATUS\r
269EFIAPI\r
270RootBridgeIoIoRead (\r
271 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,\r
272 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width,\r
273 IN UINT64 UserAddress,\r
274 IN UINTN Count,\r
275 IN OUT VOID *UserBuffer\r
276 )\r
277/*++\r
278\r
279Routine Description:\r
280\r
281 Enable a PCI driver to read PCI controller registers in the\r
282 PCI root bridge I/O space.\r
283\r
284Arguments:\r
285\r
286 This - A pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL\r
287 Width - Signifies the width of the memory operation.\r
288 UserAddress - The base address of the I/O operation.\r
289 Count - The number of I/O operations to perform.\r
290 UserBuffer - The destination buffer to store the results.\r
291\r
292Returns:\r
293\r
294 EFI_SUCCESS - The data was read from the PCI root bridge.\r
295 EFI_INVALID_PARAMETER - Invalid parameters found.\r
296 EFI_OUT_OF_RESOURCES - The request could not be completed due to a lack of\r
297 resources.\r
298--*/\r
299;\r
300\r
301EFI_STATUS\r
302EFIAPI\r
303RootBridgeIoIoWrite (\r
304 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,\r
305 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width,\r
306 IN UINT64 UserAddress,\r
307 IN UINTN Count,\r
308 IN OUT VOID *UserBuffer\r
309 )\r
310/*++\r
311\r
312Routine Description:\r
313\r
314 Enable a PCI driver to write to PCI controller registers in the\r
315 PCI root bridge I/O space.\r
316\r
317Arguments:\r
318\r
319 This - A pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL\r
320 Width - Signifies the width of the memory operation.\r
321 UserAddress - The base address of the I/O operation.\r
322 Count - The number of I/O operations to perform.\r
323 UserBuffer - The source buffer to write data from.\r
324\r
325Returns:\r
326\r
327 EFI_SUCCESS - The data was written to the PCI root bridge.\r
328 EFI_INVALID_PARAMETER - Invalid parameters found.\r
329 EFI_OUT_OF_RESOURCES - The request could not be completed due to a lack of\r
330 resources.\r
331--*/\r
332;\r
333\r
334EFI_STATUS\r
335EFIAPI\r
336RootBridgeIoCopyMem (\r
337 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,\r
338 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width,\r
339 IN UINT64 DestAddress,\r
340 IN UINT64 SrcAddress,\r
341 IN UINTN Count\r
342 )\r
343/*++\r
344\r
345Routine Description:\r
346\r
347 Copy one region of PCI root bridge memory space to be copied to\r
348 another region of PCI root bridge memory space.\r
349\r
350Arguments:\r
351\r
352 This - A pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL instance.\r
353 Width - Signifies the width of the memory operation.\r
354 DestAddress - Destination address of the memory operation.\r
355 SrcAddress - Source address of the memory operation.\r
356 Count - Number of memory operations to perform.\r
357\r
358Returns:\r
359\r
360 EFI_SUCCESS - The data was copied successfully.\r
361 EFI_INVALID_PARAMETER - Invalid parameters found.\r
362 EFI_OUT_OF_RESOURCES - The request could not be completed due to a lack of\r
363 resources.\r
364--*/\r
365;\r
366\r
367EFI_STATUS\r
368EFIAPI\r
369RootBridgeIoPciRead (\r
370 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,\r
371 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width,\r
372 IN UINT64 Address,\r
373 IN UINTN Count,\r
374 IN OUT VOID *Buffer\r
375 )\r
376/*++\r
377\r
378Routine Description:\r
379\r
380 Allows read from PCI configuration space.\r
381\r
382Arguments:\r
383\r
384 This - A pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL\r
385 Width - Signifies the width of the memory operation.\r
386 Address - The address within the PCI configuration space\r
387 for the PCI controller.\r
388 Count - The number of PCI configuration operations\r
389 to perform.\r
390 Buffer - The destination buffer to store the results.\r
391\r
392Returns:\r
393\r
394 EFI_SUCCESS - The data was read from the PCI root bridge.\r
395 EFI_INVALID_PARAMETER - Invalid parameters found.\r
396 EFI_OUT_OF_RESOURCES - The request could not be completed due to a lack of\r
397 resources.\r
398--*/\r
399;\r
400\r
401EFI_STATUS\r
402EFIAPI\r
403RootBridgeIoPciWrite (\r
404 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,\r
405 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width,\r
406 IN UINT64 Address,\r
407 IN UINTN Count,\r
408 IN OUT VOID *Buffer\r
409 )\r
410/*++\r
411\r
412Routine Description:\r
413\r
414 Allows write to PCI configuration space.\r
415\r
416Arguments:\r
417\r
418 This - A pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL\r
419 Width - Signifies the width of the memory operation.\r
420 Address - The address within the PCI configuration space\r
421 for the PCI controller.\r
422 Count - The number of PCI configuration operations\r
423 to perform.\r
424 Buffer - The source buffer to get the results.\r
425\r
426Returns:\r
427\r
428 EFI_SUCCESS - The data was written to the PCI root bridge.\r
429 EFI_INVALID_PARAMETER - Invalid parameters found.\r
430 EFI_OUT_OF_RESOURCES - The request could not be completed due to a lack of\r
431 resources.\r
432--*/\r
433;\r
434\r
435EFI_STATUS\r
436EFIAPI\r
437RootBridgeIoMap (\r
438 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,\r
439 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_OPERATION Operation,\r
440 IN VOID *HostAddress,\r
441 IN OUT UINTN *NumberOfBytes,\r
442 OUT EFI_PHYSICAL_ADDRESS *DeviceAddress,\r
443 OUT VOID **Mapping\r
444 )\r
445/*++\r
446\r
447Routine Description:\r
448\r
449 Provides the PCI controller-specific address needed to access\r
450 system memory for DMA.\r
451\r
452Arguments:\r
453\r
454 This - A pointer to the EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL.\r
455 Operation - Indicate if the bus master is going to read or write\r
456 to system memory.\r
457 HostAddress - The system memory address to map on the PCI controller.\r
458 NumberOfBytes - On input the number of bytes to map.\r
459 On output the number of bytes that were mapped.\r
460 DeviceAddress - The resulting map address for the bus master PCI\r
461 controller to use to access the system memory's HostAddress.\r
462 Mapping - The value to pass to Unmap() when the bus master DMA\r
463 operation is complete.\r
464\r
465Returns:\r
466\r
467 EFI_SUCCESS - Success.\r
468 EFI_INVALID_PARAMETER - Invalid parameters found.\r
469 EFI_UNSUPPORTED - The HostAddress cannot be mapped as a common\r
470 buffer.\r
471 EFI_DEVICE_ERROR - The System hardware could not map the requested\r
472 address.\r
473 EFI_OUT_OF_RESOURCES - The request could not be completed due to\r
474 lack of resources.\r
475\r
476--*/\r
477;\r
478\r
479EFI_STATUS\r
480EFIAPI\r
481RootBridgeIoUnmap (\r
482 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,\r
483 IN VOID *Mapping\r
484 )\r
485/*++\r
486\r
487Routine Description:\r
488\r
489 Completes the Map() operation and releases any corresponding resources.\r
490\r
491Arguments:\r
492\r
493 This - Pointer to the EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL instance.\r
494 Mapping - The value returned from Map() operation.\r
495\r
496Returns:\r
497\r
498 EFI_SUCCESS - The range was unmapped successfully.\r
499 EFI_INVALID_PARAMETER - Mapping is not a value that was returned\r
500 by Map operation.\r
501 EFI_DEVICE_ERROR - The data was not committed to the target\r
502 system memory.\r
503\r
504--*/\r
505;\r
506\r
507EFI_STATUS\r
508EFIAPI\r
509RootBridgeIoAllocateBuffer (\r
510 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,\r
511 IN EFI_ALLOCATE_TYPE Type,\r
512 IN EFI_MEMORY_TYPE MemoryType,\r
513 IN UINTN Pages,\r
514 OUT VOID **HostAddress,\r
515 IN UINT64 Attributes\r
516 )\r
517/*++\r
518\r
519Routine Description:\r
520\r
521 Allocates pages that are suitable for a common buffer mapping.\r
522\r
523Arguments:\r
524\r
525 This - Pointer to EFI_ROOT_BRIDGE_IO_PROTOCOL instance.\r
526 Type - Not used and can be ignored.\r
527 MemoryType - Type of memory to allocate.\r
528 Pages - Number of pages to allocate.\r
529 HostAddress - Pointer to store the base system memory address\r
530 of the allocated range.\r
531 Attributes - Requested bit mask of attributes of the allocated\r
532 range.\r
533\r
534Returns:\r
535\r
536 EFI_SUCCESS - The requested memory range were allocated.\r
537 EFI_INVALID_PARAMETER - Invalid parameter found.\r
538 EFI_UNSUPPORTED - Attributes is unsupported.\r
539\r
540--*/\r
541;\r
542\r
543EFI_STATUS\r
544EFIAPI\r
545RootBridgeIoFreeBuffer (\r
546 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,\r
547 IN UINTN Pages,\r
548 OUT VOID *HostAddress\r
549 )\r
550/*++\r
551\r
552Routine Description:\r
553\r
554 Free memory allocated in AllocateBuffer.\r
555\r
556Arguments:\r
557\r
558 This - Pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL\r
559 instance.\r
560 Pages - Number of pages to free.\r
561 HostAddress - The base system memory address of the\r
562 allocated range.\r
563\r
564Returns:\r
565\r
566 EFI_SUCCESS - Requested memory pages were freed.\r
567 EFI_INVALID_PARAMETER - Invalid parameter found.\r
568\r
569--*/\r
570;\r
571\r
572EFI_STATUS\r
573EFIAPI\r
574RootBridgeIoFlush (\r
575 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This\r
576 )\r
577/*++\r
578\r
579Routine Description:\r
580\r
581 Flushes all PCI posted write transactions from a PCI host\r
582 bridge to system memory.\r
583\r
584Arguments:\r
585\r
586 This - Pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL instance.\r
587\r
588Returns:\r
589\r
590 EFI_SUCCESS - PCI posted write transactions were flushed\r
591 from PCI host bridge to system memory.\r
592 EFI_DEVICE_ERROR - Fail due to hardware error.\r
593\r
594--*/\r
595;\r
596\r
597EFI_STATUS\r
598EFIAPI\r
599RootBridgeIoGetAttributes (\r
600 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,\r
601 OUT UINT64 *Supported,\r
602 OUT UINT64 *Attributes\r
603 )\r
604/*++\r
605\r
606Routine Description:\r
607\r
608 Get the attributes that a PCI root bridge supports and\r
609 the attributes the PCI root bridge is currently using.\r
610\r
611Arguments:\r
612\r
613 This - Pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL\r
614 instance.\r
615 Supports - A pointer to the mask of attributes that\r
616 this PCI root bridge supports.\r
617 Attributes - A pointer to the mask of attributes that\r
618 this PCI root bridge is currently using.\r
619Returns:\r
620\r
621 EFI_SUCCESS - Success.\r
622 EFI_INVALID_PARAMETER - Invalid parameter found.\r
623\r
624--*/\r
625\r
626// GC_TODO: Supported - add argument and description to function comment\r
627//\r
628// GC_TODO: Supported - add argument and description to function comment\r
629//\r
630// GC_TODO: Supported - add argument and description to function comment\r
631//\r
632;\r
633\r
634EFI_STATUS\r
635EFIAPI\r
636RootBridgeIoSetAttributes (\r
637 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,\r
638 IN UINT64 Attributes,\r
639 IN OUT UINT64 *ResourceBase,\r
640 IN OUT UINT64 *ResourceLength\r
641 )\r
642/*++\r
643\r
644Routine Description:\r
645\r
646 Sets the attributes for a resource range on a PCI root bridge.\r
647\r
648Arguments:\r
649\r
650 This - Pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL instance.\r
651 Attributes - The mask of attributes to set.\r
652 ResourceBase - Pointer to the base address of the resource range\r
653 to be modified by the attributes specified by Attributes.\r
654 ResourceLength - Pointer to the length of the resource range to be modified.\r
655\r
656Returns:\r
657 EFI_SUCCESS - Success.\r
658 EFI_INVALID_PARAMETER - Invalid parameter found.\r
659 EFI_OUT_OF_RESOURCES - Not enough resources to set the attributes upon.\r
660\r
661--*/\r
662;\r
663\r
664EFI_STATUS\r
665EFIAPI\r
666RootBridgeIoConfiguration (\r
667 IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This,\r
668 OUT VOID **Resources\r
669 )\r
670/*++\r
671\r
672Routine Description:\r
673\r
674 Retrieves the current resource settings of this PCI root bridge\r
675 in the form of a set of ACPI 2.0 resource descriptor.\r
676\r
677Arguments:\r
678\r
679 This - Pointer to the EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL instance.\r
680 Resources - Pointer to the ACPI 2.0 resource descriptor that\r
681 describe the current configuration of this PCI root\r
682 bridge.\r
683\r
684Returns:\r
685\r
686 EFI_SUCCESS - Success.\r
687 EFI_UNSUPPORTED - Current configuration of the PCI root bridge\r
688 could not be retrieved.\r
689\r
690--*/\r
691;\r
692\r
693#endif\r