Re: [RFC PATCH 1/1] tpm: don't return bool from update_timeouts

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue Jan 29 19, Jarkko Sakkinen wrote:
On Tue, Jan 29, 2019 at 10:41:45AM -0700, Jerry Snitselaar wrote:
Set tpm_chip->timeouts_adjusted directly in the update_timeouts
code instead of returning bool. Return rc of tpm read instead,
which can be return an error in the case of the spi driver.

Signed-off-by: Jerry Snitselaar <jsnitsel@xxxxxxxxxx>

Couple of remarks:

1. Shouldn't it then be just void?

Yes I think if we don't really care about the tpm read failing
it can just be void, and print out a warning when the read fail
occurs.

2. Why do we even need timeout_adjusted in struct tpm_chip [1]?

It gets used by timeouts_show in tpm-sysfs.c as well.


[1] Only used locally in tpm1_get_timeouts().

/Jarkko



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux Kernel]     [Linux Kernel Hardening]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux SCSI]

  Powered by Linux