]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/alpha/kernel/srmcons.c
Merge branch 'drm-patches' of master.kernel.org:/pub/scm/linux/kernel/git/airlied...
[linux-2.6-omap-h63xx.git] / arch / alpha / kernel / srmcons.c
index 9d7dff27f81562e986064ff55d68d045cd8ca5fb..85a821aaceb47d68c822e3b656b471ded8a30d65 100644 (file)
@@ -164,9 +164,9 @@ srmcons_get_private_struct(struct srmcons_private **ps)
        int retval = 0;
 
        if (srmconsp == NULL) {
+               srmconsp = kmalloc(sizeof(*srmconsp), GFP_KERNEL);
                spin_lock_irqsave(&srmconsp_lock, flags);
 
-               srmconsp = kmalloc(sizeof(*srmconsp), GFP_KERNEL);
                if (srmconsp == NULL)
                        retval = -ENOMEM;
                else {
@@ -229,7 +229,7 @@ srmcons_close(struct tty_struct *tty, struct file *filp)
 
 static struct tty_driver *srmcons_driver;
 
-static struct tty_operations srmcons_ops = {
+static const struct tty_operations srmcons_ops = {
        .open           = srmcons_open,
        .close          = srmcons_close,
        .write          = srmcons_write,