Re: [PATCH] tpm_tis: Add a check for invalid status

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Sep 28, 2020 at 11:00:12AM -0700, James Bottomley wrote:
> Some TIS based TPMs can return 0xff to status reads if the locality
> hasn't been properly requested.  Detect this condition by checking the
> bits that the TIS spec specifies must return zero are clear and return
> zero in that case.  Also drop a warning so the problem can be
> identified in the calling path and fixed (usually a missing
> try_get_ops()).
> 
> Signed-off-by: James Bottomley <James.Bottomley@xxxxxxxxxxxxxxxxxxxxx>
> 
> This is the patch I've been using to catch and kill all the points in
> the stack where we're not properly using get/put ops on the tpm chip.

If this is a problem add a lockdep on ops_sem in various places too?

Jason



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux Kernel]     [Linux Kernel Hardening]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux SCSI]

  Powered by Linux