linux icon indicating copy to clipboard operation
linux copied to clipboard

Delay for IRQ testing is not correct.

Open fredjsq opened this issue 4 months ago • 2 comments

Code : https://github.com/raspberrypi/linux/blob/7335f3c839417ab9fc40fb205249d415e8ed5aa3/drivers/char/tpm/tpm_tis_core.c#L600C2-L600C17

When IRQ has not been tested, the driver is waiting for 1ms only instead of the ordinal maximum duration of the command (usually the GetCapability). For a GetCapability command, we should wait the IRQ for 750ms.

As a result if a TPM is too slow but still meets the specification requirements, the IRQ is wrongly seen at not working.

fredjsq avatar Sep 18 '25 08:09 fredjsq

That's not a file that we have modified - it's unchanged from the mainline/upstream kernel code. I would normally suggest you start by emailing the maintainers:

$ scripts/get_maintainer.pl drivers/char/tpm/tpm_tis_core.c
Peter Huewe <[email protected]> (maintainer:TPM DEVICE DRIVER)
Jarkko Sakkinen <[email protected]> (maintainer:TPM DEVICE DRIVER)
Jason Gunthorpe <[email protected]> (reviewer:TPM DEVICE DRIVER)
[email protected] (open list:TPM DEVICE DRIVER)
[email protected] (open list)

But in this case we can (slightly cheekily) notify @PeterHuewe and @jarkkojs like this. They may have feedback, but they would be within their rights to expect us to go the more formal route of the kernel mailing lists.

pelwell avatar Sep 18 '25 08:09 pelwell

See also https://github.com/raspberrypi/linux/issues/7054.

pelwell avatar Sep 18 '25 08:09 pelwell