VirtualBox

Changeset 77957 in vbox for trunk


Ignore:
Timestamp:
Mar 29, 2019 6:05:32 PM (6 years ago)
Author:
vboxsync
Message:

Additions/linux/vboxvideo: make driver work with Linux 5.1. Clean up previous.
bugref:4567: Linux kernel driver maintenance.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/linux/drm/vbox_main.c

    r77850 r77957  
    606606#endif
    607607
    608 #if LINUX_VERSION_CODE < KERNEL_VERSION(5, 1, 0)
    609 static void vbox_bo_unref(struct vbox_bo **bo)
    610 {
    611         struct ttm_buffer_object *tbo;
    612 
    613         if ((*bo) == NULL)
    614                 return;
    615 
    616         tbo = &((*bo)->bo);
    617         ttm_bo_unref(&tbo);
    618         if (!tbo)
    619                 *bo = NULL;
     608#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 19, 0)
     609static void ttm_bo_put(struct ttm_buffer_object *bo)
     610{
     611        ttm_bo_unref(&bo);
    620612}
    621613#endif
     
    625617        struct vbox_bo *vbox_bo = gem_to_vbox_bo(obj);
    626618
    627 #if LINUX_VERSION_CODE < KERNEL_VERSION(5, 1, 0)
    628         vbox_bo_unref(&vbox_bo);
    629 #else
    630619        ttm_bo_put(&vbox_bo->bo);
    631 #endif
    632620}
    633621
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