public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [RFC] TPM non-MMIO Access
@ 2018-11-09 22:37 Cohen, Eugene
  2018-11-09 23:11 ` Yao, Jiewen
  2018-11-09 23:17 ` Yao, Jiewen
  0 siblings, 2 replies; 8+ messages in thread
From: Cohen, Eugene @ 2018-11-09 22:37 UTC (permalink / raw)
  To: edk2-devel@lists.01.org, Chao Zhang, Jiewen Yao
  Cc: Bin, Sung-Uk (빈성욱), Chae, Matthew

Dear SecurityPkg maintainers,

We are trying to use the SecurityPkg TPM support (Tcg2Config, Tpm2DeviceLibDTpm, etc) and see that access to the TPM are using the MMIO routines such as MmioRead8().

Not all platforms support memory-mapped access to the TPM so we would like to propose that we create a library to abstract the TPM access, called the TpmIoLib.  One instance of the library would provide the Mmio (TpmIoLibMmio) method but others can use protocols like SPI (TpmIoLibSpi).

Before starting this work I wanted to check if you agree with the approach of replacing the Mmio calls with new TpmIoLib ones.  We can upstream the library header and mmio library instance (or you could do the work if you think it would be easier for you).

I counted up the number of instances of unique MMIO calls in the TPM libraries and got

Library/TpmCommLib/TisPc.c:7
Library/Tpm2DeviceLibDTpm/Tpm2Tis.c:13
Library/Tpm2DeviceLibDTpm/Tpm2Ptp.c:29
Library/Tpm12DeviceLibDTpm/Tpm12Tis.c:16

Please let me know if this works for you and how you'd like to structure the change.

Thanks,

Eugene





^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2018-11-13  2:13 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-11-09 22:37 [RFC] TPM non-MMIO Access Cohen, Eugene
2018-11-09 23:11 ` Yao, Jiewen
2018-11-09 23:17 ` Yao, Jiewen
     [not found]   ` <AT5PR8401MB0897901965373899E2D9351DF4C10@AT5PR8401MB0897.NAMPRD84.PROD.OUTLOOK.COM>
2018-11-12  4:33     ` Yao, Jiewen
2018-11-12 13:58       ` Cohen, Eugene
2018-11-12 16:44         ` Kinney, Michael D
2018-11-12 20:23           ` Cohen, Eugene
2018-11-13  2:13             ` Bin, Sung-Uk (빈성욱)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox