drm/cirrus/ast/mgag200: fix build without CONFIG_VGA_CONSOLE
authorDave Airlie <airlied@redhat.com>
Sat, 19 May 2012 15:33:21 +0000 (16:33 +0100)
committerDave Airlie <airlied@redhat.com>
Sat, 19 May 2012 15:34:16 +0000 (16:34 +0100)
Reported-by: Randy Dunlap
Signed-off-by: Dave Airlie <airlied@redhat.com>
drivers/gpu/drm/ast/ast_drv.c
drivers/gpu/drm/cirrus/cirrus_drv.c
drivers/gpu/drm/mgag200/mgag200_drv.c

index b56eac6b155f17274e72258f660558ef685ea35b..d0c4574ef49c1d60b074643b278580a72ff8dc69 100644 (file)
@@ -221,8 +221,10 @@ static struct drm_driver driver = {
 
 static int __init ast_init(void)
 {
+#ifdef CONFIG_VGA_CONSOLE
        if (vgacon_text_force() && ast_modeset == -1)
                return -EINVAL;
+#endif
 
        if (ast_modeset == 0)
                return -EINVAL;
index 2e1f925b5caf2de542d90e12c3bde0910c7c13f2..d7038230b71e7f113e8ae453bce0327528de575a 100644 (file)
@@ -84,8 +84,10 @@ static struct pci_driver cirrus_pci_driver = {
 
 static int __init cirrus_init(void)
 {
+#ifdef CONFIG_VGA_CONSOLE
        if (vgacon_text_force() && cirrus_modeset == -1)
                return -EINVAL;
+#endif
 
        if (cirrus_modeset == 0)
                return -EINVAL;
index f03a636d769e7e312a0523251cfd12e255a58148..3c8e04f54713b7964c5c915f3b06ca1a70f54578 100644 (file)
@@ -93,8 +93,10 @@ static struct pci_driver mgag200_pci_driver = {
 
 static int __init mgag200_init(void)
 {
+#ifdef CONFIG_VGA_CONSOLE
        if (vgacon_text_force() && mgag200_modeset == -1)
                return -EINVAL;
+#endif
 
        if (mgag200_modeset == 0)
                return -EINVAL;