Forum | Documentation | Website | Blog

Skip to content
Snippets Groups Projects
Commit df745e25 authored by Jarkko Sakkinen's avatar Jarkko Sakkinen
Browse files

tpm: Lazily flush the auth session


Move the allocation of chip->auth to tpm2_start_auth_session() so that this
field can be used as flag to tell whether auth session is active or not.

Instead of flushing and reloading the auth session for every transaction
separately, keep the session open unless /dev/tpm0 is used.

Reported-by: default avatarPengyu Ma <mapengyu@gmail.com>
Closes: https://bugzilla.kernel.org/show_bug.cgi?id=219229
Cc: stable@vger.kernel.org # v6.10+
Fixes: 7ca110f2

 ("tpm: Address !chip->auth in tpm_buf_append_hmac_session*()")
Tested-by: default avatarPengyu Ma <mapengyu@gmail.com>
Tested-by: default avatarStefan Berger <stefanb@linux.ibm.com>
Reviewed-by: default avatarStefan Berger <stefanb@linux.ibm.com>
Signed-off-by: default avatarJarkko Sakkinen <jarkko@kernel.org>
parent cc7d8594
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment