public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [PATCH] CoffeelakeSiliconPkg: Add a needed ZeroMem ()
@ 2019-08-29 23:00 Nate DeSimone
  2019-08-29 23:15 ` [edk2-devel] " Kubacki, Michael A
  0 siblings, 1 reply; 3+ messages in thread
From: Nate DeSimone @ 2019-08-29 23:00 UTC (permalink / raw)
  To: devel; +Cc: Chasel Chiu, Michael Kubacki, Sai Chaganty

AddComponentConfigBlocks () should ZeroMem () the Config Block Header before using it.

Cc: Chasel Chiu <chasel.chiu@intel.com>
Cc: Michael Kubacki <michael.a.kubacki@intel.com>
Cc: Sai Chaganty <rangasai.v.chaganty@intel.com>
Signed-off-by: Nate DeSimone <nathaniel.l.desimone@intel.com>
---
 .../Library/BaseSiConfigBlockLib/BaseSiConfigBlockLib.c          | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseSiConfigBlockLib/BaseSiConfigBlockLib.c b/Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseSiConfigBlockLib/BaseSiConfigBlockLib.c
index 16a14b3245..3c02a4563c 100644
--- a/Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseSiConfigBlockLib/BaseSiConfigBlockLib.c
+++ b/Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseSiConfigBlockLib/BaseSiConfigBlockLib.c
@@ -75,6 +75,7 @@ AddComponentConfigBlocks (
   // Loop to identify each config block from ComponentBlocks[] Table and add each of them
   //
   for (BlockCount = 0 ; BlockCount < TotalBlockCount; BlockCount++) {
+    ZeroMem (&ConfigBlockBuf, sizeof (CONFIG_BLOCK));
     CopyMem (&(ConfigBlockBuf.Header.GuidHob.Name), ComponentBlocks[BlockCount].Guid, sizeof (EFI_GUID));
     ConfigBlockBuf.Header.GuidHob.Header.HobLength = ComponentBlocks[BlockCount].Size;
     ConfigBlockBuf.Header.Revision        = ComponentBlocks[BlockCount].Revision;
-- 
2.17.1.windows.2


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

* Re: [edk2-devel] [PATCH] CoffeelakeSiliconPkg: Add a needed ZeroMem ()
  2019-08-29 23:00 [PATCH] CoffeelakeSiliconPkg: Add a needed ZeroMem () Nate DeSimone
@ 2019-08-29 23:15 ` Kubacki, Michael A
  2019-08-30 12:39   ` Chiu, Chasel
  0 siblings, 1 reply; 3+ messages in thread
From: Kubacki, Michael A @ 2019-08-29 23:15 UTC (permalink / raw)
  To: devel@edk2.groups.io, Desimone, Nathaniel L
  Cc: Chiu, Chasel, Chaganty, Rangasai V

In the future, the subject should include [edk2-platforms] for patches in the repo.

Reviewed-by: Michael Kubacki <michael.a.kubacki@intel.com>

> -----Original Message-----
> From: devel@edk2.groups.io <devel@edk2.groups.io> On Behalf Of Nate
> DeSimone
> Sent: Thursday, August 29, 2019 4:00 PM
> To: devel@edk2.groups.io
> Cc: Chiu, Chasel <chasel.chiu@intel.com>; Kubacki, Michael A
> <michael.a.kubacki@intel.com>; Chaganty, Rangasai V
> <rangasai.v.chaganty@intel.com>
> Subject: [edk2-devel] [PATCH] CoffeelakeSiliconPkg: Add a needed
> ZeroMem ()
> 
> AddComponentConfigBlocks () should ZeroMem () the Config Block Header
> before using it.
> 
> Cc: Chasel Chiu <chasel.chiu@intel.com>
> Cc: Michael Kubacki <michael.a.kubacki@intel.com>
> Cc: Sai Chaganty <rangasai.v.chaganty@intel.com>
> Signed-off-by: Nate DeSimone <nathaniel.l.desimone@intel.com>
> ---
>  .../Library/BaseSiConfigBlockLib/BaseSiConfigBlockLib.c          | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git
> a/Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseSiConfigBlockLib/BaseSiCon
> figBlockLib.c
> b/Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseSiConfigBlockLib/BaseSiCon
> figBlockLib.c
> index 16a14b3245..3c02a4563c 100644
> ---
> a/Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseSiConfigBlockLib/BaseSiCon
> figBlockLib.c
> +++
> b/Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseSiConfigBlockLib/BaseSiCon
> figBlockLib.c
> @@ -75,6 +75,7 @@ AddComponentConfigBlocks (
>    // Loop to identify each config block from ComponentBlocks[] Table and
> add each of them
>    //
>    for (BlockCount = 0 ; BlockCount < TotalBlockCount; BlockCount++) {
> +    ZeroMem (&ConfigBlockBuf, sizeof (CONFIG_BLOCK));
>      CopyMem (&(ConfigBlockBuf.Header.GuidHob.Name),
> ComponentBlocks[BlockCount].Guid, sizeof (EFI_GUID));
>      ConfigBlockBuf.Header.GuidHob.Header.HobLength =
> ComponentBlocks[BlockCount].Size;
>      ConfigBlockBuf.Header.Revision        =
> ComponentBlocks[BlockCount].Revision;
> --
> 2.17.1.windows.2
> 
> 
> 


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

* Re: [edk2-devel] [PATCH] CoffeelakeSiliconPkg: Add a needed ZeroMem ()
  2019-08-29 23:15 ` [edk2-devel] " Kubacki, Michael A
