* [Qemu-devel] [PATCH] tests: request access to locality 0 before sending command
@ 2018-04-16 17:48 Stefan Berger
2018-04-17 9:08 ` Marc-André Lureau
0 siblings, 1 reply; 3+ messages in thread
From: Stefan Berger @ 2018-04-16 17:48 UTC (permalink / raw)
To: marcandre.lureau, qemu-devel; +Cc: peter.maydell, Stefan Berger
Recent changes to the CRB code now require that access to locality 0
be requested before the locality can be used for sending a command.
This patch adds the request to access the locality.
Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
---
tests/tpm-util.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/tests/tpm-util.c b/tests/tpm-util.c
index 4967a4e..6910503 100644
--- a/tests/tpm-util.c
+++ b/tests/tpm-util.c
@@ -25,6 +25,8 @@ void tpm_util_crb_transfer(QTestState *s,
uint64_t caddr = qtest_readq(s, TPM_CRB_ADDR_BASE + A_CRB_CTRL_CMD_LADDR);
uint64_t raddr = qtest_readq(s, TPM_CRB_ADDR_BASE + A_CRB_CTRL_RSP_ADDR);
+ qtest_writeb(s, TPM_CRB_ADDR_BASE + A_CRB_LOC_CTRL, 1);
+
qtest_memwrite(s, caddr, req, req_size);
uint32_t sts, start = 1;
--
2.5.5
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [PATCH] tests: request access to locality 0 before sending command
2018-04-16 17:48 [Qemu-devel] [PATCH] tests: request access to locality 0 before sending command Stefan Berger
@ 2018-04-17 9:08 ` Marc-André Lureau
2018-04-17 10:41 ` Stefan Berger
0 siblings, 1 reply; 3+ messages in thread
From: Marc-André Lureau @ 2018-04-17 9:08 UTC (permalink / raw)
To: Stefan Berger; +Cc: QEMU, Peter Maydell
Hi
On Mon, Apr 16, 2018 at 7:48 PM, Stefan Berger
<stefanb@linux.vnet.ibm.com> wrote:
> Recent changes to the CRB code now require that access to locality 0
> be requested before the locality can be used for sending a command.
> This patch adds the request to access the locality.
>
> Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
> ---
> tests/tpm-util.c | 2 ++
The patch fails to apply, tpm-util is added with your upcoming "tpm:
Add test cases that use the external swtpm with CRB interface" patch,
I guess it could be squashed there (I confirm it fixes the test)
tpm-crb-test.c isn't affected, because you changed it in "tests: Tests
more flags of the CRB interface" already
> 1 file changed, 2 insertions(+)
>
> diff --git a/tests/tpm-util.c b/tests/tpm-util.c
> index 4967a4e..6910503 100644
> --- a/tests/tpm-util.c
> +++ b/tests/tpm-util.c
> @@ -25,6 +25,8 @@ void tpm_util_crb_transfer(QTestState *s,
> uint64_t caddr = qtest_readq(s, TPM_CRB_ADDR_BASE + A_CRB_CTRL_CMD_LADDR);
> uint64_t raddr = qtest_readq(s, TPM_CRB_ADDR_BASE + A_CRB_CTRL_RSP_ADDR);
>
> + qtest_writeb(s, TPM_CRB_ADDR_BASE + A_CRB_LOC_CTRL, 1);
> +
> qtest_memwrite(s, caddr, req, req_size);
>
> uint32_t sts, start = 1;
> --
> 2.5.5
>
--
Marc-André Lureau
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [PATCH] tests: request access to locality 0 before sending command
2018-04-17 9:08 ` Marc-André Lureau
@ 2018-04-17 10:41 ` Stefan Berger
0 siblings, 0 replies; 3+ messages in thread
From: Stefan Berger @ 2018-04-17 10:41 UTC (permalink / raw)
To: Marc-André Lureau; +Cc: Peter Maydell, QEMU
On 04/17/2018 05:08 AM, Marc-André Lureau wrote:
> Hi
>
> On Mon, Apr 16, 2018 at 7:48 PM, Stefan Berger
> <stefanb@linux.vnet.ibm.com> wrote:
>> Recent changes to the CRB code now require that access to locality 0
>> be requested before the locality can be used for sending a command.
>> This patch adds the request to access the locality.
>>
>> Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
>> ---
>> tests/tpm-util.c | 2 ++
> The patch fails to apply, tpm-util is added with your upcoming "tpm:
> Add test cases that use the external swtpm with CRB interface" patch,
> I guess it could be squashed there (I confirm it fixes the test)
>
>
> tpm-crb-test.c isn't affected, because you changed it in "tests: Tests
> more flags of the CRB interface" already
Right, wrong branch. Everything is good on 'git tip'.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2018-04-17 10:42 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-04-16 17:48 [Qemu-devel] [PATCH] tests: request access to locality 0 before sending command Stefan Berger
2018-04-17 9:08 ` Marc-André Lureau
2018-04-17 10:41 ` Stefan Berger
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).