1 #ifndef TPM_DRIVER_H 2 /* low level driver implementation */ 3 struct tpm_driver { 4 uint32_t baseaddr; 5 uint32_t (*activate)(uint32_t baseaddr); 6 uint32_t (*ready)(uint32_t baseaddr); 7 uint32_t (*senddata)(uint32_t baseaddr, unsigned char *data, uint32_t len); 8 uint32_t (*readresp)(uint32_t baseaddr, unsigned char *buffer, uint32_t len); 9 uint32_t (*waitdatavalid)(uint32_t baseaddr); 10 uint32_t (*waitrespready)(uint32_t baseaddr, uint32_t timeout); 11 uint32_t (*probe)(uint32_t baseaddr); 12 }; 13 14 #define TPM_NUM_DRIVERS 1 15 16 #define TPM_INVALID_DRIVER -1 17 18 #endif 19