From: Jarkko Sakkinen <jarkko@kernel.org>
To: tpm-protocol@lists.linux.dev
Cc: tpm2@lists.linux.dev
Subject: Re: [PATCH] fix(message): return `BuildCapacity` from build traits
Date: Mon, 1 Sep 2025 19:29:44 +0300 [thread overview]
Message-ID: <aLXJ-KQ1bM67qV2q@kernel.org> (raw)
In-Reply-To: <20250901161651.2142200-1-jarkko@kernel.org>
On Mon, Sep 01, 2025 at 07:16:51PM +0300, Jarkko Sakkinen wrote:
> Build traits incorrectly return `ParseCapacity` when they should return
> `BuildCapacity`. Fixup the error code.
>
> Capacity means the value of an architectural limit in this context. E.g.,
> the builder and parser detect if a `TPML_*` has more values than the TCG
> specifications allows, and return capacity error if the limit is surpassed.
>
> Additionally, updated documentation of these error values to better
> clarify their use and their purpose.
>
> `BuildOverflow` is probably the most confusing of the pre-existing error
> code. It pre-dates to the time when the implementation had internal
> buffers. Right now, the only function returning that error is
> `TpmWriter::write_bytes`, and when this happens, it is a clear sign of a
> regression in the crate implementation i.e., not part of the legit behavior
> anymore.
>
> In the main branch `BufferOverflow` will be eventually removed but it is
> out of scope for the bug fix.
>
> Signed-off-by: Jarkko Sakkinen <jarkko@kernel.org>
> ---
Since the traffic is low this more like announcing a merge than actual
request-for-review. Any further updates can be provided by sending
patches to the list.
I'll apply this to both main and 0.10.x branches.
BR, Jarkko
prev parent reply other threads:[~2025-09-01 16:29 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-01 16:16 [PATCH] fix(message): return `BuildCapacity` from build traits Jarkko Sakkinen
2025-09-01 16:29 ` Jarkko Sakkinen [this message]
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=aLXJ-KQ1bM67qV2q@kernel.org \
--to=jarkko@kernel.org \
--cc=tpm-protocol@lists.linux.dev \
--cc=tpm2@lists.linux.dev \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.