On Thu, Jun 04, 2020 at 04:47:06PM +0300, [email protected] wrote:
> From: Amir Mizinski <[email protected]>
> 
> Only tpm_tis can use memory-mapped I/O, which is truly mapped into
> the kernel's memory space. Therefore, using ioread16/ioread32/iowrite32
> turns into a straightforward pointer dereference.
> Every other driver requires more complicated operations to read more than
> one byte at a time and will just fall back to read_bytes/write_bytes.
> Therefore, move this common code out of tpm_tis_spi and into tpm_tis_core
> so that it is used automatically when low-level drivers do not implement
> the specialized methods.
> 
> Co-developed-by: Alexander Steffen <[email protected]>
> Signed-off-by: Alexander Steffen <[email protected]>
> Signed-off-by: Amir Mizinski <[email protected]>

Reviewed-by: Jarkko Sakkinen <[email protected]>
Tested-by: Jarkko Sakkinen <[email protected]>

I tested this with my T480 ThinkPad, which has Infineon SLB 9670 TPM
chip according to TPM_PT_VENDOR_STRING_* [*]

[*] tpm2_getcap properties-fixed from tpm2-tools package to fetch this
    information.

/Jarkko

Reply via email to