|
@@ -450,7 +450,7 @@ static ssize_t tpm_try_transmit(struct tpm_chip *chip,
|
|
header->tag = cpu_to_be16(TPM2_ST_NO_SESSIONS);
|
|
header->tag = cpu_to_be16(TPM2_ST_NO_SESSIONS);
|
|
header->return_code = cpu_to_be32(TPM2_RC_COMMAND_CODE |
|
|
header->return_code = cpu_to_be32(TPM2_RC_COMMAND_CODE |
|
|
TSS2_RESMGR_TPM_RC_LAYER);
|
|
TSS2_RESMGR_TPM_RC_LAYER);
|
|
- return bufsiz;
|
|
|
|
|
|
+ return sizeof(*header);
|
|
}
|
|
}
|
|
|
|
|
|
if (bufsiz > TPM_BUFSIZE)
|
|
if (bufsiz > TPM_BUFSIZE)
|