public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Gao, Zhichao" <zhichao.gao@intel.com>
To: devel@edk2.groups.io
Cc: Jiewen Yao <jiewen.yao@intel.com>,
	Chao Zhang <chao.b.zhang@intel.com>,
	Jian J Wang <jian.j.wang@intel.com>, Hao Wu <hao.a.wu@intel.com>,
	Ray Ni <ray.ni@intel.com>, Star Zeng <star.zeng@intel.com>,
	Michael D Kinney <michael.d.kinney@intel.com>,
	Liming Gao <liming.gao@intel.com>,
	Sean Brogan <sean.brogan@microsoft.com>,
	Michael Turner <Michael.Turner@microsoft.com>,
	Bret Barkelew <Bret.Barkelew@microsoft.com>
Subject: [PATCH V2 0/5] Make some DebugLib instance runtime safe
Date: Fri, 12 Apr 2019 08:42:26 +0800	[thread overview]
Message-ID: <20190412004231.17280-1-zhichao.gao@intel.com> (raw)

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

Some pointer will be invalid after ExitBootServices, such as protocol pointer,
gST, gBS and so on. Disable the functions which used that pointer.

Remove SMM support of UefiDebugLibDebugPortProtocol, UefidebugLibConOut
and UefiDebugLibStdErr.
Before removing, should change the SMM instance in the dsc file which use
them as SMM instance. And null version is safe.

V2:
Fix some typos.
Change the comment of function to meet the Doxygen rule.

Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Chao Zhang <chao.b.zhang@intel.com>
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: Michael D Kinney <michael.d.kinney@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>

Aaron Antone (3):
  MdePkg/UefiDebugLibDebugPortProtocol: Make it runtime safe
  MdePkg/UefidebugLibConOut: Make it runtime safe
  MdePkg/UefiDebugLibStdErr: Make it runtime safe

Zhichao Gao (2):
  MdeModulePkg: Change the SMM debug lib instance
  SignedCapsulePkg: Change the SMM debug lib instance

 MdeModulePkg/MdeModulePkg.dsc                 |   2 +-
 MdePkg/Library/UefiDebugLibConOut/DebugLib.c  | 116 +++++++-------
 .../UefiDebugLibConOut/DebugLibConstructor.c  |  77 +++++++++
 .../UefiDebugLibConOut/UefiDebugLibConOut.inf |  12 +-
 .../UefiDebugLibDebugPortProtocol/DebugLib.c  | 146 +++++++++---------
 .../DebugLibConstructor.c                     |  77 +++++++++
 .../UefiDebugLibDebugPortProtocol.inf         |  12 +-
 MdePkg/Library/UefiDebugLibStdErr/DebugLib.c  | 113 +++++++-------
 .../UefiDebugLibStdErr/DebugLibConstructor.c  |  77 +++++++++
 .../UefiDebugLibStdErr/UefiDebugLibStdErr.inf |  12 +-
 SignedCapsulePkg/SignedCapsulePkg.dsc         |   4 +-
 11 files changed, 458 insertions(+), 190 deletions(-)
 create mode 100644 MdePkg/Library/UefiDebugLibConOut/DebugLibConstructor.c
 create mode 100644 MdePkg/Library/UefiDebugLibDebugPortProtocol/DebugLibConstructor.c
 create mode 100644 MdePkg/Library/UefiDebugLibStdErr/DebugLibConstructor.c

-- 
2.21.0.windows.1


             reply	other threads:[~2019-04-12  0:42 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-12  0:42 Gao, Zhichao [this message]
2019-04-12  0:42 ` [PATCH V2 1/5] MdeModulePkg: Change the SMM debug lib instance Gao, Zhichao
2019-04-12  0:42 ` [PATCH V2 2/5] SignedCapsulePkg: " Gao, Zhichao
2019-04-12  0:42 ` [PATCH V2 3/5] MdePkg/UefiDebugLibDebugPortProtocol: Make it runtime safe Gao, Zhichao
2019-04-12  0:42 ` [PATCH V2 4/5] MdePkg/UefidebugLibConOut: " Gao, Zhichao
2019-04-12  0:42 ` [PATCH V2 5/5] MdePkg/UefiDebugLibStdErr: " Gao, Zhichao
2019-04-17  1:24 ` [PATCH V2 0/5] Make some DebugLib instance " Liming Gao

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=20190412004231.17280-1-zhichao.gao@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