#include <linux/ktime.h>
#include <linux/math64.h>
#include <linux/mod_devicetable.h>
#include <linux/module.h>
#include <linux/platform_data/cros_ec_commands.h>
#include <linux/platform_data/cros_ec_proto.h>
#include <linux/platform_device.h>
#include <linux/rtc.h>
#define DRV_NAME …
#define CROS_USBPD_MAX_LOG_ENTRIES …
#define CROS_USBPD_LOG_UPDATE_DELAY …
#define CROS_USBPD_DATA_SIZE …
#define CROS_USBPD_LOG_RESP_SIZE …
#define CROS_USBPD_BUFFER_SIZE …
#define BUF_SIZE …
struct logger_data { … };
static const char * const chg_type_names[] = …;
static const char * const role_names[] = …;
static const char * const fault_names[] = …;
__printf(3, 4)
static int append_str(char *buf, int pos, const char *fmt, ...)
{ … }
static struct ec_response_pd_log *ec_get_log_entry(struct logger_data *logger)
{ … }
static void cros_usbpd_print_log_entry(struct ec_response_pd_log *r,
ktime_t tstamp)
{ … }
static void cros_usbpd_log_check(struct work_struct *work)
{ … }
static int cros_usbpd_logger_probe(struct platform_device *pd)
{ … }
static void cros_usbpd_logger_remove(struct platform_device *pd)
{ … }
static int __maybe_unused cros_usbpd_logger_resume(struct device *dev)
{ … }
static int __maybe_unused cros_usbpd_logger_suspend(struct device *dev)
{ … }
static SIMPLE_DEV_PM_OPS(cros_usbpd_logger_pm_ops, cros_usbpd_logger_suspend,
cros_usbpd_logger_resume);
static const struct platform_device_id cros_usbpd_logger_id[] = …;
MODULE_DEVICE_TABLE(platform, cros_usbpd_logger_id);
static struct platform_driver cros_usbpd_logger_driver = …;
module_platform_driver(…) …;
MODULE_LICENSE(…) …;
MODULE_DESCRIPTION(…) …;