From: Siddharth Chintamaneni <sidchintamaneni@gmail.com>
To: Peter Huewe <peterhuewe@gmx.de>, Jarkko Sakkinen <jarkko@kernel.org>
Cc: Jason Gunthorpe <jgg@ziepe.ca>,
Sudeep Holla <sudeep.holla@kernel.org>,
Yeoreum Yun <yeoreum.yun@arm.com>,
Stuart Yoder <stuart.yoder@arm.com>,
apais@microsoft.com, rachelmenge@linux.microsoft.com,
hargar@linux.microsoft.com, linux-integrity@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org,
Siddharth Chintamaneni <sidchintamaneni@gmail.com>
Subject: [PATCH v3 0/4] tpm: Cache ACPI TPM2 start method and gate tpm_crb_ffa probe
Date: Sun, 15 Nov 2026 01:34:52 +0000 [thread overview]
Message-ID: <20261115013456.212141-1-sidchintamaneni@gmail.com> (raw)
This series caches the ACPI TPM2 start method in tpm_init() and uses
the cached tpm2_acpi_start_method value across tpm_crb_ffa, tpm_tis,
and tpm_crb.
Patch 1 caches the ACPI TPM2 start method once in tpm_init() into
tpm2_acpi_start_method (defaulting to ACPI_TPM2_NOT_ALLOWED when
absent or invalid) and logs it when a TPM2 ACPI table is present.
Patch 2 checks tpm2_acpi_start_method in tpm_crb_ffa_probe() and
returns -ENODEV unless ACPI advertises ACPI_TPM2_CRB_WITH_ARM_FFA,
skipping FF-A probing on non-FF-A platforms while keeping modular
tpm_crb/tpm_crb_ffa loading intact.
Patches 3 and 4 update tpm_tis and tpm_crb to use the cached
tpm2_acpi_start_method value directly.
Changes in v3:
- Log tpm2_acpi_start_method in tpm_init() after acpi_put_table() and
use a single-line acpi_get_table() call with typeof(tbl->header)
cast (Jarkko Sakkinen).
- Remove check_acpi_tpm2() in tpm_tis and open-code the check in
tpm_tis_init(), dropping dev_err() and returning -ENODEV (Jarkko
Sakkinen).
- Remove priv->sm and local sm in tpm_crb, use tpm2_acpi_start_method
throughout, drop the probe dev_err() messages, and return -ENODEV
(Jarkko Sakkinen).
Changes in v2:
- Expand into a 4-patch series caching tpm2_acpi_start_method in
tpm_init() and converting tpm_crb_ffa, tpm_tis, and tpm_crb to use
it (Jarkko Sakkinen).
- Move the tpm_crb_ffa start_method check from module_init into
tpm_crb_ffa_probe() so tpm_crb.ko and tpm_crb_ffa.ko still load
cleanly on non-FF-A systems when built as modules.
v2: https://lore.kernel.org/linux-integrity/20261114193434.117714-1-sidchintamaneni@gmail.com/
v1: https://lore.kernel.org/linux-integrity/20261112233807.70664-1-sidchintamaneni@gmail.com/
Jarkko Sakkinen (1):
tpm: Cache TPM2 start method
Siddharth Chintamaneni (3):
tpm: tpm_crb_ffa: Only probe when ACPI TPM2 uses FF-A
tpm: tpm_tis: Use cached tpm2_acpi_start_method
tpm: tpm_crb: Use cached tpm2_acpi_start_method
drivers/char/tpm/tpm-interface.c | 21 ++++++++
drivers/char/tpm/tpm.h | 1 +
drivers/char/tpm/tpm_crb.c | 82 +++++++++++++++-----------------
drivers/char/tpm/tpm_crb_ffa.c | 5 ++
drivers/char/tpm/tpm_tis.c | 45 +++---------------
5 files changed, 71 insertions(+), 83 deletions(-)
base-commit: 7e52fc165aa50e70e8df3c879d04fc0ff1673d4a
--
2.45.4
next reply other threads:[~2026-11-15 1:35 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-15 1:34 Siddharth Chintamaneni [this message]
2026-11-15 1:34 ` [PATCH v3 1/4] tpm: Cache TPM2 start method Siddharth Chintamaneni
2026-11-15 1:34 ` [PATCH v3 2/4] tpm: tpm_crb_ffa: Only probe when ACPI TPM2 uses FF-A Siddharth Chintamaneni
2026-11-15 1:34 ` [PATCH v3 3/4] tpm: tpm_tis: Use cached tpm2_acpi_start_method Siddharth Chintamaneni
2026-11-15 1:34 ` [PATCH v3 4/4] tpm: tpm_crb: " Siddharth Chintamaneni
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261115013456.212141-1-sidchintamaneni@gmail.com \
--to=sidchintamaneni@gmail.com \
--cc=apais@microsoft.com \
--cc=hargar@linux.microsoft.com \
--cc=jarkko@kernel.org \
--cc=jgg@ziepe.ca \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-integrity@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=peterhuewe@gmx.de \
--cc=rachelmenge@linux.microsoft.com \
--cc=stuart.yoder@arm.com \
--cc=sudeep.holla@kernel.org \
--cc=yeoreum.yun@arm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®