@ 2019-08-30 12:39   ` Chiu, Chasel
  0 siblings, 0 replies; 3+ messages in thread
From: Chiu, Chasel @ 2019-08-30 12:39 UTC (permalink / raw)
  To: Kubacki, Michael A, devel@edk2.groups.io, Desimone, Nathaniel L
  Cc: Chaganty, Rangasai V


Reviewed-by: Chasel Chiu <chasel.chiu@intel.com>

> -----Original Message-----
> From: Kubacki, Michael A
> Sent: Friday, August 30, 2019 7:16 AM
> To: devel@edk2.groups.io; Desimone, Nathaniel L
> <nathaniel.l.desimone@intel.com>
> Cc: Chiu, Chasel <chasel.chiu@intel.com>; Chaganty, Rangasai V
> <rangasai.v.chaganty@intel.com>
> Subject: RE: [edk2-devel] [PATCH] CoffeelakeSiliconPkg: Add a needed
> ZeroMem ()
> 
> In the future, the subject should include [edk2-platforms] for patches in the
> repo.
> 
> Reviewed-by: Michael Kubacki <michael.a.kubacki@intel.com>
> 
> > -----Original Message-----
> > From: devel@edk2.groups.io <devel@edk2.groups.io> On Behalf Of Nate
> > DeSimone
> > Sent: Thursday, August 29, 2019 4:00 PM
> > To: devel@edk2.groups.io
> > Cc: Chiu, Chasel <chasel.chiu@intel.com>; Kubacki, Michael A
> > <michael.a.kubacki@intel.com>; Chaganty, Rangasai V
> > <rangasai.v.chaganty@intel.com>
> > Subject: [edk2-devel] [PATCH] CoffeelakeSiliconPkg: Add a needed
> > ZeroMem ()
> >
> > AddComponentConfigBlocks () should ZeroMem () the Config Block Header
> > before using it.
> >
> > Cc: Chasel Chiu <chasel.chiu@intel.com>
> > Cc: Michael Kubacki <michael.a.kubacki@intel.com>
> > Cc: Sai Chaganty <rangasai.v.chaganty@intel.com>
> > Signed-off-by: Nate DeSimone <nathaniel.l.desimone@intel.com>
> > ---
> >  .../Library/BaseSiConfigBlockLib/BaseSiConfigBlockLib.c          | 1 +
> >  1 file changed, 1 insertion(+)
> >
> > diff --git
> > a/Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseSiConfigBlockLib/Base
> > SiCon
> > figBlockLib.c
> > b/Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseSiConfigBlockLib/Base
> > SiCon
> > figBlockLib.c
> > index 16a14b3245..3c02a4563c 100644
> > ---
> > a/Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseSiConfigBlockLib/Base
> > SiCon
> > figBlockLib.c
> > +++
> > b/Silicon/Intel/CoffeelakeSiliconPkg/Library/BaseSiConfigBlockLib/Base
> > SiCon
> > figBlockLib.c
> > @@ -75,6 +75,7 @@ AddComponentConfigBlocks (
> >    // Loop to identify each config block from ComponentBlocks[] Table
> > and add each of them
> >    //
> >    for (BlockCount = 0 ; BlockCount < TotalBlockCount; BlockCount++) {
> > +    ZeroMem (&ConfigBlockBuf, sizeof (CONFIG_BLOCK));
> >      CopyMem (&(ConfigBlockBuf.Header.GuidHob.Name),
> > ComponentBlocks[BlockCount].Guid, sizeof (EFI_GUID));
> >      ConfigBlockBuf.Header.GuidHob.Header.HobLength =
> > ComponentBlocks[BlockCount].Size;
> >      ConfigBlockBuf.Header.Revision        =
> > ComponentBlocks[BlockCount].Revision;
> > --
> > 2.17.1.windows.2
> >
> >
> > 


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

end of thread, other threads:[~2019-08-30 12:40 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-08-29 23:00 [PATCH] CoffeelakeSiliconPkg: Add a needed ZeroMem () Nate DeSimone
2019-08-29 23:15 ` [edk2-devel] " Kubacki, Michael A
2019-08-30 12:39   ` Chiu, Chasel

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