Skip to content

Commit

Permalink
OcConfigurationLib: Try to call pcd setters
Browse files Browse the repository at this point in the history
  • Loading branch information
PMheart committed Mar 31, 2022
1 parent b47231f commit 3968b3b
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 1 deletion.
6 changes: 5 additions & 1 deletion Include/Acidanthera/Library/OcConfigurationLib.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
#include <Library/DebugLib.h>
#include <Library/OcSerializeLib.h>
#include <Library/OcBootManagementLib.h>
#include <Library/PcdLib.h>

/**
ACPI section
Expand Down Expand Up @@ -407,7 +408,10 @@ typedef enum {
OC_DECLARE (OC_MISC_TOOLS_ARRAY)

#define OC_MISC_SERIAL_FIELDS(_, __) \
_(UINT32 , BaudRate , , 115200 , ()) \
//
// TODO: Call pcd getters & Fix build
//
_(UINT32 , BaudRate , , PcdGet8 (PcdSerialRegisterAccessWidth) , ()) \
_(UINT32 , ClockRate , , 1843200 , ()) \
_(BOOLEAN , DetectCable , , FALSE , ()) \
_(UINT32 , ExtendedTxFifoSize , , 64 , ()) \
Expand Down
18 changes: 18 additions & 0 deletions Library/OcConfigurationLib/OcConfigurationLib.inf
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,26 @@

[Packages]
MdePkg/MdePkg.dec
MdeModulePkg/MdeModulePkg.dec
OpenCorePkg/OpenCorePkg.dec

[Guids]
gEfiMdeModulePkgTokenSpaceGuid

[Pcd]
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialRegisterAccessWidth ## SOMETIMES_CONSUMES
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialUseMmio ## CONSUMES
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialUseHardwareFlowControl ## CONSUMES
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialDetectCable ## SOMETIMES_CONSUMES
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialRegisterBase ## CONSUMES
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialBaudRate ## CONSUMES
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialLineControl ## CONSUMES
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialFifoControl ## CONSUMES
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialClockRate ## CONSUMES
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialPciDeviceInfo ## CONSUMES
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialExtendedTxFifoSize ## CONSUMES
gEfiMdeModulePkgTokenSpaceGuid.PcdSerialRegisterStride ## CONSUMES

[LibraryClasses]
BaseLib
DebugLib
Expand Down

0 comments on commit 3968b3b

Please sign in to comment.