[Skiboot] [PATCH 3/8] TPM/TSS: Register TPM chip for further use within TSS
Mauro S. M. Rodrigues
maurosr at linux.vnet.ibm.com
Tue Jun 2 06:34:34 AEST 2020
TSS will know which device and transmit handler to use through this
registration, and the equivalent unregistering process.
Signed-off-by: Mauro S. M. Rodrigues <maurosr at linux.vnet.ibm.com>
---
libstb/drivers/tpm_i2c_nuvoton.c | 1 +
libstb/tpm_chip.c | 1 +
2 files changed, 2 insertions(+)
diff --git a/libstb/drivers/tpm_i2c_nuvoton.c b/libstb/drivers/tpm_i2c_nuvoton.c
index 9a26fca65d..9d3ff82e0a 100644
--- a/libstb/drivers/tpm_i2c_nuvoton.c
+++ b/libstb/drivers/tpm_i2c_nuvoton.c
@@ -608,6 +608,7 @@ void tpm_i2c_nuvoton_probe(void)
free(tpm_device);
continue;
}
+ tss_tpm_register(tpm_device, &tpm_i2c_nuvoton_driver);
bus = i2c_find_bus_by_id(tpm_device->bus_id);
assert(bus->check_quirk == NULL);
bus->check_quirk = nuvoton_tpm_quirk;
diff --git a/libstb/tpm_chip.c b/libstb/tpm_chip.c
index 004750f5fb..f90282fe2f 100644
--- a/libstb/tpm_chip.c
+++ b/libstb/tpm_chip.c
@@ -213,6 +213,7 @@ void tpm_cleanup(void)
tpm = list_pop(&tpm_list, struct tpm_chip, link);
}
+ tss_tpm_unregister();
list_head_init(&tpm_list);
}
--
2.26.2
More information about the Skiboot
mailing list