1 /* SPDX-License-Identifier: GPL-2.0-only */
3 * STMicroelectronics TPM Linux driver for TPM ST33ZP24
4 * Copyright (C) 2009 - 2016 STMicroelectronics
7 #ifndef __LOCAL_ST33ZP24_H__
8 #define __LOCAL_ST33ZP24_H__
10 #define TPM_WRITE_DIRECTION 0x80
11 #define ST33ZP24_BUFSIZE 2048
14 struct tpm_chip *chip;
16 const struct st33zp24_phy_ops *ops;
21 wait_queue_head_t read_queue;
25 struct st33zp24_phy_ops {
26 int (*send)(void *phy_id, u8 tpm_register, u8 *tpm_data, int tpm_size);
27 int (*recv)(void *phy_id, u8 tpm_register, u8 *tpm_data, int tpm_size);
30 #ifdef CONFIG_PM_SLEEP
31 int st33zp24_pm_suspend(struct device *dev);
32 int st33zp24_pm_resume(struct device *dev);
35 int st33zp24_probe(void *phy_id, const struct st33zp24_phy_ops *ops,
36 struct device *dev, int irq, int io_lpcpd);
37 int st33zp24_remove(struct tpm_chip *chip);
38 #endif /* __LOCAL_ST33ZP24_H__ */