Merge tag 'tty-4.14-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty
Pull tty/serial updates from Greg KH: "Here is the big tty/serial driver update for 4.14-rc1. Well, not all that big, just a number of small serial driver fixes, and a new serial driver. Also in here are some much needed goldfish tty driver (emulator) fixes to try to get that codebase under control. All of these have been in linux-next for a while with no reported issues" * tag 'tty-4.14-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty: (94 commits) tty: goldfish: Implement support for kernel 'earlycon' parameter tty: goldfish: Use streaming DMA for r/w operations on Ranchu platforms tty: goldfish: Refactor constants to better reflect their nature serial: 8250_port: Remove useless NULL checks earlycon: initialise baud field of earlycon device structure tty: hvcs: make ktermios const pty: show associative slave of ptmx in fdinfo tty: n_gsm: Add compat_ioctl tty: hvcs: constify vio_device_id tty: hvc_vio: constify vio_device_id tty: mips_ejtag_fdc: constify mips_cdmm_device_id Introduce 8250_men_mcb mcb: introduce mcb_get_resource() serial: imx: Avoid post-PIO cleanup if TX DMA is started tty: serial: imx: disable irq after suspend serial: 8250_uniphier: add suspend/resume support serial: 8250_uniphier: use CHAR register for canary to detect power-off serial: 8250_uniphier: fix serial port index in private data serial: 8250: of: Add new port type for MediaTek BTIF controller on MT7622/23 SoC dt-bindings: serial: 8250: Add MediaTek BTIF controller bindings ...
This commit is contained in:
@@ -136,5 +136,7 @@ extern struct resource *mcb_request_mem(struct mcb_device *dev,
|
||||
const char *name);
|
||||
extern void mcb_release_mem(struct resource *mem);
|
||||
extern int mcb_get_irq(struct mcb_device *dev);
|
||||
extern struct resource *mcb_get_resource(struct mcb_device *dev,
|
||||
unsigned int type);
|
||||
|
||||
#endif /* _LINUX_MCB_H */
|
||||
|
@@ -80,9 +80,10 @@ struct uart_8250_ops {
|
||||
};
|
||||
|
||||
struct uart_8250_em485 {
|
||||
struct timer_list start_tx_timer; /* "rs485 start tx" timer */
|
||||
struct timer_list stop_tx_timer; /* "rs485 stop tx" timer */
|
||||
struct timer_list *active_timer; /* pointer to active timer */
|
||||
struct hrtimer start_tx_timer; /* "rs485 start tx" timer */
|
||||
struct hrtimer stop_tx_timer; /* "rs485 stop tx" timer */
|
||||
struct hrtimer *active_timer; /* pointer to active timer */
|
||||
struct uart_8250_port *port; /* for hrtimer callbacks */
|
||||
};
|
||||
|
||||
/*
|
||||
|
@@ -20,7 +20,7 @@
|
||||
#ifndef LINUX_SERIAL_CORE_H
|
||||
#define LINUX_SERIAL_CORE_H
|
||||
|
||||
|
||||
#include <linux/bitops.h>
|
||||
#include <linux/compiler.h>
|
||||
#include <linux/interrupt.h>
|
||||
#include <linux/circ_buf.h>
|
||||
@@ -144,7 +144,7 @@ struct uart_port {
|
||||
unsigned char x_char; /* xon/xoff char */
|
||||
unsigned char regshift; /* reg offset shift */
|
||||
unsigned char iotype; /* io access style */
|
||||
unsigned char unused1;
|
||||
unsigned char quirks; /* internal quirks */
|
||||
|
||||
#define UPIO_PORT (SERIAL_IO_PORT) /* 8b I/O port access */
|
||||
#define UPIO_HUB6 (SERIAL_IO_HUB6) /* Hub6 ISA card */
|
||||
@@ -155,6 +155,9 @@ struct uart_port {
|
||||
#define UPIO_MEM32BE (SERIAL_IO_MEM32BE) /* 32b big endian */
|
||||
#define UPIO_MEM16 (SERIAL_IO_MEM16) /* 16b little endian */
|
||||
|
||||
/* quirks must be updated while holding port mutex */
|
||||
#define UPQ_NO_TXEN_TEST BIT(0)
|
||||
|
||||
unsigned int read_status_mask; /* driver specific */
|
||||
unsigned int ignore_status_mask; /* driver specific */
|
||||
struct uart_state *state; /* pointer to parent state */
|
||||
@@ -175,7 +178,6 @@ struct uart_port {
|
||||
* [for bit definitions in the UPF_CHANGE_MASK]
|
||||
*
|
||||
* Bits [0..UPF_LAST_USER] are userspace defined/visible/changeable
|
||||
* except bit 15 (UPF_NO_TXEN_TEST) which is masked off.
|
||||
* The remaining bits are serial-core specific and not modifiable by
|
||||
* userspace.
|
||||
*/
|
||||
@@ -192,7 +194,6 @@ struct uart_port {
|
||||
#define UPF_SPD_SHI ((__force upf_t) ASYNC_SPD_SHI /* 12 */ )
|
||||
#define UPF_LOW_LATENCY ((__force upf_t) ASYNC_LOW_LATENCY /* 13 */ )
|
||||
#define UPF_BUGGY_UART ((__force upf_t) ASYNC_BUGGY_UART /* 14 */ )
|
||||
#define UPF_NO_TXEN_TEST ((__force upf_t) (1 << 15))
|
||||
#define UPF_MAGIC_MULTIPLIER ((__force upf_t) ASYNC_MAGIC_MULTIPLIER /* 16 */ )
|
||||
|
||||
#define UPF_NO_THRE_TEST ((__force upf_t) (1 << 19))
|
||||
@@ -246,7 +247,6 @@ struct uart_port {
|
||||
struct device *dev; /* parent device */
|
||||
unsigned char hub6; /* this should be in the 8250 driver */
|
||||
unsigned char suspended;
|
||||
unsigned char irq_wake;
|
||||
unsigned char unused[2];
|
||||
const char *name; /* port name */
|
||||
struct attribute_group *attr_group; /* port specific attributes */
|
||||
|
@@ -243,6 +243,7 @@
|
||||
#include <linux/list.h>
|
||||
#include <linux/cdev.h>
|
||||
#include <linux/termios.h>
|
||||
#include <linux/seq_file.h>
|
||||
|
||||
struct tty_struct;
|
||||
struct tty_driver;
|
||||
@@ -285,6 +286,7 @@ struct tty_operations {
|
||||
int (*set_termiox)(struct tty_struct *tty, struct termiox *tnew);
|
||||
int (*get_icount)(struct tty_struct *tty,
|
||||
struct serial_icounter_struct *icount);
|
||||
void (*show_fdinfo)(struct tty_struct *tty, struct seq_file *m);
|
||||
#ifdef CONFIG_CONSOLE_POLL
|
||||
int (*poll_init)(struct tty_driver *driver, int line, char *options);
|
||||
int (*poll_get_char)(struct tty_driver *driver, int line);
|
||||
|
@@ -12,6 +12,7 @@ extern int tty_prepare_flip_string(struct tty_port *port,
|
||||
unsigned char **chars, size_t size);
|
||||
extern void tty_flip_buffer_push(struct tty_port *port);
|
||||
void tty_schedule_flip(struct tty_port *port);
|
||||
int __tty_insert_flip_char(struct tty_port *port, unsigned char ch, char flag);
|
||||
|
||||
static inline int tty_insert_flip_char(struct tty_port *port,
|
||||
unsigned char ch, char flag)
|
||||
@@ -26,7 +27,7 @@ static inline int tty_insert_flip_char(struct tty_port *port,
|
||||
*char_buf_ptr(tb, tb->used++) = ch;
|
||||
return 1;
|
||||
}
|
||||
return tty_insert_flip_string_flags(port, &ch, &flag, 1);
|
||||
return __tty_insert_flip_char(port, ch, flag);
|
||||
}
|
||||
|
||||
static inline int tty_insert_flip_string(struct tty_port *port,
|
||||
|
Reference in New Issue
Block a user