devices: rework TPM register and field look-up

Match against enums instead.

This then drops the need to import phf.

Signed-off-by: Wei Liu <liuwe@microsoft.com>
This commit is contained in:
Wei Liu
2023-01-25 17:00:57 +00:00
committed by Rob Bradford
parent 99d8c34861
commit cd1470e289
3 changed files with 207 additions and 169 deletions
-1
View File
@@ -13,7 +13,6 @@ byteorder = "1.4.3"
hypervisor = { path = "../hypervisor" }
libc = "0.2.139"
log = "0.4.17"
phf = { version = "0.11.1", features = ["macros"] }
thiserror = "1.0.38"
tpm = { path = "../tpm" }
versionize = "0.1.9"