From: Tom Lendacky <thomas.lendacky@amd.com>
To: Teddy Astie <teddy.astie@vates.tech>,
linux-kernel@vger.kernel.org, linux-crypto@vger.kernel.org
Cc: Mario Limonciello <mario.limonciello@amd.com>,
John Allen <john.allen@amd.com>,
Herbert Xu <herbert@gondor.apana.org.au>,
"David S. Miller" <davem@davemloft.net>
Subject: Re: [PATCH] ccp/hsti: Fix bogus sizeof in psp_populate_hsti
Date: Thu, 2 Oct 2025 14:18:24 -0500 [thread overview]
Message-ID: <1f662c38-ccf9-af04-a558-a99e153ada48@amd.com> (raw)
In-Reply-To: <5743ec02c374ce52d1b406d41e9e240d049ee7e2.1759427927.git.teddy.astie@vates.tech>
On 10/2/25 13:04, Teddy Astie wrote:
> Payload is actually struct hsti_request and not a pointer which
> makes the considered payload size smaller than it should be.
>
> Signed-off-by: Teddy Astie <teddy.astie@vates.tech>
> Fixes: 82f9327f774c ("crypto: ccp - Add support for getting security attributes on some older systems")
> ---
> CC: Mario Limonciello <mario.limonciello@amd.com>
> CC: Tom Lendacky <thomas.lendacky@amd.com>
> CC: John Allen <john.allen@amd.com>
> CC: Herbert Xu <herbert@gondor.apana.org.au>
> CC: "David S. Miller" <davem@davemloft.net>
Already fixed by 2b0dc40ac6ca ("crypto: ccp - Fix incorrect payload size
calculation in psp_poulate_hsti()")
Thanks,
Tom
> ---
> drivers/crypto/ccp/hsti.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/crypto/ccp/hsti.c b/drivers/crypto/ccp/hsti.c
> index 1b39a4fb55c0..0e6b73b55dbf 100644
> --- a/drivers/crypto/ccp/hsti.c
> +++ b/drivers/crypto/ccp/hsti.c
> @@ -88,7 +88,7 @@ static int psp_poulate_hsti(struct psp_device *psp)
> if (!req)
> return -ENOMEM;
>
> - req->header.payload_size = sizeof(req);
> + req->header.payload_size = sizeof(*req);
>
> ret = psp_send_platform_access_msg(PSP_CMD_HSTI_QUERY, (struct psp_request *)req);
> if (ret)
prev parent reply other threads:[~2025-10-02 19:18 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-02 18:04 Teddy Astie
2025-10-02 19:18 ` Tom Lendacky [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=1f662c38-ccf9-af04-a558-a99e153ada48@amd.com \
--to=thomas.lendacky@amd.com \
--cc=davem@davemloft.net \
--cc=herbert@gondor.apana.org.au \
--cc=john.allen@amd.com \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mario.limonciello@amd.com \
--cc=teddy.astie@vates.tech \
/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®