[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANg-bXCcbQn3CfDh6YVrSsxUAAAySR05+dVzvQ=XxLb0HaHeaQ@mail.gmail.com>
Date: Mon, 27 Mar 2023 10:26:20 -0600
From: Mark Hasemeyer <markhas@...omium.org>
To: Mario Limonciello <mario.limonciello@....com>
Cc: Jan Dąbroś <jsd@...ihalf.com>,
Grzegorz Bernacki <gjb@...ihalf.com>,
Tom Lendacky <thomas.lendacky@....com>,
John Allen <john.allen@....com>,
Herbert Xu <herbert@...dor.apana.org.au>,
"David S. Miller" <davem@...emloft.net>,
linux-crypto@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v6 2/4] crypto: ccp: Return doorbell status code as an argument
> -int psp_ring_platform_doorbell(int msg)
> +int psp_ring_platform_doorbell(int msg, u32 *result)
> {
> struct psp_device *psp = psp_get_master_device();
> struct psp_platform_access_device *pa_dev;
> @@ -184,6 +184,8 @@ int psp_ring_platform_doorbell(int msg)
>
> val = FIELD_GET(PSP_CMDRESP_STS, ioread32(cmd));
> if (val) {
> + if (result)
> + *result = val;
> ret = -EIO;
> goto unlock;
> }
The bitfields in the new mailbox architecture have changed, as it is
now a dedicated mailbox for I2C arbitration. The 8 lsbs are used for
command and response status, and bit 31 is the ready bit.
Accounting for these changes, I was able to get the TPM contention
test to pass locally. I also removed calls to "check_doorbell" and
"check_recovery" as those steps weren't described in the design doc.
Powered by blists - more mailing lists