linux-sg2042/drivers/char/tpm
Dr. Greg Wettstein e487a0f523 tpm: Restore functionality to xen vtpm driver.
Functionality of the xen-tpmfront driver was lost secondary to
the introduction of xenbus multi-page support in commit ccc9d90a9a
("xenbus_client: Extend interface to support multi-page ring").

In this commit pointer to location of where the shared page address
is stored was being passed to the xenbus_grant_ring() function rather
then the address of the shared page itself. This resulted in a situation
where the driver would attach to the vtpm-stubdom but any attempt
to send a command to the stub domain would timeout.

A diagnostic finding for this regression is the following error
message being generated when the xen-tpmfront driver probes for a
device:

<3>vtpm vtpm-0: tpm_transmit: tpm_send: error -62

<3>vtpm vtpm-0: A TPM error (-62) occurred attempting to determine
the timeouts

This fix is relevant to all kernels from 4.1 forward which is the
release in which multi-page xenbus support was introduced.

Daniel De Graaf formulated the fix by code inspection after the
regression point was located.

Fixes: ccc9d90a9a ("xenbus_client: Extend interface to support multi-page ring")
Signed-off-by: Dr. Greg Wettstein <greg@enjellic.com>

[boris: Updated commit message, added Fixes tag]
Signed-off-by: Boris Ostrovsky <boris.ostrovsky@oracle.com>
Cc: stable@vger.kernel.org # v4.1+
Reviewed-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Signed-off-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
2018-10-05 13:47:34 +03:00
..
eventlog tpm: replace kmalloc() + memcpy() with kmemdup() 2018-05-14 13:59:52 +03:00
st33zp24 tpm/st33zp24: Fix spelling mistake in macro ST33ZP24_TISREGISTER_UKNOWN 2018-05-09 14:45:46 +03:00
Kconfig tpm: Make SECURITYFS a weak dependency 2018-10-05 13:47:33 +03:00
Makefile tpm: Move shared eventlog functions to common.c 2018-05-09 14:45:46 +03:00
tpm-chip.c tpm: Convert tpm_find_get_ops() to use tpm_default_chip() 2018-07-28 17:03:11 +03:00
tpm-dev-common.c tpm: add support for nonblocking operation 2018-10-05 13:47:33 +03:00
tpm-dev.c tpm: add support for nonblocking operation 2018-10-05 13:47:33 +03:00
tpm-dev.h tpm: add support for nonblocking operation 2018-10-05 13:47:33 +03:00
tpm-interface.c tpm: add support for nonblocking operation 2018-10-05 13:47:33 +03:00
tpm-sysfs.c tpm: migrate pubek_show to struct tpm_buf 2017-10-12 14:28:59 +03:00
tpm.h tpm: add support for nonblocking operation 2018-10-05 13:47:33 +03:00
tpm2-cmd.c tpm: fix response size validation in tpm_get_random() 2018-10-05 13:47:33 +03:00
tpm2-space.c tpm: replace TPM_TRANSMIT_RAW with TPM_TRANSMIT_NESTED 2018-07-28 17:03:11 +03:00
tpm_atmel.c tpm/tpm_atmel: remove unnecessary NULL check 2017-06-19 02:36:04 +02:00
tpm_atmel.h tpm: remove tpm_read_index and tpm_write_index from tpm.h 2017-02-03 22:03:14 +02:00
tpm_crb.c tpm: separate cmd_ready/go_idle from runtime_pm 2018-07-28 17:03:11 +03:00
tpm_i2c_atmel.c tpm: Factor out common startup code 2016-07-19 17:43:38 +03:00
tpm_i2c_infineon.c tpm/tpm_i2c_infineon: switch to i2c_lock_bus(..., I2C_LOCK_SEGMENT) 2018-07-28 17:03:11 +03:00
tpm_i2c_nuvoton.c tpm_i2c_nuvoton: fix potential buffer overruns caused by bit glitches on the bus 2018-02-26 15:43:44 -08:00
tpm_ibmvtpm.c tpm: ibmvtpm: simplify crq initialization and document crq format 2017-09-23 21:51:38 -07:00
tpm_ibmvtpm.h tpm_ibmvtpm: properly handle interrupted packet receptions 2015-12-20 15:27:12 +02:00
tpm_infineon.c tpm: replace msleep() with usleep_range() in TPM 1.2/2.0 generic drivers 2017-09-23 21:51:00 -07:00
tpm_nsc.c tpm: remove tpm_read_index and tpm_write_index from tpm.h 2017-02-03 22:03:14 +02:00
tpm_ppi.c ACPI: Switch to use generic guid_t in acpi_evaluate_dsm() 2017-06-07 12:20:49 +02:00
tpm_tis.c tpm: remove unused variables 2018-01-08 12:58:54 +02:00
tpm_tis_core.c tpm: Allow tpm_tis drivers to set hwrng quality. 2018-07-28 17:03:11 +03:00
tpm_tis_core.h tpm: Allow tpm_tis drivers to set hwrng quality. 2018-07-28 17:03:11 +03:00
tpm_tis_spi.c tpm_tis_spi: Pass the SPI IRQ down to the driver 2018-07-28 17:03:11 +03:00
tpm_vtpm_proxy.c tpm: replace TPM_TRANSMIT_RAW with TPM_TRANSMIT_NESTED 2018-07-28 17:03:11 +03:00
tpmrm-dev.c tpm: add support for nonblocking operation 2018-10-05 13:47:33 +03:00
xen-tpmfront.c tpm: Restore functionality to xen vtpm driver. 2018-10-05 13:47:34 +03:00