public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Gao, Zhichao" <zhichao.gao@intel.com>
To: "devel@edk2.groups.io" <devel@edk2.groups.io>,
	"lersek@redhat.com" <lersek@redhat.com>
Cc: Bret Barkelew <Bret.Barkelew@microsoft.com>,
	"Wang, Jian J" <jian.j.wang@intel.com>,
	"Wu, Hao A" <hao.a.wu@intel.com>, "Ni, Ray" <ray.ni@intel.com>,
	"Zeng, Star" <star.zeng@intel.com>,
	"Gao, Liming" <liming.gao@intel.com>,
	Sean Brogan <sean.brogan@microsoft.com>,
	"Michael Turner" <Michael.Turner@microsoft.com>
Subject: Re: [edk2-devel] [PATCH] MdeModulePkg/PeiMain: Substantial change for PeiAllocatePool
Date: Thu, 13 Jun 2019 00:32:08 +0000	[thread overview]
Message-ID: <3CE959C139B4C44DBEA1810E3AA6F9000B7F2FE3@SHSMSX101.ccr.corp.intel.com> (raw)
In-Reply-To: <5d2aa3bd-1acc-7048-7675-e3e9da217415@redhat.com>

Thanks for the comments.
Your example makes the purpose clear. I would update the subject like that.

Thanks,
Zhichao

> -----Original Message-----
> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
> Laszlo Ersek
> Sent: Wednesday, June 12, 2019 4:34 PM
> To: devel@edk2.groups.io; Gao, Zhichao <zhichao.gao@intel.com>
> Cc: Bret Barkelew <Bret.Barkelew@microsoft.com>; Wang, Jian J
> <jian.j.wang@intel.com>; Wu, Hao A <hao.a.wu@intel.com>; Ni, Ray
> <ray.ni@intel.com>; Zeng, Star <star.zeng@intel.com>; Gao, Liming
> <liming.gao@intel.com>; Sean Brogan <sean.brogan@microsoft.com>;
> Michael Turner <Michael.Turner@microsoft.com>
> Subject: Re: [edk2-devel] [PATCH] MdeModulePkg/PeiMain: Substantial
> change for PeiAllocatePool
> 
> Hi Zhichao,
> 
> On 06/12/19 06:50, Gao, Zhichao wrote:
> > From: Bret Barkelew <Bret.Barkelew@microsoft.com>
> >
> > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1901
> >
> > The original logic is ASSERT if fail to create HOB. But that doesn't
> > make sense for release version. So it is required to set the Buffer to
> > null to indicate the failure.
> 
> this patch may or may not be worthwhile; that's for the PEI Core maintainers
> to evaluate.
> 
> Either way, the subject line is completely useless. "Substantial change"
> means nothing at all. Please write a subject line that reflects what this patch
> *actually does*.
> 
> For example:
> 
> MdeModulePkg/PeiMain: PeiAllocatePool: output NULL if HOB creation fails
> 
> (72 characters).
> 
> Thanks
> Laszlo
> 
> > Cc: Jian J Wang <jian.j.wang@intel.com>
> > Cc: Hao Wu <hao.a.wu@intel.com>
> > Cc: Ray Ni <ray.ni@intel.com>
> > Cc: Star Zeng <star.zeng@intel.com>
> > Cc: Liming Gao <liming.gao@intel.com>
> > Cc: Sean Brogan <sean.brogan@microsoft.com>
> > Cc: Michael Turner <Michael.Turner@microsoft.com>
> > Cc: Bret Barkelew <Bret.Barkelew@microsoft.com>
> > Signed-off-by: Zhichao Gao <zhichao.gao@intel.com>
> > ---
> >  MdeModulePkg/Core/Pei/Memory/MemoryServices.c | 7 ++++++-
> >  1 file changed, 6 insertions(+), 1 deletion(-)
> >
> > diff --git a/MdeModulePkg/Core/Pei/Memory/MemoryServices.c
> > b/MdeModulePkg/Core/Pei/Memory/MemoryServices.c
> > index 42f79ab076..37b0cfa3cf 100644
> > --- a/MdeModulePkg/Core/Pei/Memory/MemoryServices.c
> > +++ b/MdeModulePkg/Core/Pei/Memory/MemoryServices.c
> > @@ -802,7 +802,12 @@ PeiAllocatePool (
> >               (VOID **)&Hob
> >               );
> >    ASSERT_EFI_ERROR (Status);
> > -  *Buffer = Hob+1;
> > +
> > +  if (EFI_ERROR (Status)) {
> > +    *Buffer = NULL;
> > +  } else {
> > +    *Buffer = Hob+1;
> > +  }
> >
> >    return Status;
> >  }
> >
> 
> 
> 


  reply	other threads:[~2019-06-13  0:32 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-12  4:50 [PATCH] MdeModulePkg/PeiMain: Substantial change for PeiAllocatePool Gao, Zhichao
2019-06-12  8:33 ` [edk2-devel] " Laszlo Ersek
2019-06-13  0:32   ` Gao, Zhichao [this message]
2019-06-18  5:14   ` Wu, Hao A
2019-06-18  5:16     ` Liming Gao
2019-06-24  2:20       ` Wu, Hao A

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=3CE959C139B4C44DBEA1810E3AA6F9000B7F2FE3@SHSMSX101.ccr.corp.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