VirtualBox

Ignore:
Timestamp:
Jun 9, 2016 6:11:14 AM (9 years ago)
Author:
vboxsync
Message:

bugref:4567: Linux kernel driver maintenance:
drm/vboxvideo: Initialize data needed to map fbdev memory

Due to a missing initialization there was no way to map fbdev memory.
Thus for example using the Xserver with the fbdev driver failed.
This fix adds initialization for fix.smem_start and fix.smem_len
in the fb_info structure, which fixes this problem.

Signed-off-by: Egbert Eich <eich@…>
Signed-off-by: Egbert Eich <eich@…>

Location:
trunk/src/VBox/Additions/linux/drm
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/linux/drm/vbox_drv.h

    r61431 r61596  
    228228void vbox_fbdev_fini(struct drm_device *dev);
    229229void vbox_fbdev_set_suspend(struct drm_device *dev, int state);
     230void vbox_fbdev_set_base(struct vbox_private *vbox, unsigned long gpu_addr);
    230231
    231232struct vbox_bo {
  • trunk/src/VBox/Additions/linux/drm/vbox_fb.c

    r61431 r61596  
    452452    fb_set_suspend(vbox->fbdev->helper.fbdev, state);
    453453}
     454
     455void vbox_fbdev_set_base(struct vbox_private *vbox, unsigned long gpu_addr)
     456{
     457        vbox->fbdev->helper.fbdev->fix.smem_start =
     458                vbox->fbdev->helper.fbdev->apertures->ranges[0].base +
     459                gpu_addr;
     460        vbox->fbdev->helper.fbdev->fix.smem_len = vbox->vram_size - gpu_addr;
     461}
  • trunk/src/VBox/Additions/linux/drm/vbox_mode.c

    r61431 r61596  
    225225        if (ret)
    226226            DRM_ERROR("failed to kmap fbcon\n");
     227        else
     228            vbox_fbdev_set_base(vbox, gpu_addr);
    227229    }
    228230    vbox_bo_unreserve(bo);
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette