diff options
| author | Kevin Bowling <kbowling@FreeBSD.org> | 2026-08-27 13:42:49 +0000 |
|---|---|---|
| committer | Kevin Bowling <kbowling@FreeBSD.org> | 2026-09-01 18:23:36 +0000 |
| commit | 4e0f283fb97a7b0903adc7bc3ef2f6e07167c73e (patch) | |
| tree | c9f298593a78e1bc78e0e39083d5f114d741d114 /llvm/lib/Analysis/LoopAccessAnalysis.cpp | |
| parent | 799e14aa60d81aa9eed1985e4683e12f6851ecfd (diff) | |
tpm: Bound TPM 1.2 locality ownership
A TIS locality must remain active while a command is in flight, but
should be relinquished once the command completes or is abandoned. The
driver retained locality zero after probe, initialization, and resume,
and several transaction error paths returned without releasing it.
Closing the device after writing a command without reading its response
had the same effect.
Track locality ownership and whether a command is awaiting its response.
Release locality after probe, initialization, and resume; retain it only
across a successful command write and its matching response read. Abort
and release on errors, replacement commands, close, and detach.
Wait for locality during ISA probe instead of assuming an immediate
grant, release locality acquired by the probe, and stop treating the
command-style TPM_ACCESS register as restorable state.
On a ThinkPad T440p with an STMicro TPM 1.2, the old driver left
TPM_ACCESS at 0xa1 immediately after attach. The new driver left it at
0x81 after attach, completed PCR reads, and closing with an unread
response. PCR reads also survived an unload and reload without TPM or
locking diagnostics.
Reviewed by: kevants
MFC after: 2 weeks
Sponsored by: BBOX.io
Differential Revision: https://reviews.freebsd.org/D59237
Diffstat (limited to 'llvm/lib/Analysis/LoopAccessAnalysis.cpp')
0 files changed, 0 insertions, 0 deletions
