#include <linux/acpi.h>
#include <linux/mod_devicetable.h>
#include <linux/module.h>
#include <linux/platform_data/cros_ec_proto.h>
#include <linux/platform_data/cros_usbpd_notify.h>
#include <linux/platform_device.h>
#define DRV_NAME …
#define DRV_NAME_PLAT_ACPI …
#define ACPI_DRV_NAME …
static BLOCKING_NOTIFIER_HEAD(cros_usbpd_notifier_list);
struct cros_usbpd_notify_data { … };
int cros_usbpd_register_notify(struct notifier_block *nb)
{ … }
EXPORT_SYMBOL_GPL(…);
void cros_usbpd_unregister_notify(struct notifier_block *nb)
{ … }
EXPORT_SYMBOL_GPL(…);
static void cros_usbpd_get_event_and_notify(struct device *dev,
struct cros_ec_device *ec_dev)
{ … }
#ifdef CONFIG_ACPI
static void cros_usbpd_notify_acpi(acpi_handle device, u32 event, void *data)
{ … }
static int cros_usbpd_notify_probe_acpi(struct platform_device *pdev)
{ … }
static void cros_usbpd_notify_remove_acpi(struct platform_device *pdev)
{ … }
static const struct acpi_device_id cros_usbpd_notify_acpi_device_ids[] = …;
MODULE_DEVICE_TABLE(acpi, cros_usbpd_notify_acpi_device_ids);
static struct platform_driver cros_usbpd_notify_acpi_driver = …;
#endif
static int cros_usbpd_notify_plat(struct notifier_block *nb,
unsigned long queued_during_suspend,
void *data)
{ … }
static int cros_usbpd_notify_probe_plat(struct platform_device *pdev)
{ … }
static void cros_usbpd_notify_remove_plat(struct platform_device *pdev)
{ … }
static const struct platform_device_id cros_usbpd_notify_id[] = …;
MODULE_DEVICE_TABLE(platform, cros_usbpd_notify_id);
static struct platform_driver cros_usbpd_notify_plat_driver = …;
static int __init cros_usbpd_notify_init(void)
{ … }
static void __exit cros_usbpd_notify_exit(void)
{ … }
module_init(…) …;
module_exit(cros_usbpd_notify_exit);
MODULE_LICENSE(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_AUTHOR(…) …;