drm/cirrus: Fix cirrus drm driver for fbdev + qemu
authorMartin Koegler <martin.koegler@chello.at>
Thu, 9 Jan 2014 09:05:07 +0000 (10:05 +0100)
committerDave Airlie <airlied@redhat.com>
Mon, 13 Jan 2014 04:15:04 +0000 (14:15 +1000)
Xorg fbdev driver requires smem_start/smem_len, otherwise
it tries to map 0 bytes as video memory.

Bugzilla: https://bugzilla.novell.com/show_bug.cgi?id=856760
Signed-off-by: Martin Koegler <martin.koegler@chello.at>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Dave Airlie <airlied@redhat.com>
drivers/gpu/drm/cirrus/cirrus_fbdev.c

index b27e956..e63a753 100644 (file)
@@ -233,6 +233,9 @@ static int cirrusfb_create(struct drm_fb_helper *helper,
        info->apertures->ranges[0].base = cdev->dev->mode_config.fb_base;
        info->apertures->ranges[0].size = cdev->mc.vram_size;
 
+       info->fix.smem_start = cdev->dev->mode_config.fb_base;
+       info->fix.smem_len = cdev->mc.vram_size;
+
        info->screen_base = sysram;
        info->screen_size = size;