[edk2-devel] [`edk2-devel][PATCH V2] UefiPayloadPkg: Fix the build issue for coreboot

Guo Dong posted 1 patch 2 years, 6 months ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/edk2 tags/patchew/20211015050751.498-1-guo.dong@intel.com
UefiPayloadPkg/Library/CbParseLib/CbParseLib.c     | 4 ++--
UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c | 4 +++-
2 files changed, 5 insertions(+), 3 deletions(-)
[edk2-devel] [`edk2-devel][PATCH V2] UefiPayloadPkg: Fix the build issue for coreboot
Posted by Guo Dong 2 years, 6 months ago
From: Guo Dong <guo.dong@intel.com>

V2: Fix GCC build issue.

There is typo in previous change caused coreboot build failue.
This patch fixed the build issue.

Cc: Ray Ni <ray.ni@intel.com>
Cc: Maurice Ma <maurice.ma@intel.com>
Cc: Benjamin You <benjamin.you@intel.com>
Signed-off-by: Guo Dong <guo.dong@intel.com>
---
 UefiPayloadPkg/Library/CbParseLib/CbParseLib.c     | 4 ++--
 UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c | 4 +++-
 2 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/UefiPayloadPkg/Library/CbParseLib/CbParseLib.c b/UefiPayloadPkg/Library/CbParseLib/CbParseLib.c
index f81aa0f301..4be5d66ba5 100644
--- a/UefiPayloadPkg/Library/CbParseLib/CbParseLib.c
+++ b/UefiPayloadPkg/Library/CbParseLib/CbParseLib.c
@@ -194,8 +194,8 @@ GetParameterBase (
     return NULL;
   }
 
-  PcdSet64S (PcdBootloaderParameter, (UINTN)CbTablePtr);
-  ASSERT_EFI_STATUS (Status);
+  Status = PcdSet64S (PcdBootloaderParameter, (UINTN)CbTablePtr);
+  ASSERT_EFI_ERROR (Status);
 
   return CbTablePtr;
 }
