Skip to content

Commit 756c0ae

Browse files
committed
Merge tag 'tty-4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty
Pull tty fixes from Greg KH: "Here are two tty fixes for some reported issues. One resolves a crash in devpts, and the other resolves a problem with the fbcon cursor blink causing lockups. Both have been in linux-next with no reported problems" * tag 'tty-4.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty: devpts: fix null pointer dereference on failed memory allocation tty: vt: Fix soft lockup in fbcon cursor blink timer.
2 parents 0232b23 + 5353ed8 commit 756c0ae

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

drivers/tty/pty.c

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -667,8 +667,11 @@ static void pty_unix98_remove(struct tty_driver *driver, struct tty_struct *tty)
667667
fsi = tty->driver_data;
668668
else
669669
fsi = tty->link->driver_data;
670-
devpts_kill_index(fsi, tty->index);
671-
devpts_release(fsi);
670+
671+
if (fsi) {
672+
devpts_kill_index(fsi, tty->index);
673+
devpts_release(fsi);
674+
}
672675
}
673676

674677
static const struct tty_operations ptm_unix98_ops = {

drivers/tty/vt/vt.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -750,6 +750,7 @@ static void visual_init(struct vc_data *vc, int num, int init)
750750
vc->vc_complement_mask = 0;
751751
vc->vc_can_do_color = 0;
752752
vc->vc_panic_force_write = false;
753+
vc->vc_cur_blink_ms = DEFAULT_CURSOR_BLINK_MS;
753754
vc->vc_sw->con_init(vc, init);
754755
if (!vc->vc_complement_mask)
755756
vc->vc_complement_mask = vc->vc_can_do_color ? 0x7700 : 0x0800;

0 commit comments

Comments
 (0)