Centos-kernel-stream-9/drivers/tty
Scott Weaver 797dccd11c Merge: CVE-2024-40966 kernel: tty: add the option to have a tty reject a new ldisc
MR: https://gitlab.com/redhat/centos-stream/src/kernel/centos-stream-9/-/merge_requests/4777

# Merge Request Required Information

## Summary of Changes

tty: add the option to have a tty reject a new ldisc

## Approved Development Ticket

JIRA: https://issues.redhat.com/browse/RHEL-48254

CVE: CVE-2024-40966

tty: add the option to have a tty reject a new ldisc

... and use it to limit the virtual terminals to just N_TTY. They are
kind of special, and in particular, the "con_write()" routine violates
the "writes cannot sleep" rule that some ldiscs rely on.

This avoids the

BUG: sleeping function called from invalid context at kernel/printk/printk.c:2659

when N_GSM has been attached to a virtual console, and gsmld_write()
calls con_write() while holding a spinlock, and con_write() then tries
to get the console lock.

Signed-off-by: John W. Linville <linville@redhat.com>

Approved-by: Andrew Halaney <ahalaney@redhat.com>
Approved-by: Derek Barbosa <debarbos@redhat.com>
Approved-by: Jarod Wilson <jarod@redhat.com>
Approved-by: Tony Camuso <tcamuso@redhat.com>
Approved-by: CKI KWF Bot <cki-ci-bot+kwf-gitlab-com@redhat.com>

Merged-by: Scott Weaver <scweaver@redhat.com>
2024-08-02 10:38:20 -04:00
..
hvc
ipwireless
serdev
serial serial: port: Don't block system suspend even if bytes are left to xmit 2024-06-24 15:22:21 -05:00
vt tty: add the option to have a tty reject a new ldisc 2024-07-19 19:37:50 -04:00
Kconfig
Makefile
amiserial.c
ehv_bytechan.c
goldfish.c
mips_ejtag_fdc.c
moxa.c
mxser.c
n_gsm.c
n_hdlc.c
n_null.c
n_tty.c
nozomi.c
pty.c
rpmsg_tty.c
synclink_gt.c
sysrq.c
tty.h
tty_audit.c
tty_baudrate.c
tty_buffer.c
tty_io.c
tty_ioctl.c
tty_jobctrl.c
tty_ldisc.c tty: add the option to have a tty reject a new ldisc 2024-07-19 19:37:50 -04:00
tty_ldsem.c
tty_mutex.c
tty_port.c
ttynull.c
vcc.c