diff --git a/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c b/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c
index 5a1e578668..0e6dcf10f9 100644
--- a/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c
+++ b/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c
@@ -406,7 +406,9 @@ _ModuleEntryPoint (
   SERIAL_PORT_INFO              SerialPortInfo;
   UNIVERSAL_PAYLOAD_SERIAL_PORT_INFO  *UniversalSerialPort;
 
-  PcdSet64S (PcdBootloaderParameter, BootloaderParameter);
+  Status = PcdSet64S (PcdBootloaderParameter, BootloaderParameter);
+  ASSERT_EFI_ERROR (Status);
+
   // Initialize floating point operating environment to be compliant with UEFI spec.
   InitializeFloatingPointUnits ();
 
-- 
2.32.0.windows.2



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#82087): https://edk2.groups.io/g/devel/message/82087
Mute This Topic: https://groups.io/mt/86332763/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [edk2-devel] [`edk2-devel][PATCH V2] UefiPayloadPkg: Fix the build issue for coreboot
Posted by Ni, Ray 2 years, 6 months ago
Reviewed-by: Ray Ni <ray.ni@intel.com>

Thanks,
Ray

-----Original Message-----
From: Dong, Guo <guo.dong@intel.com> 
Sent: Friday, October 15, 2021 1:08 PM
To: devel@edk2.groups.io
Cc: Dong, Guo <guo.dong@intel.com>; Ni, Ray <ray.ni@intel.com>; Ma, Maurice <maurice.ma@intel.com>; You, Benjamin <benjamin.you@intel.com>
Subject: [`edk2-devel][PATCH V2] UefiPayloadPkg: Fix the build issue for coreboot

From: Guo Dong <guo.dong@intel.com>

V2: Fix GCC build issue.

There is typo in previous change caused coreboot build failue.
This patch fixed the build issue.

Cc: Ray Ni <ray.ni@intel.com>
Cc: Maurice Ma <maurice.ma@intel.com>
Cc: Benjamin You <benjamin.you@intel.com>
Signed-off-by: Guo Dong <guo.dong@intel.com>
---
 UefiPayloadPkg/Library/CbParseLib/CbParseLib.c     | 4 ++--
 UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c | 4 +++-
 2 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/UefiPayloadPkg/Library/CbParseLib/CbParseLib.c b/UefiPayloadPkg/Library/CbParseLib/CbParseLib.c
index f81aa0f301..4be5d66ba5 100644
--- a/UefiPayloadPkg/Library/CbParseLib/CbParseLib.c
+++ b/UefiPayloadPkg/Library/CbParseLib/CbParseLib.c
@@ -194,8 +194,8 @@ GetParameterBase (
     return NULL;

   }

 

-  PcdSet64S (PcdBootloaderParameter, (UINTN)CbTablePtr);

-  ASSERT_EFI_STATUS (Status);

+  Status = PcdSet64S (PcdBootloaderParameter, (UINTN)CbTablePtr);

+  ASSERT_EFI_ERROR (Status);

 

   return CbTablePtr;

 }

diff --git a/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c b/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c
index 5a1e578668..0e6dcf10f9 100644
--- a/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c
+++ b/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c
@@ -406,7 +406,9 @@ _ModuleEntryPoint (
   SERIAL_PORT_INFO              SerialPortInfo;

   UNIVERSAL_PAYLOAD_SERIAL_PORT_INFO  *UniversalSerialPort;

 

-  PcdSet64S (PcdBootloaderParameter, BootloaderParameter);

+  Status = PcdSet64S (PcdBootloaderParameter, BootloaderParameter);

+  ASSERT_EFI_ERROR (Status);

+

   // Initialize floating point operating environment to be compliant with UEFI spec.

   InitializeFloatingPointUnits ();

 

-- 
2.32.0.windows.2



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#82092): https://edk2.groups.io/g/devel/message/82092
Mute This Topic: https://groups.io/mt/86332763/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [edk2-devel] [`edk2-devel][PATCH V2] UefiPayloadPkg: Fix the build issue for coreboot
Posted by Ma, Maurice 2 years, 6 months ago
There is a typo ' failue' in the commit message.   Other than that, looks good.

Reviewed-by: Maurice Ma <maurice.ma@intel.com>

> -----Original Message-----
> From: Dong, Guo <guo.dong@intel.com>
> Sent: Thursday, October 14, 2021 22:08
> To: devel@edk2.groups.io
> Cc: Dong, Guo <guo.dong@intel.com>; Ni, Ray <ray.ni@intel.com>; Ma,
> Maurice <maurice.ma@intel.com>; You, Benjamin
> <benjamin.you@intel.com>
> Subject: [`edk2-devel][PATCH V2] UefiPayloadPkg: Fix the build issue for
> coreboot
> 
> From: Guo Dong <guo.dong@intel.com>
> 
> V2: Fix GCC build issue.
> 
> There is typo in previous change caused coreboot build failue.
> This patch fixed the build issue.
> 
> Cc: Ray Ni <ray.ni@intel.com>
> Cc: Maurice Ma <maurice.ma@intel.com>
> Cc: Benjamin You <benjamin.you@intel.com>
> Signed-off-by: Guo Dong <guo.dong@intel.com>
> ---
>  UefiPayloadPkg/Library/CbParseLib/CbParseLib.c     | 4 ++--
>  UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c | 4 +++-
>  2 files changed, 5 insertions(+), 3 deletions(-)
> 
> diff --git a/UefiPayloadPkg/Library/CbParseLib/CbParseLib.c
> b/UefiPayloadPkg/Library/CbParseLib/CbParseLib.c
> index f81aa0f301..4be5d66ba5 100644
> --- a/UefiPayloadPkg/Library/CbParseLib/CbParseLib.c
> +++ b/UefiPayloadPkg/Library/CbParseLib/CbParseLib.c
> @@ -194,8 +194,8 @@ GetParameterBase (
>      return NULL;
> 
>    }
> 
> 
> 
> -  PcdSet64S (PcdBootloaderParameter, (UINTN)CbTablePtr);
> 
> -  ASSERT_EFI_STATUS (Status);
> 
> +  Status = PcdSet64S (PcdBootloaderParameter, (UINTN)CbTablePtr);
> 
> +  ASSERT_EFI_ERROR (Status);
> 
> 
> 
>    return CbTablePtr;
> 
>  }
> 
> diff --git a/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c
> b/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c
> index 5a1e578668..0e6dcf10f9 100644
> --- a/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c
> +++ b/UefiPayloadPkg/UefiPayloadEntry/UefiPayloadEntry.c
> @@ -406,7 +406,9 @@ _ModuleEntryPoint (
>    SERIAL_PORT_INFO              SerialPortInfo;
> 
>    UNIVERSAL_PAYLOAD_SERIAL_PORT_INFO  *UniversalSerialPort;
> 
> 
> 
> -  PcdSet64S (PcdBootloaderParameter, BootloaderParameter);
> 
> +  Status = PcdSet64S (PcdBootloaderParameter, BootloaderParameter);
> 
> +  ASSERT_EFI_ERROR (Status);
> 
> +
> 
>    // Initialize floating point operating environment to be compliant with UEFI
> spec.
> 
>    InitializeFloatingPointUnits ();
> 
> 
> 
> --
> 2.32.0.windows.2



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#82135): https://edk2.groups.io/g/devel/message/82135
Mute This Topic: https://groups.io/mt/86332763/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-