public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [Patch 0/2] Clean up useless parmeter.
@ 2019-08-08 13:24 Dong, Eric
  2019-08-08 13:24 ` [Patch 1/2] UefiCpuPkg/RegisterCpuFeaturesLib: Clean up useless parameter Dong, Eric
  2019-08-08 13:24 ` [Patch 2/2] UefiCpuPkg/PiSmmCpuDxeSmm: " Dong, Eric
  0 siblings, 2 replies; 5+ messages in thread
From: Dong, Eric @ 2019-08-08 13:24 UTC (permalink / raw)
  To: devel

After commit 02031cfc920e ("UefiCpuPkg/PiSmmCpuDxeSmm: Remove debug
message.", 2019-08-06), RegisterCpuFeaturesLib and PiSmmCpuDxeSmm
are each left with a useless spinlock called "ConsoleLogLock".

This patch serial remove this useless parameter.

Eric Dong (2):
  UefiCpuPkg/RegisterCpuFeaturesLib: Clean up useless parameter.
  UefiCpuPkg/PiSmmCpuDxeSmm: Clean up useless parameter.

 UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeatures.h | 1 -
 .../Library/RegisterCpuFeaturesLib/RegisterCpuFeaturesLib.c     | 1 -
 UefiCpuPkg/PiSmmCpuDxeSmm/CpuS3.c                               | 2 --
 3 files changed, 4 deletions(-)

-- 
2.21.0.windows.1


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Patch 1/2] UefiCpuPkg/RegisterCpuFeaturesLib: Clean up useless parameter.
  2019-08-08 13:24 [Patch 0/2] Clean up useless parmeter Dong, Eric
@ 2019-08-08 13:24 ` Dong, Eric
  2019-08-08 20:15   ` Laszlo Ersek
  2019-08-08 13:24 ` [Patch 2/2] UefiCpuPkg/PiSmmCpuDxeSmm: " Dong, Eric
  1 sibling, 1 reply; 5+ messages in thread
From: Dong, Eric @ 2019-08-08 13:24 UTC (permalink / raw)
  To: devel; +Cc: Ray Ni, Laszlo Ersek

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2060

Remove the useless parameter.

Signed-off-by: Eric Dong <eric.dong@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Laszlo Ersek <lersek@redhat.com>
---
 UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeatures.h  | 1 -
 .../Library/RegisterCpuFeaturesLib/RegisterCpuFeaturesLib.c      | 1 -
 2 files changed, 2 deletions(-)

diff --git a/UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeatures.h b/UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeatures.h
index a25dd69292..7c48b0a645 100644
--- a/UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeatures.h
+++ b/UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeatures.h
@@ -58,7 +58,6 @@ typedef struct {
 // Flags used when program the register.
 //
 typedef struct {
-  volatile UINTN           ConsoleLogLock;          // Spinlock used to control console.
   volatile UINTN           MemoryMappedLock;        // Spinlock used to program mmio
   volatile UINT32          *CoreSemaphoreCount;     // Semaphore containers used to program Core semaphore.
   volatile UINT32          *PackageSemaphoreCount;  // Semaphore containers used to program Package semaphore.
diff --git a/UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeaturesLib.c b/UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeaturesLib.c
index 493566de5d..67885bf69b 100644
--- a/UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeaturesLib.c
+++ b/UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeaturesLib.c
@@ -839,7 +839,6 @@ RegisterCpuFeature (
   if (CpuFeaturesData->FeaturesCount == 0) {
     InitializeListHead (&CpuFeaturesData->FeatureList);
     InitializeSpinLock (&CpuFeaturesData->CpuFlags.MemoryMappedLock);
-    InitializeSpinLock (&CpuFeaturesData->CpuFlags.ConsoleLogLock);
     //
     // Code assumes below three PCDs have PCD same buffer size.
     //
-- 
2.21.0.windows.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [Patch 2/2] UefiCpuPkg/PiSmmCpuDxeSmm: Clean up useless parameter.
  2019-08-08 13:24 [Patch 0/2] Clean up useless parmeter Dong, Eric
  2019-08-08 13:24 ` [Patch 1/2] UefiCpuPkg/RegisterCpuFeaturesLib: Clean up useless parameter Dong, Eric
