#include <linux/bits.h>
#include <linux/console.h>
#include <linux/math.h>
#include <linux/module.h>
#include <linux/slab.h>
#include <linux/serial_core.h>
#include <linux/serial_reg.h>
#include <linux/of_address.h>
#include <linux/of_irq.h>
#include <linux/of_platform.h>
#include <linux/pm_runtime.h>
#include <linux/clk.h>
#include <linux/reset.h>
#include <linux/notifier.h>
#include "8250.h"
struct of_serial_info { … };
#define UART_NPCM_TOR …
#define UART_NPCM_TOIE …
static int npcm_startup(struct uart_port *port)
{ … }
static unsigned int npcm_get_divisor(struct uart_port *port, unsigned int baud,
unsigned int *frac)
{ … }
static int npcm_setup(struct uart_port *port)
{ … }
static inline struct of_serial_info *clk_nb_to_info(struct notifier_block *nb)
{ … }
static int of_platform_serial_clk_notifier_cb(struct notifier_block *nb, unsigned long event,
void *data)
{ … }
static int of_platform_serial_setup(struct platform_device *ofdev,
int type, struct uart_8250_port *up,
struct of_serial_info *info)
{ … }
static int of_platform_serial_probe(struct platform_device *ofdev)
{ … }
static void of_platform_serial_remove(struct platform_device *ofdev)
{ … }
#ifdef CONFIG_PM_SLEEP
static int of_serial_suspend(struct device *dev)
{ … }
static int of_serial_resume(struct device *dev)
{ … }
#endif
static SIMPLE_DEV_PM_OPS(of_serial_pm_ops, of_serial_suspend, of_serial_resume);
static const struct of_device_id of_platform_serial_table[] = …;
MODULE_DEVICE_TABLE(of, of_platform_serial_table);
static struct platform_driver of_platform_serial_driver = …;
module_platform_driver(…) …;
MODULE_AUTHOR(…) …;
MODULE_LICENSE(…) …;
MODULE_DESCRIPTION(…) …;