Re: [PATCH] tpm: Detach page allocation from tpm_buf

From: Jarkko Sakkinen
Date: Tue Oct 01 2019 - 16:52:00 EST


On Sat, Sep 28, 2019 at 12:58:13AM -0700, Jerry Snitselaar wrote:
> TPM2_CC_GET_RANDOM

Ugh, I somehow sent v1 2nd time also in terms of contents (was fixed in
v2).

I think it would be a great idea to add call to tpm_get_random() to the
chip startup as an additional test.

> Would this work here?
>
> err = total ? total : -EIO;
> out:
> kunmap(data_page);
> __free_page(data_page);
> return err;

I'd guess but I want to keep this commit as dumbed down and mechanical
as possible given the amount of changes.

/Jarkko