public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Ni, Ray" <ray.ni@intel.com>
To: "Gao, Liming" <liming.gao@intel.com>,
	"devel@edk2.groups.io" <devel@edk2.groups.io>
Cc: "Voelz, Jason" <jason.voelz@intel.com>
Subject: Re: [Patch 2/2] UefiCpuPkg/CpuCommonFeaturesLib: SMXE bit of CR4 should set
Date: Wed, 8 Jan 2020 14:12:21 +0000	[thread overview]
Message-ID: <734D49CCEBEEF84792F5B80ED585239D5C3E0248@SHSMSX104.ccr.corp.intel.com> (raw)
In-Reply-To: <20191223065537.32468-3-liming.gao@intel.com>

Reviewed-by: Ray Ni <ray.ni@intel.com>

> -----Original Message-----
> From: Gao, Liming <liming.gao@intel.com>
> Sent: Monday, December 23, 2019 2:56 PM
> To: devel@edk2.groups.io
> Cc: Voelz, Jason <jason.voelz@intel.com>; Ni, Ray <ray.ni@intel.com>
> Subject: [Patch 2/2] UefiCpuPkg/CpuCommonFeaturesLib: SMXE bit of CR4 should set
> 
> From: Jason Voelz <jason.voelz@intel.com>
> 
> Add code to set SMXE in CR4 in the SmxInitialize flow when SMX is enabled.
> 
> Signed-off-by: Jason Voelz <jason.voelz@intel.com>
> Cc: Ray Ni <ray.ni@intel.com>
> ---
>  UefiCpuPkg/Library/CpuCommonFeaturesLib/FeatureControl.c | 9 +++++++++
>  1 file changed, 9 insertions(+)
> 
> diff --git a/UefiCpuPkg/Library/CpuCommonFeaturesLib/FeatureControl.c
> b/UefiCpuPkg/Library/CpuCommonFeaturesLib/FeatureControl.c
> index 38d3f53f56..b4474d2fab 100644
> --- a/UefiCpuPkg/Library/CpuCommonFeaturesLib/FeatureControl.c
> +++ b/UefiCpuPkg/Library/CpuCommonFeaturesLib/FeatureControl.c
> @@ -240,6 +240,15 @@ SmxInitialize (
>      Status = RETURN_UNSUPPORTED;
>    }
> 
> +  CPU_REGISTER_TABLE_WRITE_FIELD (
> +    ProcessorNumber,
> +    ControlRegister,
> +    4,
> +    IA32_CR4,
> +    Bits.SMXE,
> +    (State) ? 1 : 0
> +  )
> +
>    CPU_REGISTER_TABLE_TEST_THEN_WRITE_FIELD (
>      ProcessorNumber,
>      Msr,
> --
> 2.13.0.windows.1


      reply	other threads:[~2020-01-08 14:12 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-23  6:55 [Patch 0/2] UefiCpuPkg/CpuCommonFeaturesLib: Set SMXE bit of CR4 when SMX is enabled Liming Gao
2019-12-23  6:55 ` [Patch 1/2] MdePkg BaseLib.h: Update IA32_CR4 strut to include all public fields Liming Gao
2020-01-08 14:12   ` Ni, Ray
2019-12-23  6:55 ` [Patch 2/2] UefiCpuPkg/CpuCommonFeaturesLib: SMXE bit of CR4 should set Liming Gao
2020-01-08 14:12   ` Ni, Ray [this message]

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=734D49CCEBEEF84792F5B80ED585239D5C3E0248@SHSMSX104.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