[PATCH v6 0/2] Fix corner cases with disabling CLKRUN in tpm_tis
From: Shaikh, Azhar <hidden>
Date: 2017-12-07 01:35:13
Also in:
lkml
-----Original Message----- From: Jarkko Sakkinen [mailto:jarkko.sakkinen at linux.intel.com] Sent: Wednesday, December 6, 2017 5:30 PM To: Shaikh, Azhar <redacted> Cc: jgunthorpe at obsidianresearch.com; peterhuewe at gmx.de; linux-security- module at vger.kernel.org; linux-kernel at vger.kernel.org; tpmdd- devel at lists.sourceforge.net Subject: Re: [PATCH v6 0/2] Fix corner cases with disabling CLKRUN in tpm_tis On Wed, Nov 29, 2017 at 10:39:49AM -0800, Azhar Shaikh wrote:quoted
Changes from v1: - Patch 1: "tpm: Keep CLKRUN enabled throughout the duration oftransmit_cmd()"quoted
- Add NULL checks before calling clk_toggle callback - Use IS_ENABLED instead of ifdef in tpm_tis_clkrun_toggle() - Do not call tpm_platform_begin_xfer() and tpm_platform_end_xfer() from tpm_tis_clkrun_toggle(). Make them static again. - Patch 2: "tpm_tis: Move ilb_base_addr to tpm_tis_tcg_phy" - This is a new patch in this series as per suggestion from Jason. - Is the current implementation ok or I should move the code intpm_tis_pnp_remove()quoted
and tpm_tis_plat_remove() inside tpm_tis_remove(). That way all theunmappingquoted
can be done in one place, instead of 3 different places now. Also theunmappingquoted
in tpm_tis_init() can be moved to tpm_tis_remove(), since in case of error tpm_tis_core_init() calls tpm_tis_remove(). Kindly suggest. Changes from v2: - Patch 1: "tpm: Keep CLKRUN enabled throughout the duration oftransmit_cmd()"quoted
- No changes - Patch 2: "tpm_tis: Move ilb_base_addr to tpm_tis_tcg_phy" - Updated is_bsw() function to have the #ifdef CONFIG_X86 check withinthe functionquoted
itself. Also removed the #ifdef CONFIG_X86 from all other places aroundis_bsw()quoted
Changes from v3: - Patch 1: "tpm: Keep CLKRUN enabled throughout the duration oftransmit_cmd()"quoted
- Change function name from clk_toggle to clk_enable - Update the commit message. - Patch 2: "tpm_tis: Move ilb_base_addr to tpm_tis_tcg_phy" - No changes Changes from v4: - The numbering of patches is now interchanged. - Patch 1: "tpm_tis: Move ilb_base_addr to tpm_tis_data" - Had to move ilb_base_addr to tpm_tis_data, from tpm_tis_tcg_phy. Since the ioremapping of ilb_base_addr had to be done before any TPMaccess,quoted
hence moved the variable to tpm_tis_data. - Also move the ioremapping of ilb_base_addr from tpm_tis_init() to tpm_tis_core_init() i.e. before any TPM access is done. - Rename marco LPC_CNTRL_REG_OFFSET to LPC_CNTRL_OFFSET - Update the commit message. - Patch 2: "tpm: Keep CLKRUN enabled throughout the duration oftransmit_cmd()"quoted
- Remove the functions tpm_platform_begin_xfer() andtpm_platform_end_xfer()quoted
- Move the code from these functions to tpm_tis_clkrun_enable(). Changes from v5: - Patch 1: "tpm_tis: Move ilb_base_addr to tpm_tis_data" - No changes - Patch 2: "tpm: Keep CLKRUN enabled throughout the duration oftransmit_cmd()"quoted
- Update the commit message. Azhar Shaikh (2): tpm_tis: Move ilb_base_addr to tpm_tis_data tpm: Keep CLKRUN enabled throughout the duration of transmit_cmd() drivers/char/tpm/tpm-interface.c | 6 ++ drivers/char/tpm/tpm_tis.c | 121 ++++++--------------------------------- drivers/char/tpm/tpm_tis_core.c | 111+++++++++++++++++++++++++++++++++--quoted
drivers/char/tpm/tpm_tis_core.h | 17 ++++++ include/linux/tpm.h | 1 + 5 files changed, 147 insertions(+), 109 deletions(-) -- 1.9.1Please, resend this to linux-integrity. You have wrong ML in your CC.
Sure, I will send it to linux-integrity.
/Jarkko
Regards, Azhar Shaikh -- To unsubscribe from this list: send the line "unsubscribe linux-security-module" in the body of a message to majordomo at vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html