From: "Yao, Jiewen" <jiewen.yao@intel.com>
To: "Gonzalez Del Cueto,
Rodrigo" <rodrigo.gonzalez.del.cueto@intel.com>,
"edk2-devel@lists.01.org" <edk2-devel@lists.01.org>
Cc: "Zhang, Chao B" <chao.b.zhang@intel.com>
Subject: Re: [PATCH] SecurityPkg/TcgConfigDxe: Allow enabling TPM 1.2 device from disabled state.
Date: Wed, 20 Feb 2019 03:12:15 +0000 [thread overview]
Message-ID: <74D8A39837DF1E4DA445A8C0B3885C503F5190C2@shsmsx102.ccr.corp.intel.com> (raw)
In-Reply-To: <20190204060657.38860-1-rodrigo.gonzalez.del.cueto@intel.com>
Thanks for the enhancement.
Reviewed-by: Jiewen.yao@intel.com
> -----Original Message-----
> From: Gonzalez Del Cueto, Rodrigo
> Sent: Monday, February 4, 2019 2:07 PM
> To: edk2-devel@lists.01.org
> Cc: Gonzalez Del Cueto, Rodrigo <rodrigo.gonzalez.del.cueto@intel.com>;
> Zhang, Chao B <chao.b.zhang@intel.com>; Yao, Jiewen
> <jiewen.yao@intel.com>
> Subject: [PATCH] SecurityPkg/TcgConfigDxe: Allow enabling TPM 1.2 device
> from disabled state.
>
> BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=1511
>
> Currently the TCG config setup form defaults the physical presence action to
> PHYSICAL_PRESENCE_ENABLE, this prevents the action from being called.
> When a TPM
> 1.2 device is in Disabled and Activated state it is not possible to issue the
> PHYSICAL_PRESENCE_ENABLE using the menu action.
>
> By having the form default to PHYSICAL_PRESENCE_NO_ACTION, the user is
> now able
> to select PHYSICAL_PRESENCE_ENABLE and toggle the TPM 1.2 device
> enable state.
>
> Contributed-under: TianoCore Contribution Agreement 1.1
>
> Signed-off-by: Rodrigo Gonzalez del Cueto
> <rodrigo.gonzalez.del.cueto@intel.com>
> Cc: Chao Zhang <chao.b.zhang@intel.com>
> Cc: Jiewen Yao <jiewen.yao@intel.com>
> ---
> SecurityPkg/Tcg/TcgConfigDxe/TcgConfig.vfr | 8 ++++++--
> SecurityPkg/Tcg/TcgConfigDxe/TcgConfigImpl.c | 4 ++--
> SecurityPkg/Tcg/TcgConfigDxe/TcgConfigStrings.uni | 3 ++-
> 3 files changed, 10 insertions(+), 5 deletions(-)
>
> diff --git a/SecurityPkg/Tcg/TcgConfigDxe/TcgConfig.vfr
> b/SecurityPkg/Tcg/TcgConfigDxe/TcgConfig.vfr
> index b0a7bf6f47..1047475cef 100644
> --- a/SecurityPkg/Tcg/TcgConfigDxe/TcgConfig.vfr
> +++ b/SecurityPkg/Tcg/TcgConfigDxe/TcgConfig.vfr
> @@ -1,7 +1,7 @@
> /** @file
> VFR file used by the TCG configuration component.
>
> -Copyright (c) 2011 - 2018, Intel Corporation. All rights reserved.<BR>
> +Copyright (c) 2011 - 2019, Intel Corporation. All rights reserved.<BR>
> This program and the accompanying materials
> are licensed and made available under the terms and conditions of the BSD
> License
> which accompanies this distribution. The full text of the license may be
> found at
> @@ -43,6 +43,10 @@ formset
> help = STRING_TOKEN(STR_TPM_OPERATION_HELP),
> flags = INTERACTIVE | RESET_REQUIRED,
> //
> + // Default the form to NO ACTION to allow toggling other
> options
> + //
> + option text = STRING_TOKEN(STR_NO_ACTION), value =
> PHYSICAL_PRESENCE_NO_ACTION, flags = DEFAULT;
> + //
> // Disable (TPM_ORD_PhysicalDisable) command is not
> available when disabled.
> // Activate/deactivate (TPM_ORD_physicalSetDeactivated)
> command is not available when disabled.
> //
> @@ -61,7 +65,7 @@ formset
> option text =
> STRING_TOKEN(STR_TPM_CLEAR_ENABLE_ACTIVATE), value =
> PHYSICAL_PRESENCE_CLEAR_ENABLE_ACTIVATE, flags = 0;
> endif
>
> - option text = STRING_TOKEN(STR_ENABLE), value =
> PHYSICAL_PRESENCE_ENABLE, flags = DEFAULT;
> + option text = STRING_TOKEN(STR_ENABLE), value =
> PHYSICAL_PRESENCE_ENABLE, flags = 0;
> option text = STRING_TOKEN(STR_TPM_ENABLE_ACTIVATE),
> value = PHYSICAL_PRESENCE_ENABLE_ACTIVATE, flags = 0;
> option text =
> STRING_TOKEN(STR_TPM_ENABLE_ACTIVATE_CLEAR), value =
> PHYSICAL_PRESENCE_ENABLE_ACTIVATE_CLEAR, flags = 0;
> option text =
> STRING_TOKEN(STR_TPM_ENABLE_ACTIVATE_CLEAR_E_A), value =
> PHYSICAL_PRESENCE_ENABLE_ACTIVATE_CLEAR_ENABLE_ACTIVATE, flags
> = 0;
> diff --git a/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigImpl.c
> b/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigImpl.c
> index a306bbbb5c..4455fd2b48 100644
> --- a/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigImpl.c
> +++ b/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigImpl.c
> @@ -1,7 +1,7 @@
> /** @file
> HII Config Access protocol implementation of TCG configuration module.
>
> -Copyright (c) 2011 - 2018, Intel Corporation. All rights reserved.<BR>
> +Copyright (c) 2011 - 2019, Intel Corporation. All rights reserved.<BR>
> This program and the accompanying materials
> are licensed and made available under the terms and conditions of the BSD
> License
> which accompanies this distribution. The full text of the license may be
> found at
> @@ -176,7 +176,7 @@ TcgExtractConfig (
> //
> // Convert buffer data to <ConfigResp> by helper function
> BlockToConfig()
> //
> - PrivateData->Configuration->TpmOperation =
> PHYSICAL_PRESENCE_ENABLE;
> + PrivateData->Configuration->TpmOperation =
> PHYSICAL_PRESENCE_NO_ACTION;
>
> //
> // Get current TPM state.
> diff --git a/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigStrings.uni
> b/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigStrings.uni
> index 7a84462a6e..3c3f0f7ddb 100644
> --- a/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigStrings.uni
> +++ b/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigStrings.uni
> @@ -1,7 +1,7 @@
> /** @file
> String definitions for TCG configuration form.
>
> -Copyright (c) 2011 - 2018, Intel Corporation. All rights reserved.<BR>
> +Copyright (c) 2011 - 2019, Intel Corporation. All rights reserved.<BR>
> This program and the accompanying materials
> are licensed and made available under the terms and conditions of the BSD
> License
> which accompanies this distribution. The full text of the license may be
> found at
> @@ -23,6 +23,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF
> ANY KIND, EITHER EXPRESS OR IMPLIED.
> #string STR_TPM_OPERATION #language en-US "TPM
> Operation"
> #string STR_TPM_OPERATION_HELP #language en-US
> "Select one of the supported operation to change TPM state."
>
> +#string STR_NO_ACTION #language en-US "No
> Action"
> #string STR_ENABLE #language en-US
> "Enable"
> #string STR_DISABLE #language en-US
> "Disable"
> #string STR_TPM_ACTIVATE #language en-US
> "Activate"
> --
> 2.20.1.windows.1
prev parent reply other threads:[~2019-02-20 3:12 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-02-04 6:06 [PATCH] SecurityPkg/TcgConfigDxe: Allow enabling TPM 1.2 device from disabled state Rodrigo Gonzalez del Cueto
2019-02-20 3:12 ` Yao, Jiewen [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=74D8A39837DF1E4DA445A8C0B3885C503F5190C2@shsmsx102.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