VirtualBox

Changeset 80712 in vbox for trunk/src/VBox/Additions/linux


Ignore:
Timestamp:
Sep 10, 2019 7:25:36 PM (5 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
133253
Message:

Additions/linux: ticketref:18917: VBox 6.0.10 GAs fail to compile on Red Hat/CentOS/OL 7.7; also Red Hat 8.1 Beta

Location:
trunk/src/VBox/Additions/linux
Files:
7 edited

Legend:

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

    r79690 r80712  
    4242#include "vbox_drv.h"
    4343
    44 #if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 1, 0)
     44#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 1, 0) || defined(RHEL_81)
    4545#include <drm/drm_probe_helper.h>
    4646#endif
     
    308308        .driver_features =
    309309            DRIVER_MODESET | DRIVER_GEM | DRIVER_HAVE_IRQ |
    310 #if LINUX_VERSION_CODE < KERNEL_VERSION(5, 1, 0)
     310#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 1, 0) && !defined(RHEL_81)
    311311            DRIVER_IRQ_SHARED |
    312312#endif
  • trunk/src/VBox/Additions/linux/drm/vbox_drv.h

    r79025 r80712  
    5151
    5252#if defined(RHEL_MAJOR) && defined(RHEL_MINOR)
     53# if RHEL_MAJOR == 8 && RHEL_MINOR >= 1
     54#  define RHEL_81
     55# endif
     56# if RHEL_MAJOR == 8 && RHEL_MINOR >= 0
     57#  define RHEL_80
     58# endif
     59# if RHEL_MAJOR == 7 && RHEL_MINOR >= 7
     60#  define RHEL_77
     61# endif
    5362# if RHEL_MAJOR == 7 && RHEL_MINOR >= 6
    5463#  define RHEL_76
     
    188197
    189198        struct {
    190 #if LINUX_VERSION_CODE < KERNEL_VERSION(5, 0, 0)
     199#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 0, 0) && !defined(RHEL_77) && !defined(RHEL_81)
    191200                struct drm_global_reference mem_global_ref;
    192201                struct ttm_bo_global_ref bo_global_ref;
  • trunk/src/VBox/Additions/linux/drm/vbox_irq.c

    r77850 r80712  
    3636#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 1, 0)
    3737#include <drm/drm_crtc_helper.h>
     38# if defined(RHEL_81)
     39#  include <drm/drm_probe_helper.h>
     40# endif
    3841#else
    3942#include <drm/drm_probe_helper.h>
  • trunk/src/VBox/Additions/linux/drm/vbox_main.c

    r79025 r80712  
    606606#endif
    607607
    608 #if LINUX_VERSION_CODE < KERNEL_VERSION(4, 19, 0) && !defined(OPENSUSE_151)
     608#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 19, 0) && !defined(OPENSUSE_151) && !defined(RHEL_77) && !defined(RHEL_81)
    609609static void ttm_bo_put(struct ttm_buffer_object *bo)
    610610{
  • trunk/src/VBox/Additions/linux/drm/vbox_mode.c

    r79694 r80712  
    4343#include <drm/drm_plane_helper.h>
    4444#endif
    45 #if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 1, 0)
     45#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 1, 0) || defined(RHEL_81)
    4646#include <drm/drm_probe_helper.h>
    4747#endif
     
    541541                sum += edid[i];
    542542        edid[EDID_SIZE - 1] = (0x100 - (sum & 0xFF)) & 0xFF;
    543 #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 19, 0) || defined(OPENSUSE_151)
     543#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 19, 0) || defined(OPENSUSE_151) || defined(RHEL_77) || defined(RHEL_81)
    544544        drm_connector_update_edid_property(connector, (struct edid *)edid);
    545545#else
     
    716716#endif
    717717
    718 #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 19, 0) || defined(OPENSUSE_151)
     718#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 19, 0) || defined(OPENSUSE_151) || defined(RHEL_77) || defined(RHEL_81)
    719719        drm_connector_attach_encoder(connector, encoder);
    720720#else
  • trunk/src/VBox/Additions/linux/drm/vbox_ttm.c

    r80270 r80712  
    4747}
    4848
    49 #if LINUX_VERSION_CODE < KERNEL_VERSION(5, 0, 0)
     49#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 0, 0) && !defined(RHEL_77) && !defined(RHEL_81)
    5050static int vbox_ttm_mem_global_init(struct drm_global_reference *ref)
    5151{
     
    298298        struct ttm_bo_device *bdev = &vbox->ttm.bdev;
    299299
    300 #if LINUX_VERSION_CODE < KERNEL_VERSION(5, 0, 0)
     300#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 0, 0) && !defined(RHEL_77) && !defined(RHEL_81)
    301301        ret = vbox_ttm_global_init(vbox);
    302302        if (ret)
     
    304304#endif
    305305        ret = ttm_bo_device_init(&vbox->ttm.bdev,
    306 #if LINUX_VERSION_CODE < KERNEL_VERSION(5, 0, 0)
     306#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 0, 0) && !defined(RHEL_77) && !defined(RHEL_81)
    307307                                 vbox->ttm.bo_global_ref.ref.object,
    308308#endif
     
    318318        if (ret) {
    319319                DRM_ERROR("Error initialising bo driver; %d\n", ret);
    320 #if LINUX_VERSION_CODE < KERNEL_VERSION(5, 0, 0)
     320#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 0, 0) && !defined(RHEL_77) && !defined(RHEL_81)
    321321                goto err_ttm_global_release;
    322322#else
     
    344344err_device_release:
    345345        ttm_bo_device_release(&vbox->ttm.bdev);
    346 #if LINUX_VERSION_CODE < KERNEL_VERSION(5, 0, 0)
     346#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 0, 0) && !defined(RHEL_77) && !defined(RHEL_81)
    347347err_ttm_global_release:
    348348        vbox_ttm_global_release(vbox);
     
    361361#endif
    362362        ttm_bo_device_release(&vbox->ttm.bdev);
    363 #if LINUX_VERSION_CODE < KERNEL_VERSION(5, 0, 0)
     363#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 0, 0) && !defined(RHEL_77) && !defined(RHEL_81)
    364364        vbox_ttm_global_release(vbox);
    365365#endif
  • trunk/src/VBox/Additions/linux/sharedfolders/regops.c

    r80582 r80712  
    8080#endif
    8181
     82#ifdef RHEL_RELEASE_CODE
     83# if RHEL_RELEASE_CODE >= RHEL_RELEASE_VERSION(8, 1)
     84#  define RHEL_81
     85# endif
     86#endif
    8287
    8388/*********************************************************************************************************************************
     
    14091414     * Check that this is valid user memory that is actually in the kernel range.
    14101415     */
    1411 #if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 0, 0)
     1416#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 0, 0) || defined(RHEL_81)
    14121417    if (   access_ok((void *)uPtrFrom, cPages << PAGE_SHIFT)
    14131418        && uPtrFrom >= USER_DS.seg)
Note: See TracChangeset for help on using the changeset viewer.

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