1
0
forked from pool/virtualbox

Accepting request 734678 from home:lwfinger:branches:Virtualization

- Update file "fixes_for_5.4.patch" to handle removal of DRIVER_PRIME and rework of
  struct ttm_buffer_object. These are needed for Kernel_HEAD_standard.

OBS-URL: https://build.opensuse.org/request/show/734678
OBS-URL: https://build.opensuse.org/package/show/Virtualization/virtualbox?expand=0&rev=507
This commit is contained in:
Larry Finger 2019-10-02 22:12:15 +00:00 committed by Git OBS Bridge
parent 25fd248a04
commit 6f89660efe
2 changed files with 43 additions and 0 deletions

View File

@ -70,3 +70,40 @@ Index: VirtualBox-6.0.12/src/VBox/Runtime/r0drv/linux/thread2-r0drv-linux.c
RTDECL(RTTHREAD) RTThreadSelf(void)
{
Index: VirtualBox-6.0.12/src/VBox/Additions/linux/drm/vbox_drv.c
===================================================================
--- VirtualBox-6.0.12.orig/src/VBox/Additions/linux/drm/vbox_drv.c
+++ VirtualBox-6.0.12/src/VBox/Additions/linux/drm/vbox_drv.c
@@ -271,11 +271,13 @@ static void vbox_master_drop(struct drm_
static struct drm_driver driver = {
.driver_features =
- DRIVER_MODESET | DRIVER_GEM | DRIVER_HAVE_IRQ |
+#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 4, 0)
+ DRIVER_PRIME |
+#endif
#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 1, 0)
DRIVER_IRQ_SHARED |
#endif
- DRIVER_PRIME,
+ DRIVER_MODESET | DRIVER_GEM | DRIVER_HAVE_IRQ,
.dev_priv_size = 0,
.load = vbox_driver_load,
Index: VirtualBox-6.0.12/src/VBox/Additions/linux/drm/vbox_main.c
===================================================================
--- VirtualBox-6.0.12.orig/src/VBox/Additions/linux/drm/vbox_main.c
+++ VirtualBox-6.0.12/src/VBox/Additions/linux/drm/vbox_main.c
@@ -619,8 +619,12 @@ static inline u64 vbox_bo_mmap_offset(st
#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 12, 0) && !defined(RHEL_70)
return bo->bo.addr_space_offset;
#else
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 4, 0)
+ return drm_vma_node_offset_addr(&bo->bo.base.vma_node);
+#else
return drm_vma_node_offset_addr(&bo->bo.vma_node);
#endif
+#endif
}
int

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Wed Oct 2 19:08:58 UTC 2019 - Larry Finger <Larry.Finger@gmail.com>
- Update file "fixes_for_5.4.patch" to handle removal of DRIVER_PRIME and rework of
struct ttm_buffer_object.
-------------------------------------------------------------------
Thu Sep 26 14:46:23 UTC 2019 - Larry Finger <Larry.Finger@gmail.com>