diff options
author | Stefan Berger <stefanb@linux.vnet.ibm.com> | 2017-05-24 17:39:39 -0400 |
---|---|---|
committer | Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com> | 2017-06-13 22:02:09 +0300 |
commit | 85ab3bf305b96e5f4c83b23a0b7e11d90144eb18 (patch) | |
tree | f5cf55bfe1773613f11aa3dabdba5beb334f01ca /drivers/char/tpm/tpm-interface.c | |
parent | 402149c6470d9562fe6891e0165df7f5f6bff7a7 (diff) | |
download | op-kernel-dev-85ab3bf305b96e5f4c83b23a0b7e11d90144eb18.zip op-kernel-dev-85ab3bf305b96e5f4c83b23a0b7e11d90144eb18.tar.gz |
tpm: Introduce flag TPM_TRANSMIT_RAW
Introduce the flag TPM_TRANSMIT_RAW that allows us to transmit
a command without recursing into the requesting of locality.
Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Reviewed-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Signed-off-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Diffstat (limited to 'drivers/char/tpm/tpm-interface.c')
-rw-r--r-- | drivers/char/tpm/tpm-interface.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/char/tpm/tpm-interface.c b/drivers/char/tpm/tpm-interface.c index a965a9f..8ef5e17 100644 --- a/drivers/char/tpm/tpm-interface.c +++ b/drivers/char/tpm/tpm-interface.c @@ -416,7 +416,8 @@ ssize_t tpm_transmit(struct tpm_chip *chip, struct tpm_space *space, /* Store the decision as chip->locality will be changed. */ need_locality = chip->locality == -1; - if (need_locality && chip->ops->request_locality) { + if (!(flags & TPM_TRANSMIT_RAW) && + need_locality && chip->ops->request_locality) { rc = chip->ops->request_locality(chip, 0); if (rc < 0) goto out_no_locality; |