diff options
Diffstat (limited to 'drivers/tty/vcc.c')
| -rw-r--r-- | drivers/tty/vcc.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/tty/vcc.c b/drivers/tty/vcc.c index 27a55465b..9adb533f7 100644 --- a/drivers/tty/vcc.c +++ b/drivers/tty/vcc.c @@ -492,7 +492,7 @@ static ssize_t domain_show(struct device *dev, static int vcc_send_ctl(struct vcc_port *port, int ctl) { - struct vio_vcc pkt; + struct vio_vcc pkt = {}; int rv; pkt.tag.type = VIO_TYPE_CTRL; @@ -986,7 +986,8 @@ static void vcc_cleanup(struct tty_struct *tty) port = vcc_get(tty->index, true); if (port) { - port->tty = NULL; + scoped_guard(spinlock_irqsave, &port->lock) + port->tty = NULL; if (port->removed) { vcc_table_remove(tty->index); |
