#include <linux/clk.h>
#include <linux/console.h>
#include <linux/module.h>
#include <linux/of_irq.h>
#include <linux/platform_device.h>
#include <linux/serial_core.h>
#include <linux/tty.h>
#include <linux/tty_flip.h>
#define USIO_NAME …
#define USIO_UART_DEV_NAME …
static struct uart_port mlb_usio_ports[CONFIG_SERIAL_MILBEAUT_USIO_PORTS];
#define RX …
#define TX …
static int mlb_usio_irq[CONFIG_SERIAL_MILBEAUT_USIO_PORTS][2];
#define MLB_USIO_REG_SMR …
#define MLB_USIO_REG_SCR …
#define MLB_USIO_REG_ESCR …
#define MLB_USIO_REG_SSR …
#define MLB_USIO_REG_DR …
#define MLB_USIO_REG_BGR …
#define MLB_USIO_REG_FCR …
#define MLB_USIO_REG_FBYTE …
#define MLB_USIO_SMR_SOE …
#define MLB_USIO_SMR_SBL …
#define MLB_USIO_SCR_TXE …
#define MLB_USIO_SCR_RXE …
#define MLB_USIO_SCR_TBIE …
#define MLB_USIO_SCR_TIE …
#define MLB_USIO_SCR_RIE …
#define MLB_USIO_SCR_UPCL …
#define MLB_USIO_ESCR_L_8BIT …
#define MLB_USIO_ESCR_L_5BIT …
#define MLB_USIO_ESCR_L_6BIT …
#define MLB_USIO_ESCR_L_7BIT …
#define MLB_USIO_ESCR_P …
#define MLB_USIO_ESCR_PEN …
#define MLB_USIO_ESCR_FLWEN …
#define MLB_USIO_SSR_TBI …
#define MLB_USIO_SSR_TDRE …
#define MLB_USIO_SSR_RDRF …
#define MLB_USIO_SSR_ORE …
#define MLB_USIO_SSR_FRE …
#define MLB_USIO_SSR_PE …
#define MLB_USIO_SSR_REC …
#define MLB_USIO_SSR_BRK …
#define MLB_USIO_FCR_FE1 …
#define MLB_USIO_FCR_FE2 …
#define MLB_USIO_FCR_FCL1 …
#define MLB_USIO_FCR_FCL2 …
#define MLB_USIO_FCR_FSET …
#define MLB_USIO_FCR_FTIE …
#define MLB_USIO_FCR_FDRQ …
#define MLB_USIO_FCR_FRIIE …
static void mlb_usio_stop_tx(struct uart_port *port)
{ … }
static void mlb_usio_tx_chars(struct uart_port *port)
{ … }
static void mlb_usio_start_tx(struct uart_port *port)
{ … }
static void mlb_usio_stop_rx(struct uart_port *port)
{ … }
static void mlb_usio_enable_ms(struct uart_port *port)
{ … }
static void mlb_usio_rx_chars(struct uart_port *port)
{ … }
static irqreturn_t mlb_usio_rx_irq(int irq, void *dev_id)
{ … }
static irqreturn_t mlb_usio_tx_irq(int irq, void *dev_id)
{ … }
static unsigned int mlb_usio_tx_empty(struct uart_port *port)
{ … }
static void mlb_usio_set_mctrl(struct uart_port *port, unsigned int mctrl)
{ … }
static unsigned int mlb_usio_get_mctrl(struct uart_port *port)
{ … }
static void mlb_usio_break_ctl(struct uart_port *port, int break_state)
{ … }
static int mlb_usio_startup(struct uart_port *port)
{ … }
static void mlb_usio_shutdown(struct uart_port *port)
{ … }
static void mlb_usio_set_termios(struct uart_port *port,
struct ktermios *termios,
const struct ktermios *old)
{ … }
static const char *mlb_usio_type(struct uart_port *port)
{ … }
static void mlb_usio_config_port(struct uart_port *port, int flags)
{ … }
static const struct uart_ops mlb_usio_ops = …;
#ifdef CONFIG_SERIAL_MILBEAUT_USIO_CONSOLE
static void mlb_usio_console_putchar(struct uart_port *port, unsigned char c)
{ … }
static void mlb_usio_console_write(struct console *co, const char *s,
unsigned int count)
{ … }
static int __init mlb_usio_console_setup(struct console *co, char *options)
{ … }
static struct uart_driver mlb_usio_uart_driver;
static struct console mlb_usio_console = …;
static int __init mlb_usio_console_init(void)
{ … }
console_initcall(mlb_usio_console_init);
static void mlb_usio_early_console_write(struct console *co, const char *s,
u_int count)
{ … }
static int __init mlb_usio_early_console_setup(struct earlycon_device *device,
const char *opt)
{ … }
OF_EARLYCON_DECLARE(…);
#define USIO_CONSOLE …
#else
#define USIO_CONSOLE …
#endif
static struct uart_driver mlb_usio_uart_driver = …;
static int mlb_usio_probe(struct platform_device *pdev)
{ … }
static void mlb_usio_remove(struct platform_device *pdev)
{ … }
static const struct of_device_id mlb_usio_dt_ids[] = …;
MODULE_DEVICE_TABLE(of, mlb_usio_dt_ids);
static struct platform_driver mlb_usio_driver = …;
static int __init mlb_usio_init(void)
{ … }
static void __exit mlb_usio_exit(void)
{ … }
module_init(…) …;
module_exit(mlb_usio_exit);
MODULE_AUTHOR(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_LICENSE(…) …;