On 1/2/20 4:04 AM, Frank Batschulat wrote:
On 24.12.19 02:36, Larry Finger wrote:

Index: VirtualBox-6.0.14/src/VBox/Additions/linux/drm/vbox_ttm.c
===================================================================
--- VirtualBox-6.0.14.orig/src/VBox/Additions/linux/drm/vbox_ttm.c
+++ VirtualBox-6.0.14/src/VBox/Additions/linux/drm/vbox_ttm.c
@@ -34,6 +34,10 @@
   */
  #include "vbox_drv.h"
  #include <ttm/ttm_page_alloc.h>
+#include <linux/pci.h>
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 5, 0)
+#include <drm/drm_fourcc.h>
+#endif

  #if LINUX_VERSION_CODE < KERNEL_VERSION(3, 18, 0) && !defined(RHEL_72)
  #define PLACEMENT_FLAGS(placement) (placement)
@@ -310,11 +314,12 @@ int vbox_mm_init(struct vbox_private *vb
  #if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 15, 0) || defined(RHEL_71)
                                  dev->anon_inode->i_mapping,
  #endif
-#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 2, 0)
-                                DRM_FILE_PAGE_OFFSET, true);
-#else
-                                true);
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 5, 0)
+                                NULL,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Replace the above line with:
   +                                bdev->vma_manager,
+#elif LINUX_VERSION_CODE < KERNEL_VERSION(5, 2, 0)
+                                DRM_FILE_PAGE_OFFSET,
  #endif
+                                true);

Btw, this is not an appropriate fix.

Again, the patch is build, but not run tested. All the kernels I support have vboxvideo built in.

Larry


_______________________________________________
vbox-dev mailing list
vbox-dev@virtualbox.org
https://www.virtualbox.org/mailman/listinfo/vbox-dev

Reply via email to