]> git.proxmox.com Git - mirror_edk2.git/blob - ArmPlatformPkg/Library/PrePiHobListPointerLib/PrePiHobListPointer.c
5b0b31b1448d5ea28a86023c4f23b7a616d1ad3f
[mirror_edk2.git] / ArmPlatformPkg / Library / PrePiHobListPointerLib / PrePiHobListPointer.c
1 /** @file
2
3 Copyright (c) 2011, ARM Limited. All rights reserved.
4
5 SPDX-License-Identifier: BSD-2-Clause-Patent
6
7 **/
8
9 #include <PiPei.h>
10 #include <Library/ArmLib.h>
11 #include <Library/PrePiHobListPointerLib.h>
12 #include <Library/DebugLib.h>
13
14 /**
15 Returns the pointer to the HOB list.
16
17 This function returns the pointer to first HOB in the list.
18
19 @return The pointer to the HOB list.
20
21 **/
22 VOID *
23 EFIAPI
24 PrePeiGetHobList (
25 VOID
26 )
27 {
28 return (VOID *)ArmReadTpidrurw ();
29 }
30
31 /**
32 Updates the pointer to the HOB list.
33
34 @param HobList Hob list pointer to store
35
36 **/
37 EFI_STATUS
38 EFIAPI
39 PrePeiSetHobList (
40 IN VOID *HobList
41 )
42 {
43 ArmWriteTpidrurw ((UINTN)HobList);
44
45 return EFI_SUCCESS;
46 }