1 /* SPDX-License-Identifier: GPL-2.0-or-later */
2 /*
3  * Driver for OMAP-UART controller.
4  * Based on drivers/serial/8250.c
5  *
6  * Copyright (C) 2010 Texas Instruments.
7  *
8  * Authors:
9  *	Govindraj R	<govindraj.raja@ti.com>
10  *	Thara Gopinath	<thara@ti.com>
11  */
12 
13 #ifndef __OMAP_SERIAL_H__
14 #define __OMAP_SERIAL_H__
15 
16 #include <linux/serial_core.h>
17 #include <linux/device.h>
18 #include <linux/pm_qos.h>
19 
20 #define OMAP_SERIAL_DRIVER_NAME	"omap_uart"
21 
22 /*
23  * Use tty device name as ttyO, [O -> OMAP]
24  * in bootargs we specify as console=ttyO0 if uart1
25  * is used as console uart.
26  */
27 #define OMAP_SERIAL_NAME	"ttyO"
28 
29 struct omap_uart_port_info {
30 	bool			dma_enabled;	/* To specify DMA Mode */
31 	unsigned int		uartclk;	/* UART clock rate */
32 	upf_t			flags;		/* UPF_* flags */
33 	unsigned int		dma_rx_buf_size;
34 	unsigned int		dma_rx_timeout;
35 	unsigned int		autosuspend_timeout;
36 	unsigned int		dma_rx_poll_rate;
37 
38 	int (*get_context_loss_count)(struct device *);
39 	void (*enable_wakeup)(struct device *, bool);
40 };
41 
42 #endif /* __OMAP_SERIAL_H__ */
43