“3f57ff4f9c78ee0fafb010287019126ce8c1fc01”上不存在“drivers/pci/controller/vmd.c”
提交 6830f0ca 编写于 作者: J Jiri Slaby 提交者: Zheng Zengkai

tty: drivers/tty/, stop using tty_schedule_flip()

stable inclusion
from stable-v5.10.134
commit 6a81848252869d929354a879e08807c932444929
category: bugfix
bugzilla: https://gitee.com/src-openeuler/kernel/issues/I5A5Y1
CVE: CVE-2022-1462

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=6a81848252869d929354a879e08807c932444929

--------------------------------

commit 5f6a8515 upstream.

Since commit a9c3f68f (tty: Fix low_latency BUG) in 2014,
tty_flip_buffer_push() is only a wrapper to tty_schedule_flip(). We are
going to remove the latter (as it is used less), so call the former in
drivers/tty/.

Cc: Vladimir Zapolskiy <vz@mleia.com>
Reviewed-by: NJohan Hovold <johan@kernel.org>
Signed-off-by: NJiri Slaby <jslaby@suse.cz>
Link: https://lore.kernel.org/r/20211122111648.30379-2-jslaby@suse.czSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: NYi Yang <yiyang13@huawei.com>
Reviewed-by: NWang Weiyang <wangweiyang2@huawei.com>
Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
上级 6ebc45ae
...@@ -556,7 +556,7 @@ static void cyy_chip_rx(struct cyclades_card *cinfo, int chip, ...@@ -556,7 +556,7 @@ static void cyy_chip_rx(struct cyclades_card *cinfo, int chip,
} }
info->idle_stats.recv_idle = jiffies; info->idle_stats.recv_idle = jiffies;
} }
tty_schedule_flip(port); tty_flip_buffer_push(port);
/* end of service */ /* end of service */
cyy_writeb(info, CyRIR, save_xir & 0x3f); cyy_writeb(info, CyRIR, save_xir & 0x3f);
...@@ -996,7 +996,7 @@ static void cyz_handle_rx(struct cyclades_port *info) ...@@ -996,7 +996,7 @@ static void cyz_handle_rx(struct cyclades_port *info)
mod_timer(&info->rx_full_timer, jiffies + 1); mod_timer(&info->rx_full_timer, jiffies + 1);
#endif #endif
info->idle_stats.recv_idle = jiffies; info->idle_stats.recv_idle = jiffies;
tty_schedule_flip(&info->port); tty_flip_buffer_push(&info->port);
/* Update rx_get */ /* Update rx_get */
cy_writel(&buf_ctrl->rx_get, new_rx_get); cy_writel(&buf_ctrl->rx_get, new_rx_get);
...@@ -1172,7 +1172,7 @@ static void cyz_handle_cmd(struct cyclades_card *cinfo) ...@@ -1172,7 +1172,7 @@ static void cyz_handle_cmd(struct cyclades_card *cinfo)
if (delta_count) if (delta_count)
wake_up_interruptible(&info->port.delta_msr_wait); wake_up_interruptible(&info->port.delta_msr_wait);
if (special_count) if (special_count)
tty_schedule_flip(&info->port); tty_flip_buffer_push(&info->port);
} }
} }
......
...@@ -151,7 +151,7 @@ static irqreturn_t goldfish_tty_interrupt(int irq, void *dev_id) ...@@ -151,7 +151,7 @@ static irqreturn_t goldfish_tty_interrupt(int irq, void *dev_id)
address = (unsigned long)(void *)buf; address = (unsigned long)(void *)buf;
goldfish_tty_rw(qtty, address, count, 0); goldfish_tty_rw(qtty, address, count, 0);
tty_schedule_flip(&qtty->port); tty_flip_buffer_push(&qtty->port);
return IRQ_HANDLED; return IRQ_HANDLED;
} }
......
...@@ -1385,7 +1385,7 @@ static int moxa_poll_port(struct moxa_port *p, unsigned int handle, ...@@ -1385,7 +1385,7 @@ static int moxa_poll_port(struct moxa_port *p, unsigned int handle,
if (inited && !tty_throttled(tty) && if (inited && !tty_throttled(tty) &&
MoxaPortRxQueue(p) > 0) { /* RX */ MoxaPortRxQueue(p) > 0) { /* RX */
MoxaPortReadData(p); MoxaPortReadData(p);
tty_schedule_flip(&p->port); tty_flip_buffer_push(&p->port);
} }
} else { } else {
clear_bit(EMPTYWAIT, &p->statusflags); clear_bit(EMPTYWAIT, &p->statusflags);
...@@ -1410,7 +1410,7 @@ static int moxa_poll_port(struct moxa_port *p, unsigned int handle, ...@@ -1410,7 +1410,7 @@ static int moxa_poll_port(struct moxa_port *p, unsigned int handle,
if (tty && (intr & IntrBreak) && !I_IGNBRK(tty)) { /* BREAK */ if (tty && (intr & IntrBreak) && !I_IGNBRK(tty)) { /* BREAK */
tty_insert_flip_char(&p->port, 0, TTY_BREAK); tty_insert_flip_char(&p->port, 0, TTY_BREAK);
tty_schedule_flip(&p->port); tty_flip_buffer_push(&p->port);
} }
if (intr & IntrLine) if (intr & IntrLine)
......
...@@ -344,7 +344,7 @@ static irqreturn_t serial_lpc32xx_interrupt(int irq, void *dev_id) ...@@ -344,7 +344,7 @@ static irqreturn_t serial_lpc32xx_interrupt(int irq, void *dev_id)
LPC32XX_HSUART_IIR(port->membase)); LPC32XX_HSUART_IIR(port->membase));
port->icount.overrun++; port->icount.overrun++;
tty_insert_flip_char(tport, 0, TTY_OVERRUN); tty_insert_flip_char(tport, 0, TTY_OVERRUN);
tty_schedule_flip(tport); tty_flip_buffer_push(tport);
} }
/* Data received? */ /* Data received? */
......
...@@ -311,7 +311,7 @@ int kbd_rate(struct kbd_repeat *rpt) ...@@ -311,7 +311,7 @@ int kbd_rate(struct kbd_repeat *rpt)
static void put_queue(struct vc_data *vc, int ch) static void put_queue(struct vc_data *vc, int ch)
{ {
tty_insert_flip_char(&vc->port, ch, 0); tty_insert_flip_char(&vc->port, ch, 0);
tty_schedule_flip(&vc->port); tty_flip_buffer_push(&vc->port);
} }
static void puts_queue(struct vc_data *vc, char *cp) static void puts_queue(struct vc_data *vc, char *cp)
...@@ -320,7 +320,7 @@ static void puts_queue(struct vc_data *vc, char *cp) ...@@ -320,7 +320,7 @@ static void puts_queue(struct vc_data *vc, char *cp)
tty_insert_flip_char(&vc->port, *cp, 0); tty_insert_flip_char(&vc->port, *cp, 0);
cp++; cp++;
} }
tty_schedule_flip(&vc->port); tty_flip_buffer_push(&vc->port);
} }
static void applkey(struct vc_data *vc, int key, char mode) static void applkey(struct vc_data *vc, int key, char mode)
...@@ -565,7 +565,7 @@ static void fn_inc_console(struct vc_data *vc) ...@@ -565,7 +565,7 @@ static void fn_inc_console(struct vc_data *vc)
static void fn_send_intr(struct vc_data *vc) static void fn_send_intr(struct vc_data *vc)
{ {
tty_insert_flip_char(&vc->port, 0, TTY_BREAK); tty_insert_flip_char(&vc->port, 0, TTY_BREAK);
tty_schedule_flip(&vc->port); tty_flip_buffer_push(&vc->port);
} }
static void fn_scroll_forw(struct vc_data *vc) static void fn_scroll_forw(struct vc_data *vc)
......
...@@ -1834,7 +1834,7 @@ static void csi_m(struct vc_data *vc) ...@@ -1834,7 +1834,7 @@ static void csi_m(struct vc_data *vc)
static void respond_string(const char *p, size_t len, struct tty_port *port) static void respond_string(const char *p, size_t len, struct tty_port *port)
{ {
tty_insert_flip_string(port, p, len); tty_insert_flip_string(port, p, len);
tty_schedule_flip(port); tty_flip_buffer_push(port);
} }
static void cursor_report(struct vc_data *vc, struct tty_struct *tty) static void cursor_report(struct vc_data *vc, struct tty_struct *tty)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册