lkml.org 
[lkml]   [2015]   [Mar]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [tpmdd-devel] [PATCH v2] tpm: fix: sanitized code paths in tpm_chip_register()
On Wed, 18 Mar 2015, Jarkko Sakkinen wrote:
> I started to work with PPI interface so that it would be available
> under character device sysfs directory and realized that chip
> registeration was still too messy.
>
> In TPM 1.x in some rare scenarios (errors that almost never occur)
> wrong order in deinitialization steps was taken in teardown. I
> reproduced these scenarios by manually inserting error codes in the
> place of the corresponding function calls.
>
> The key problem is that the teardown is messy with two separate code
> paths (this was inherited when moving code from tpm-interface.c).
>
> Moved TPM 1.x specific register/unregister functionality to own helper
> functions and added single code path for teardown in tpm_chip_register().
> Now the code paths have been fixed and it should be easier to review
> later on this part of the code.
>
> Signed-off-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>

CONFIG_TCG_TPM=y
CONFIG_TCG_TIS=y
# CONFIG_TCG_TIS_I2C_ATMEL is not set
# CONFIG_TCG_TIS_I2C_INFINEON is not set
# CONFIG_TCG_TIS_I2C_NUVOTON is not set
# CONFIG_TCG_NSC is not set
# CONFIG_TCG_ATMEL is not set
# CONFIG_TCG_INFINEON is not set
# CONFIG_TCG_CRB is not set

[0.236145] tpm_tis 00:08: 1.2 TPM (device-id 0xB, rev-id 16)
[0.292769] tpm_tis 00:08: [Firmware Bug]: TPM interrupt not working, polling instead

and suspend/resume continue to function.

Tested-by: Scot Doyle <lkml14@scotdoyle.com>


\
 
 \ /
  Last update: 2015-03-18 17:21    [W:0.284 / U:0.068 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site