@ 2019-08-08 13:24 ` Dong, Eric
  2019-08-08 20:15   ` Laszlo Ersek
  1 sibling, 1 reply; 5+ messages in thread
From: Dong, Eric @ 2019-08-08 13:24 UTC (permalink / raw)
  To: devel; +Cc: Ray Ni, Laszlo Ersek

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2060

Remove the useless parameter.

Signed-off-by: Eric Dong <eric.dong@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Laszlo Ersek <lersek@redhat.com>
---
 UefiCpuPkg/PiSmmCpuDxeSmm/CpuS3.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/UefiCpuPkg/PiSmmCpuDxeSmm/CpuS3.c b/UefiCpuPkg/PiSmmCpuDxeSmm/CpuS3.c
index d20bc4aae6..d8c6b19ead 100644
--- a/UefiCpuPkg/PiSmmCpuDxeSmm/CpuS3.c
+++ b/UefiCpuPkg/PiSmmCpuDxeSmm/CpuS3.c
@@ -35,7 +35,6 @@ typedef struct {
 // Flags used when program the register.
 //
 typedef struct {
-  volatile UINTN           ConsoleLogLock;          // Spinlock used to control console.
   volatile UINTN           MemoryMappedLock;        // Spinlock used to program mmio
   volatile UINT32          *CoreSemaphoreCount;     // Semaphore container used to program
                                                     // core level semaphore.
@@ -1028,7 +1027,6 @@ GetAcpiCpuData (
     ASSERT (mCpuFlags.PackageSemaphoreCount != NULL);
   }
   InitializeSpinLock((SPIN_LOCK*) &mCpuFlags.MemoryMappedLock);
-  InitializeSpinLock((SPIN_LOCK*) &mCpuFlags.ConsoleLogLock);
 }
 
 /**
-- 
2.21.0.windows.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [Patch 1/2] UefiCpuPkg/RegisterCpuFeaturesLib: Clean up useless parameter.
  2019-08-08 13:24 ` [Patch 1/2] UefiCpuPkg/RegisterCpuFeaturesLib: Clean up useless parameter Dong, Eric
@ 2019-08-08 20:15   ` Laszlo Ersek
  0 siblings, 0 replies; 5+ messages in thread
From: Laszlo Ersek @ 2019-08-08 20:15 UTC (permalink / raw)
  To: Eric Dong, devel; +Cc: Ray Ni

On 08/08/19 15:24, Eric Dong wrote:
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2060
> 
> Remove the useless parameter.
> 
> Signed-off-by: Eric Dong <eric.dong@intel.com>
> Cc: Ray Ni <ray.ni@intel.com>
> Cc: Laszlo Ersek <lersek@redhat.com>
> ---
>  UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeatures.h  | 1 -
>  .../Library/RegisterCpuFeaturesLib/RegisterCpuFeaturesLib.c      | 1 -
>  2 files changed, 2 deletions(-)
> 
> diff --git a/UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeatures.h b/UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeatures.h
> index a25dd69292..7c48b0a645 100644
> --- a/UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeatures.h
> +++ b/UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeatures.h
> @@ -58,7 +58,6 @@ typedef struct {
>  // Flags used when program the register.
>  //
>  typedef struct {
> -  volatile UINTN           ConsoleLogLock;          // Spinlock used to control console.
>    volatile UINTN           MemoryMappedLock;        // Spinlock used to program mmio
>    volatile UINT32          *CoreSemaphoreCount;     // Semaphore containers used to program Core semaphore.
>    volatile UINT32          *PackageSemaphoreCount;  // Semaphore containers used to program Package semaphore.
> diff --git a/UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeaturesLib.c b/UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeaturesLib.c
> index 493566de5d..67885bf69b 100644
> --- a/UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeaturesLib.c
> +++ b/UefiCpuPkg/Library/RegisterCpuFeaturesLib/RegisterCpuFeaturesLib.c
> @@ -839,7 +839,6 @@ RegisterCpuFeature (
>    if (CpuFeaturesData->FeaturesCount == 0) {
>      InitializeListHead (&CpuFeaturesData->FeatureList);
>      InitializeSpinLock (&CpuFeaturesData->CpuFlags.MemoryMappedLock);
> -    InitializeSpinLock (&CpuFeaturesData->CpuFlags.ConsoleLogLock);
>      //
>      // Code assumes below three PCDs have PCD same buffer size.
>      //
> 

Please replace "useless parameter" in the subject and in the commit
message body also, with "useless ConsoleLogLock spinlock".

With that:

Reviewed-by: Laszlo Ersek <lersek@redhat.com>


Thanks
Laszlo

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [Patch 2/2] UefiCpuPkg/PiSmmCpuDxeSmm: Clean up useless parameter.
  2019-08-08 13:24 ` [Patch 2/2] UefiCpuPkg/PiSmmCpuDxeSmm: " Dong, Eric
@ 2019-08-08 20:15   ` Laszlo Ersek
  0 siblings, 0 replies; 5+ messages in thread
From: Laszlo Ersek @ 2019-08-08 20:15 UTC (permalink / raw)
  To: Eric Dong, devel; +Cc: Ray Ni

On 08/08/19 15:24, Eric Dong wrote:
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2060
> 
> Remove the useless parameter.
> 
> Signed-off-by: Eric Dong <eric.dong@intel.com>
> Cc: Ray Ni <ray.ni@intel.com>
> Cc: Laszlo Ersek <lersek@redhat.com>
> ---
>  UefiCpuPkg/PiSmmCpuDxeSmm/CpuS3.c | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/UefiCpuPkg/PiSmmCpuDxeSmm/CpuS3.c b/UefiCpuPkg/PiSmmCpuDxeSmm/CpuS3.c
> index d20bc4aae6..d8c6b19ead 100644
> --- a/UefiCpuPkg/PiSmmCpuDxeSmm/CpuS3.c
> +++ b/UefiCpuPkg/PiSmmCpuDxeSmm/CpuS3.c
> @@ -35,7 +35,6 @@ typedef struct {
>  // Flags used when program the register.
>  //
>  typedef struct {
> -  volatile UINTN           ConsoleLogLock;          // Spinlock used to control console.
>    volatile UINTN           MemoryMappedLock;        // Spinlock used to program mmio
>    volatile UINT32          *CoreSemaphoreCount;     // Semaphore container used to program
>                                                      // core level semaphore.
> @@ -1028,7 +1027,6 @@ GetAcpiCpuData (
>      ASSERT (mCpuFlags.PackageSemaphoreCount != NULL);
>    }
>    InitializeSpinLock((SPIN_LOCK*) &mCpuFlags.MemoryMappedLock);
> -  InitializeSpinLock((SPIN_LOCK*) &mCpuFlags.ConsoleLogLock);
>  }
>  
>  /**
> 

Same comment as for patch #1. With that fixed:

Reviewed-by: Laszlo Ersek <lersek@redhat.com>

Thanks!
Laszlo

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-08-08 20:15 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-08-08 13:24 [Patch 0/2] Clean up useless parmeter Dong, Eric
2019-08-08 13:24 ` [Patch 1/2] UefiCpuPkg/RegisterCpuFeaturesLib: Clean up useless parameter Dong, Eric
2019-08-08 20:15   ` Laszlo Ersek
2019-08-08 13:24 ` [Patch 2/2] UefiCpuPkg/PiSmmCpuDxeSmm: " Dong, Eric
2019-08-08 20:15   ` Laszlo Ersek

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox