summaryrefslogtreecommitdiffstats
path: root/drivers/tty/vt
diff options
context:
space:
mode:
authorGreg Kroah-Hartman2014-11-10 04:42:04 +0100
committerGreg Kroah-Hartman2014-11-10 04:42:04 +0100
commit394e849b83463869e2267ea7acea002366e6fefc (patch)
tree917ec5c564964d781ffbda2917efdf7cde252c72 /drivers/tty/vt
parentserial: pl011: Add device tree support for RX DMA polling (diff)
parentLinux 3.18-rc4 (diff)
downloadkernel-qcow2-linux-394e849b83463869e2267ea7acea002366e6fefc.tar.gz
kernel-qcow2-linux-394e849b83463869e2267ea7acea002366e6fefc.tar.xz
kernel-qcow2-linux-394e849b83463869e2267ea7acea002366e6fefc.zip
Merge 3.18-rc4 into tty-next.
This resolves a merge issue with drivers/tty/serial/8250/8250_mtk.c Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/vt')
-rw-r--r--drivers/tty/vt/consolemap.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/tty/vt/consolemap.c b/drivers/tty/vt/consolemap.c
index 610b720d3b91..59b25e039968 100644
--- a/drivers/tty/vt/consolemap.c
+++ b/drivers/tty/vt/consolemap.c
@@ -539,6 +539,12 @@ int con_set_unimap(struct vc_data *vc, ushort ct, struct unipair __user *list)
/* Save original vc_unipagdir_loc in case we allocate a new one */
p = *vc->vc_uni_pagedir_loc;
+
+ if (!p) {
+ err = -EINVAL;
+
+ goto out_unlock;
+ }
if (p->refcount > 1) {
int j, k;
@@ -623,6 +629,7 @@ int con_set_unimap(struct vc_data *vc, ushort ct, struct unipair __user *list)
set_inverse_transl(vc, p, i); /* Update inverse translations */
set_inverse_trans_unicode(vc, p);
+out_unlock:
console_unlock();
return err;
}