This updates the recently added DtPlatformDxe to indirect loading of the
actual DTB binary to a separate library. A base implementation is provided
that preserves the original behavior.
This way, we can allow platforms such as FVP or Juno (which use the same
firmware image but different DTB images) to override this library class
and insert its own logic to select the correct DTB, without resorting to
BEFORE depexes and dynamic PCDs, and the associated load order issues.
v2: - drop ArmPlatformPkg changes for now
Ard Biesheuvel (3):
EmbeddedPkg: add DtPlatformDtbLoaderLib library class
EmbeddedPkg: add base DtPlatformDtbLoaderLib implementation
EmbeddedPkg/DtPlatformDxe: load platform DTB via new library
EmbeddedPkg/Drivers/DtPlatformDxe/DtPlatformDxe.c | 26 ++++-----
EmbeddedPkg/Drivers/DtPlatformDxe/DtPlatformDxe.inf | 2 +-
EmbeddedPkg/EmbeddedPkg.dec | 1 +
EmbeddedPkg/EmbeddedPkg.dsc | 6 ++
EmbeddedPkg/Include/Library/DtPlatformDtbLoaderLib.h | 37 ++++++++++++
EmbeddedPkg/Library/DtPlatformDtbLoaderBaseLib/DtPlatformDtbLoaderBaseLib.c | 60 ++++++++++++++++++++
EmbeddedPkg/Library/DtPlatformDtbLoaderBaseLib/DtPlatformDtbLoaderBaseLib.inf | 36 ++++++++++++
7 files changed, 154 insertions(+), 14 deletions(-)
create mode 100644 EmbeddedPkg/Include/Library/DtPlatformDtbLoaderLib.h
create mode 100644 EmbeddedPkg/Library/DtPlatformDtbLoaderBaseLib/DtPlatformDtbLoaderBaseLib.c
create mode 100644 EmbeddedPkg/Library/DtPlatformDtbLoaderBaseLib/DtPlatformDtbLoaderBaseLib.inf
--
2.9.3
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel