From: Prachotan Bathi <prachotan.bathi@arm.com>
To: Peter Huewe <peterhuewe@gmx.de>,
Jarkko Sakkinen <jarkko@kernel.org>,
Jason Gunthorpe <jgg@ziepe.ca>,
Stuart Yoder <stuart.yoder@arm.com>
Cc: linux-integrity@vger.kernel.org, linux-kernel@vger.kernel.org,
Prachotan Bathi <prachotan.bathi@arm.com>
Subject: [PATCH v4 0/1] tpm_crb_ffa: handle tpm busy return code
Date: Fri, 13 Jun 2025 18:31:31 -0500 [thread overview]
Message-ID: <20250613233132.4167653-1-prachotan.bathi@arm.com> (raw)
Platforms that support FF-A direct message request v2 can implement
Secure Partitions (SPs) that host multiple services. When the TPM
service shares its SP with other services, message requests from the
driver may fail with a BUSY response if another service is currently
active.
To improve robustness in such scenarios, we need to introduce retry
logic in the driver. When a BUSY error is received, the driver will
re-attempt the TPM request until it succeeds or a configurable timeout
(default: 2000 ms) is reached. This ensures reliable TPM access under
shared-SP conditions.
Add a module parameter, `busy_timeout`, which specifies the
maximum amount of time (in milliseconds) to retry on BUSY before giving
up.
This change builds on top of commit a85b55ee64a5, which introduced
support for TPM service communication using the FF-A direct message v2
path, in accordance with section 3.3 of the TPM Service Command
Response Buffer Interface specification.
https://developer.arm.com/documentation/den0138/latest/
Changes in v4:
- Updated commit message to clarify the purpose of the patch.
- Removed comments that state the obvious.
Prachotan Bathi (1):
tpm_crb_ffa: handle tpm busy return code
drivers/char/tpm/tpm_crb_ffa.c | 74 +++++++++++++++++++++++-----------
1 file changed, 50 insertions(+), 24 deletions(-)
--
2.43.0
next reply other threads:[~2025-06-13 23:31 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-13 23:31 Prachotan Bathi [this message]
2025-06-13 23:31 ` [PATCH v4 1/1] " Prachotan Bathi
2025-06-14 5:22 ` Paul Menzel
2025-06-17 14:40 ` Jarkko Sakkinen
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=20250613233132.4167653-1-prachotan.bathi@arm.com \
--to=prachotan.bathi@arm.com \
--cc=jarkko@kernel.org \
--cc=jgg@ziepe.ca \
--cc=linux-integrity@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=peterhuewe@gmx.de \
--cc=stuart.yoder@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®