public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Nhi Pham" <nhi@os.amperecomputing.com>
To: devel@edk2.groups.io, quic_llindhol@quicinc.com,
	ardb+tianocore@kernel.org, sami.mujawar@arm.com,
	quic_rcran@quicinc.com
Cc: patches@amperecomputing.com, Nhi Pham <nhi@os.amperecomputing.com>
Subject: [edk2-platforms][PATCH 1/2] SbsaQemu/OemMiscLib: Update for new OemMiscLib APIs
Date: Tue, 13 Sep 2022 13:17:34 +0700	[thread overview]
Message-ID: <20220913061735.735632-2-nhi@os.amperecomputing.com> (raw)
In-Reply-To: <20220913061735.735632-1-nhi@os.amperecomputing.com>

This is to reflect the new APIs added to edk2/OemMiscLib library.

Signed-off-by: Nhi Pham <nhi@os.amperecomputing.com>
---
 Platform/Qemu/SbsaQemu/OemMiscLib/OemMiscLib.inf |  3 ++
 Platform/Qemu/SbsaQemu/OemMiscLib/OemMiscLib.c   | 42 ++++++++++++++++++++
 2 files changed, 45 insertions(+)

diff --git a/Platform/Qemu/SbsaQemu/OemMiscLib/OemMiscLib.inf b/Platform/Qemu/SbsaQemu/OemMiscLib/OemMiscLib.inf
index 04a07a55cee9..94e368e50a3c 100644
--- a/Platform/Qemu/SbsaQemu/OemMiscLib/OemMiscLib.inf
+++ b/Platform/Qemu/SbsaQemu/OemMiscLib/OemMiscLib.inf
@@ -34,6 +34,9 @@ [LibraryClasses]
   IoLib
   PcdLib
 
+[Guids]
+  gZeroGuid
+
 [Pcd]
   gArmVirtSbsaQemuPlatformTokenSpaceGuid.PcdDeviceTreeBaseAddress
 
diff --git a/Platform/Qemu/SbsaQemu/OemMiscLib/OemMiscLib.c b/Platform/Qemu/SbsaQemu/OemMiscLib/OemMiscLib.c
index 326bb56bcfa3..f14c18ef0874 100644
--- a/Platform/Qemu/SbsaQemu/OemMiscLib/OemMiscLib.c
+++ b/Platform/Qemu/SbsaQemu/OemMiscLib/OemMiscLib.c
@@ -9,6 +9,7 @@
 **/
 
 #include <Uefi.h>
+#include <Guid/ZeroGuid.h>
 #include <Library/BaseMemoryLib.h>
 #include <Library/DebugLib.h>
 #include <Library/FdtHelperLib.h>
@@ -330,3 +331,44 @@ OemGetChassisNumPowerCords (
 {
   return 1;
 }
+
+/**
+  Fetches the system UUID.
+
+  @param[out] SystemUuid     The pointer to the buffer to store the System UUID.
+
+**/
+VOID
+EFIAPI
+OemGetSystemUuid (
+  OUT GUID  *SystemUuid
+  )
+{
+  CopyGuid (SystemUuid, &gZeroGuid);
+}
+
+/** Fetches the BIOS release.
+
+  @return The BIOS release.
+**/
+UINT16
+EFIAPI
+OemGetBiosRelease (
+  VOID
+  )
+{
+  return 0xFFFF;
+}
+
+/** Fetches the embedded controller firmware release.
+
+  @return The embedded controller firmware release.
+**/
+UINT16
+EFIAPI
+OemGetEmbeddedControllerFirmwareRelease (
+  VOID
+  )
+{
+  return 0xFFFF;
+}
-- 
2.25.1


  reply	other threads:[~2022-09-13  6:20 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-13  6:17 [edk2-platforms][PATCH 0/2] Update SbsaQemu/OemMiscLib Nhi Pham
2022-09-13  6:17 ` Nhi Pham [this message]
2022-09-15 10:55   ` [edk2-platforms][PATCH 1/2] SbsaQemu/OemMiscLib: Update for new OemMiscLib APIs Leif Lindholm
2022-09-13  6:17 ` [edk2-platforms][PATCH 2/2] SbsaQemu/OemMiscLib: Fix typo of "AssetTagType02" Nhi Pham
2022-09-15 10:56   ` Leif Lindholm

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220913061735.735632-2-nhi@os.amperecomputing.com \
    --to=devel@edk2.groups.io \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox