From: Simon Glass Date: Sun, 18 Nov 2018 14:22:25 -0700 Subject: [U-Boot] [PATCH v2 2/5] tpm: Add a constant for the minimum supported digest size In-Reply-To: <20181118212228.23194-1-sjg@chromium.org> References: <20181118212228.23194-1-sjg@chromium.org> Message-ID: <20181118212228.23194-3-sjg@chromium.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de When SHA1 is used we need 20 bytes for the digest size. Add a constant so that clients can make use of this, e.g. to allocate local buffers. Signed-off-by: Simon Glass --- Changes in v2: - Split out from main TPM patch include/tpm-common.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/tpm-common.h b/include/tpm-common.h index 5f8bc6bc528..449ad4c96e1 100644 --- a/include/tpm-common.h +++ b/include/tpm-common.h @@ -26,6 +26,8 @@ enum tpm_duration { /* Max buffer size supported by our tpm */ #define TPM_DEV_BUFSIZE 1260 +#define TPM_PCR_MINIMUM_DIGEST_SIZE 20 + /** * enum tpm_version - The version of the TPM stack to be used * @TPM_V1: Use TPM v1.x stack -- 2.19.1.1215.g8438c0b245-goog