public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: brucex.wang@intel.com
To: devel@edk2.groups.io
Cc: brucex.wang@intel.com, Guo Dong <guo.dong@intel.com>,
	Sean Rhodes <sean@starlabs.systems>,
	James Lu <james.lu@intel.com>, Gua Guo <gua.guo@intel.com>
Subject: [edk2-devel] [PATCH v1 1/1] UefiPayloadPkg: Cleanup ProcessLibraryConstructorList()
Date: Fri, 15 Mar 2024 17:20:42 +0800	[thread overview]
Message-ID: <20240315092042.1644-2-brucex.wang@intel.com> (raw)
In-Reply-To: <20240315092042.1644-1-brucex.wang@intel.com>

From: Bruce Wang <brucex.wang@intel.com>

ProcessLibraryConstructorList() no needs to be called manually
after INF version greater or equal to 1.30.

Cc: Guo Dong <guo.dong@intel.com>
Cc: Sean Rhodes <sean@starlabs.systems>
Cc: James Lu <james.lu@intel.com>
Cc: Gua Guo <gua.guo@intel.com>

Signed-off-by: BruceX Wang <brucex.wang@intel.com>
---
 UefiPayloadPkg/UefiPayloadEntry/FitUniversalPayloadEntry.c | 2 --
 UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c         | 2 --
 UefiPayloadPkg/UefiPayloadEntry/UniversalPayloadEntry.c    | 2 --
 3 files changed, 6 deletions(-)

diff --git a/UefiPayloadPkg/UefiPayloadEntry/FitUniversalPayloadEntry.c b/UefiPayloadPkg/UefiPayloadEntry/FitUniversalPayloadEntry.c
index eb0b325369..58a7e8190f 100644
--- a/UefiPayloadPkg/UefiPayloadEntry/FitUniversalPayloadEntry.c
+++ b/UefiPayloadPkg/UefiPayloadEntry/FitUniversalPayloadEntry.c
@@ -616,8 +616,6 @@ _ModuleEntryPoint (
 
   mHobList = (VOID *)BootloaderParameter;
   DxeFv    = NULL;
-  // Call constructor for all libraries
-  ProcessLibraryConstructorList ();
 
   DEBUG ((DEBUG_INFO, "Entering Universal Payload...\n"));
   DEBUG ((DEBUG_INFO, "sizeof(UINTN) = 0x%x\n", sizeof (UINTN)));
diff --git a/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c b/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c
index 030a5baed9..7c65869563 100644
--- a/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c
+++ b/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c
@@ -434,8 +434,6 @@ _ModuleEntryPoint (
     UniversalSerialPort->RegisterStride  = (UINT8)SerialPortInfo.RegWidth;
   }
 
-  // The library constructors might depend on serial port, so call it after serial port hob
-  ProcessLibraryConstructorList ();
   DEBUG ((DEBUG_INFO, "sizeof(UINTN) = 0x%x\n", sizeof (UINTN)));
 
   // Build HOB based on information from Bootloader
diff --git a/UefiPayloadPkg/UefiPayloadEntry/UniversalPayloadEntry.c b/UefiPayloadPkg/UefiPayloadEntry/UniversalPayloadEntry.c
index f37c00fad7..019b6b3d8b 100644
--- a/UefiPayloadPkg/UefiPayloadEntry/UniversalPayloadEntry.c
+++ b/UefiPayloadPkg/UefiPayloadEntry/UniversalPayloadEntry.c
@@ -462,8 +462,6 @@ _ModuleEntryPoint (
 
   mHobList = (VOID *)BootloaderParameter;
   DxeFv    = NULL;
-  // Call constructor for all libraries
-  ProcessLibraryConstructorList ();
 
   DEBUG ((DEBUG_INFO, "Entering Universal Payload...\n"));
   DEBUG ((DEBUG_INFO, "sizeof(UINTN) = 0x%x\n", sizeof (UINTN)));
-- 
2.39.1.windows.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#116865): https://edk2.groups.io/g/devel/message/116865
Mute This Topic: https://groups.io/mt/105014773/7686176
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io]
-=-=-=-=-=-=-=-=-=-=-=-



  reply	other threads:[~2024-03-18 23:18 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-15  9:20 [edk2-devel] [PATCH v1 0/1] Cleanup ProcessLibraryConstructorList() brucex.wang
2024-03-15  9:20 ` brucex.wang [this message]
2024-03-15  9:28   ` [edk2-devel] [PATCH v1 1/1] UefiPayloadPkg: " Guo, Gua

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=20240315092042.1644-2-brucex.wang@intel.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