#include <linux/init.h>
#include <linux/module.h>
#include <linux/moduleparam.h>
#include <linux/slab.h>
#include <linux/i2c.h>
#include "tpm.h"
#define I2C_DRIVER_NAME …
#define TPM_I2C_SHORT_TIMEOUT …
#define TPM_I2C_LONG_TIMEOUT …
#define ATMEL_STS_OK …
struct priv_data { … };
static int i2c_atmel_send(struct tpm_chip *chip, u8 *buf, size_t len)
{ … }
static int i2c_atmel_recv(struct tpm_chip *chip, u8 *buf, size_t count)
{ … }
static void i2c_atmel_cancel(struct tpm_chip *chip)
{ … }
static u8 i2c_atmel_read_status(struct tpm_chip *chip)
{ … }
static bool i2c_atmel_req_canceled(struct tpm_chip *chip, u8 status)
{ … }
static const struct tpm_class_ops i2c_atmel = …;
static int i2c_atmel_probe(struct i2c_client *client)
{ … }
static void i2c_atmel_remove(struct i2c_client *client)
{ … }
static const struct i2c_device_id i2c_atmel_id[] = …;
MODULE_DEVICE_TABLE(i2c, i2c_atmel_id);
#ifdef CONFIG_OF
static const struct of_device_id i2c_atmel_of_match[] = …;
MODULE_DEVICE_TABLE(of, i2c_atmel_of_match);
#endif
static SIMPLE_DEV_PM_OPS(i2c_atmel_pm_ops, tpm_pm_suspend, tpm_pm_resume);
static struct i2c_driver i2c_atmel_driver = …;
module_i2c_driver(…) …;
MODULE_AUTHOR(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_LICENSE(…) …;