[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20160720164818.GA21460@obsidianresearch.com>
Date: Wed, 20 Jul 2016 10:48:18 -0600
From: Jason Gunthorpe <jgunthorpe@...idianresearch.com>
To: Jarkko Sakkinen <jarkko.sakkinen@...ux.intel.com>
Cc: Peter Huewe <peterhuewe@....de>,
linux-security-module@...r.kernel.org,
Marcel Selhorst <tpmdd@...horst.net>,
"moderated list:TPM DEVICE DRIVER"
<tpmdd-devel@...ts.sourceforge.net>,
open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] tpm: fix a race condition tpm2_unseal_trusted()
On Wed, Jul 20, 2016 at 03:16:32AM +0300, Jarkko Sakkinen wrote:
> Unseal and load operations should be done as an atomic unit. This
> commit fixes the issue by moving TPM mutex handling to tpm_try_get_ops()
> and tpm_put_ops(), which is probably more logical place for it anyway.
No..
'get_ops' is to be used to hold a persisent kref to a single tpm. It
cannot block other tpm access.
Eg a upper protocol might get_ops to for a long period to ensure it
consistently talks to the same TPM in a multi-tpm system.
We need something else to solve whatever you are concerned with
here..
Jason
Powered by blists - more mailing lists