forked from pool/virtualbox
Accepting request 865491 from home:lwfinger:branches:Virtualization
- Version update to 6.1.18 (released January 19 2021) This is a maintenance release. The following items were fixed and/or added: Nested VM: Fixed hangs when executing SMP nested-guests under certain conditions on Intel hosts (bug #19315, #19561) OCI integration: Cloud Instance parameters parsing is improved on import (bug #19156) Network: UDP checksum offloading in e1000 no longer produces zero checksums (bug #19930) Network: Fixed Host-Only Ethernet Adapter DHCP, guest os can not get IP on host resume (bug #19620) NAT: Fixed mss parameter handing (bug #15256) macOS host: Multiple optimizations for BigSur Audio: Fixed issues with audio playback after host goes to sleep (bug #18594) Documentation: Some content touch-up and table formatting fixes Linux host and guest: Support kernel version 5.10 (bug #20055) Solaris host: Fix regression breaking VGA text mode since version 6.1.0 Guest Additions: Fixed a build failure affecting CentOS 8.2-2004 and later (bug #20091) Guest Additions: Fixed a build failure affecting Linux kernels 3.2.0 through 3.2.50 (bug #20006) Guest Additions: Fixed a VM segfault on copy with shared clipboard with X11 (bug #19226) Shared Folder: Fixed error with remounting on Linux guests File "debug_mountsf.patch" is deleted - fixed upstream. File "linux-5.10-address-space-fixes.patch" is deleted - fixed upstream. File "linux-5.10-framebuffer-fixes.patch" is deleted - fixed upstream. File "linux-5.10-r0drv-memobj-fix-r0.patch" is deleted - fixed upstream. OBS-URL: https://build.opensuse.org/request/show/865491 OBS-URL: https://build.opensuse.org/package/show/Virtualization/virtualbox?expand=0&rev=586
This commit is contained in:
parent
be31349318
commit
8fbcac2683
@ -1,3 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:80cc1932ea5d9ec35950d9b593bcb2c12afa9dee851410d72fd589998f53ef42
|
||||
size 4906664
|
||||
oid sha256:50cf78dc97e9ce7227f6aa1966b5478ff50abad85485626dc603bb5e98808664
|
||||
size 4969463
|
||||
|
@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:66b89a73cbc97b5c818d8db60eeffe7e4216269f3654f88da289413984faae40
|
||||
size 120564764
|
3
VirtualBox-6.1.18-patched.tar.bz2
Normal file
3
VirtualBox-6.1.18-patched.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:81573e1d8cf8b1a8dbd3c643d34bfe42e26105acf5316591a8bd365a3dfebb31
|
||||
size 120586588
|
@ -1,22 +0,0 @@
|
||||
Index: VirtualBox-6.1.16/src/VBox/Additions/linux/sharedfolders/mount.vboxsf.c
|
||||
===================================================================
|
||||
--- VirtualBox-6.1.16.orig/src/VBox/Additions/linux/sharedfolders/mount.vboxsf.c
|
||||
+++ VirtualBox-6.1.16/src/VBox/Additions/linux/sharedfolders/mount.vboxsf.c
|
||||
@@ -456,6 +456,7 @@ main(int argc, char **argv)
|
||||
unsigned long flags = MS_NODEV;
|
||||
char *host_name;
|
||||
char *mount_point;
|
||||
+ char options[120];
|
||||
struct vbsf_mount_info_new mntinf;
|
||||
struct vbsf_mount_opts opts =
|
||||
{
|
||||
@@ -579,7 +580,8 @@ main(int argc, char **argv)
|
||||
* options you also would have to adjust VBoxServiceAutoMount.cpp
|
||||
* to keep this code here slick without having VbglR3.
|
||||
*/
|
||||
- err = mount(host_name, mount_point, "vboxsf", flags, &mntinf);
|
||||
+ sprintf(options, "uid=%d,gid=%d\n", mntinf.uid, mntinf.gid);
|
||||
+ err = mount(host_name, mount_point, "vboxsf", flags, options);
|
||||
saved_errno = errno;
|
||||
|
||||
/* Some versions of the mount utility (unknown which, if any) will turn the
|
@ -1,8 +1,8 @@
|
||||
Index: VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_drv.c
|
||||
Index: VirtualBox-6.1.18/src/VBox/Additions/linux/drm/vbox_drv.c
|
||||
===================================================================
|
||||
--- VirtualBox-6.1.13.orig/src/VBox/Additions/linux/drm/vbox_drv.c
|
||||
+++ VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_drv.c
|
||||
@@ -325,7 +325,9 @@ static struct drm_driver driver = {
|
||||
--- VirtualBox-6.1.18.orig/src/VBox/Additions/linux/drm/vbox_drv.c
|
||||
+++ VirtualBox-6.1.18/src/VBox/Additions/linux/drm/vbox_drv.c
|
||||
@@ -331,7 +331,9 @@ static struct drm_driver driver = {
|
||||
.master_drop = vbox_master_drop,
|
||||
#if RTLNX_VER_MIN(3,18,0) || RTLNX_RHEL_MAJ_PREREQ(7,2)
|
||||
# if RTLNX_VER_MAX(4,14,0) && !RTLNX_RHEL_MAJ_PREREQ(7,5) && !RTLNX_SUSE_MAJ_PREREQ(15,1) && !RTLNX_SUSE_MAJ_PREREQ(12,5)
|
||||
@ -12,11 +12,11 @@ Index: VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_drv.c
|
||||
# endif
|
||||
#endif
|
||||
|
||||
Index: VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_main.c
|
||||
Index: VirtualBox-6.1.18/src/VBox/Additions/linux/drm/vbox_main.c
|
||||
===================================================================
|
||||
--- VirtualBox-6.1.13.orig/src/VBox/Additions/linux/drm/vbox_main.c
|
||||
+++ VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_main.c
|
||||
@@ -606,11 +606,13 @@ int vbox_dumb_destroy(struct drm_file *f
|
||||
--- VirtualBox-6.1.18.orig/src/VBox/Additions/linux/drm/vbox_main.c
|
||||
+++ VirtualBox-6.1.18/src/VBox/Additions/linux/drm/vbox_main.c
|
||||
@@ -618,11 +618,13 @@ int vbox_dumb_destroy(struct drm_file *f
|
||||
#endif
|
||||
|
||||
#if RTLNX_VER_MAX(4,19,0) && !RTLNX_RHEL_MAJ_PREREQ(7,7) && !RTLNX_RHEL_MAJ_PREREQ(8,1) && !RTLNX_SUSE_MAJ_PREREQ(15,1) && !RTLNX_SUSE_MAJ_PREREQ(12,5)
|
||||
@ -30,29 +30,29 @@ Index: VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_main.c
|
||||
|
||||
void vbox_gem_free_object(struct drm_gem_object *obj)
|
||||
{
|
||||
Index: VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
Index: VirtualBox-6.1.18/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
===================================================================
|
||||
--- VirtualBox-6.1.13.orig/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
+++ VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
@@ -210,7 +210,7 @@ static struct ttm_backend_func vbox_tt_b
|
||||
.destroy = &vbox_ttm_backend_destroy,
|
||||
--- VirtualBox-6.1.18.orig/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
+++ VirtualBox-6.1.18/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
@@ -256,7 +256,7 @@ static struct ttm_backend_func vbox_tt_b
|
||||
};
|
||||
#endif
|
||||
|
||||
-#if RTLNX_VER_MAX(4,17,0) && !RTLNX_RHEL_MAJ_PREREQ(7,6) && !RTLNX_SUSE_MAJ_PREREQ(15,1) && !RTLNX_SUSE_MAJ_PREREQ(12,5)
|
||||
+#if RTLNX_VER_MAX(4,17,0) && !RTLNX_RHEL_MAJ_PREREQ(7,6) && !RTLNX_SUSE_MAJ_PREREQ(15,1) && !RTLNX_SUSE_MAJ_PREREQ(12,5) && !defined(SUSE_SLE12)
|
||||
static struct ttm_tt *vbox_ttm_tt_create(struct ttm_bo_device *bdev,
|
||||
unsigned long size,
|
||||
u32 page_flags,
|
||||
@@ -227,7 +227,7 @@ static struct ttm_tt *vbox_ttm_tt_create
|
||||
return NULL;
|
||||
|
||||
@@ -275,7 +275,7 @@ static struct ttm_tt *vbox_ttm_tt_create
|
||||
#if RTLNX_VER_MAX(5,10,0)
|
||||
tt->func = &vbox_tt_backend_func;
|
||||
#endif
|
||||
-#if RTLNX_VER_MAX(4,17,0) && !RTLNX_RHEL_MAJ_PREREQ(7,6) && !RTLNX_SUSE_MAJ_PREREQ(15,1) && !RTLNX_SUSE_MAJ_PREREQ(12,5)
|
||||
+#if RTLNX_VER_MAX(4,17,0) && !RTLNX_RHEL_MAJ_PREREQ(7,6) && !RTLNX_SUSE_MAJ_PREREQ(15,1) && !RTLNX_SUSE_MAJ_PREREQ(12,5) && !defined(SUSE_SLE12)
|
||||
if (ttm_tt_init(tt, bdev, size, page_flags, dummy_read_page)) {
|
||||
#else
|
||||
if (ttm_tt_init(tt, bo, page_flags)) {
|
||||
@@ -240,7 +240,7 @@ static struct ttm_tt *vbox_ttm_tt_create
|
||||
@@ -288,7 +288,7 @@ static struct ttm_tt *vbox_ttm_tt_create
|
||||
}
|
||||
|
||||
#if RTLNX_VER_MAX(4,17,0)
|
||||
@ -61,7 +61,7 @@ Index: VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
static int vbox_ttm_tt_populate(struct ttm_tt *ttm)
|
||||
{
|
||||
return ttm_pool_populate(ttm);
|
||||
@@ -274,7 +274,7 @@ static struct ttm_bo_driver vbox_bo_driv
|
||||
@@ -327,7 +327,7 @@ static struct ttm_bo_driver vbox_bo_driv
|
||||
.io_mem_reserve = &vbox_ttm_io_mem_reserve,
|
||||
.io_mem_free = &vbox_ttm_io_mem_free,
|
||||
#if RTLNX_VER_MIN(4,12,0) || RTLNX_RHEL_MAJ_PREREQ(7,5)
|
||||
@ -70,7 +70,7 @@ Index: VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
.io_mem_pfn = ttm_bo_default_io_mem_pfn,
|
||||
# endif
|
||||
#endif
|
||||
@@ -421,7 +421,7 @@ int vbox_bo_create(struct drm_device *de
|
||||
@@ -500,7 +500,7 @@ int vbox_bo_create(struct drm_device *de
|
||||
|
||||
ret = ttm_bo_init(&vbox->ttm.bdev, &vboxbo->bo, size,
|
||||
ttm_bo_type_device, &vboxbo->placement,
|
||||
@ -79,16 +79,16 @@ Index: VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
align >> PAGE_SHIFT, false, NULL, acc_size,
|
||||
#else
|
||||
align >> PAGE_SHIFT, false, acc_size,
|
||||
@@ -450,7 +450,7 @@ static inline u64 vbox_bo_gpu_offset(str
|
||||
@@ -533,7 +533,7 @@ static inline u64 vbox_bo_gpu_offset(str
|
||||
|
||||
int vbox_bo_pin(struct vbox_bo *bo, u32 pl_flag, u64 *gpu_addr)
|
||||
int vbox_bo_pin(struct vbox_bo *bo, u32 mem_type, u64 *gpu_addr)
|
||||
{
|
||||
-#if RTLNX_VER_MIN(4,16,0) || RTLNX_RHEL_MAJ_PREREQ(7,6) || RTLNX_SUSE_MAJ_PREREQ(15,1) || RTLNX_SUSE_MAJ_PREREQ(12,5)
|
||||
+#if RTLNX_VER_MIN(4,16,0) || RTLNX_RHEL_MAJ_PREREQ(7,6) || RTLNX_SUSE_MAJ_PREREQ(15,1) || RTLNX_SUSE_MAJ_PREREQ(12,5) || defined(SUSE_SLE12)
|
||||
struct ttm_operation_ctx ctx = { false, false };
|
||||
#endif
|
||||
int i, ret;
|
||||
@@ -468,7 +468,7 @@ int vbox_bo_pin(struct vbox_bo *bo, u32
|
||||
@@ -551,7 +551,7 @@ int vbox_bo_pin(struct vbox_bo *bo, u32
|
||||
for (i = 0; i < bo->placement.num_placement; i++)
|
||||
PLACEMENT_FLAGS(bo->placements[i]) |= TTM_PL_FLAG_NO_EVICT;
|
||||
|
||||
@ -97,7 +97,7 @@ Index: VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
ret = ttm_bo_validate(&bo->bo, &bo->placement, false, false);
|
||||
#else
|
||||
ret = ttm_bo_validate(&bo->bo, &bo->placement, &ctx);
|
||||
@@ -486,7 +486,7 @@ int vbox_bo_pin(struct vbox_bo *bo, u32
|
||||
@@ -569,7 +569,7 @@ int vbox_bo_pin(struct vbox_bo *bo, u32
|
||||
|
||||
int vbox_bo_unpin(struct vbox_bo *bo)
|
||||
{
|
||||
@ -106,7 +106,7 @@ Index: VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
struct ttm_operation_ctx ctx = { false, false };
|
||||
#endif
|
||||
int i, ret;
|
||||
@@ -502,7 +502,7 @@ int vbox_bo_unpin(struct vbox_bo *bo)
|
||||
@@ -585,7 +585,7 @@ int vbox_bo_unpin(struct vbox_bo *bo)
|
||||
for (i = 0; i < bo->placement.num_placement; i++)
|
||||
PLACEMENT_FLAGS(bo->placements[i]) &= ~TTM_PL_FLAG_NO_EVICT;
|
||||
|
||||
@ -115,7 +115,7 @@ Index: VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
ret = ttm_bo_validate(&bo->bo, &bo->placement, false, false);
|
||||
#else
|
||||
ret = ttm_bo_validate(&bo->bo, &bo->placement, &ctx);
|
||||
@@ -520,7 +520,7 @@ int vbox_bo_unpin(struct vbox_bo *bo)
|
||||
@@ -603,7 +603,7 @@ int vbox_bo_unpin(struct vbox_bo *bo)
|
||||
*/
|
||||
int vbox_bo_push_sysram(struct vbox_bo *bo)
|
||||
{
|
||||
@ -124,7 +124,7 @@ Index: VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
struct ttm_operation_ctx ctx = { false, false };
|
||||
#endif
|
||||
int i, ret;
|
||||
@@ -541,7 +541,7 @@ int vbox_bo_push_sysram(struct vbox_bo *
|
||||
@@ -624,7 +624,7 @@ int vbox_bo_push_sysram(struct vbox_bo *
|
||||
for (i = 0; i < bo->placement.num_placement; i++)
|
||||
PLACEMENT_FLAGS(bo->placements[i]) |= TTM_PL_FLAG_NO_EVICT;
|
||||
|
||||
@ -133,10 +133,10 @@ Index: VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
ret = ttm_bo_validate(&bo->bo, &bo->placement, false, false);
|
||||
#else
|
||||
ret = ttm_bo_validate(&bo->bo, &bo->placement, &ctx);
|
||||
Index: VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_drv.h
|
||||
Index: VirtualBox-6.1.18/src/VBox/Additions/linux/drm/vbox_drv.h
|
||||
===================================================================
|
||||
--- VirtualBox-6.1.13.orig/src/VBox/Additions/linux/drm/vbox_drv.h
|
||||
+++ VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_drv.h
|
||||
--- VirtualBox-6.1.18.orig/src/VBox/Additions/linux/drm/vbox_drv.h
|
||||
+++ VirtualBox-6.1.18/src/VBox/Additions/linux/drm/vbox_drv.h
|
||||
@@ -87,6 +87,9 @@
|
||||
#else
|
||||
# define RTLNX_RHEL_MAX(a_iMajor, a_iMinor) (0)
|
||||
@ -147,10 +147,10 @@ Index: VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_drv.h
|
||||
|
||||
/** @def RTLNX_RHEL_RANGE
|
||||
* Check that it's a RedHat kernel in the given version range.
|
||||
Index: VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_mode.c
|
||||
Index: VirtualBox-6.1.18/src/VBox/Additions/linux/drm/vbox_mode.c
|
||||
===================================================================
|
||||
--- VirtualBox-6.1.13.orig/src/VBox/Additions/linux/drm/vbox_mode.c
|
||||
+++ VirtualBox-6.1.13/src/VBox/Additions/linux/drm/vbox_mode.c
|
||||
--- VirtualBox-6.1.18.orig/src/VBox/Additions/linux/drm/vbox_mode.c
|
||||
+++ VirtualBox-6.1.18/src/VBox/Additions/linux/drm/vbox_mode.c
|
||||
@@ -544,7 +544,8 @@ static void vbox_set_edid(struct drm_con
|
||||
for (i = 0; i < EDID_SIZE - 1; ++i)
|
||||
sum += edid[i];
|
||||
|
@ -1,16 +0,0 @@
|
||||
Index: b/src/VBox/Additions/linux/sharedfolders/regops.c
|
||||
===================================================================
|
||||
--- a/src/VBox/Additions/linux/sharedfolders/regops.c
|
||||
+++ b/src/VBox/Additions/linux/sharedfolders/regops.c
|
||||
@@ -1401,7 +1401,10 @@ static int vbsf_lock_user_pages_failed_c
|
||||
/*
|
||||
* Check that this is valid user memory that is actually in the kernel range.
|
||||
*/
|
||||
-#if RTLNX_VER_MIN(5,0,0) || RTLNX_RHEL_MIN(8,1)
|
||||
+#if RTLNX_VER_MIN(5,10,0)
|
||||
+ if ( access_ok((void *)uPtrFrom, cPages << PAGE_SHIFT)
|
||||
+ && uPtrFrom >= TASK_SIZE_MAX)
|
||||
+#elif RTLNX_VER_MIN(5,0,0) || RTLNX_RHEL_MIN(8,1)
|
||||
if ( access_ok((void *)uPtrFrom, cPages << PAGE_SHIFT)
|
||||
&& uPtrFrom >= USER_DS.seg)
|
||||
#else
|
@ -1,300 +0,0 @@
|
||||
Index: b/src/VBox/Additions/linux/drm/vbox_drv.h
|
||||
===================================================================
|
||||
--- a/src/VBox/Additions/linux/drm/vbox_drv.h
|
||||
+++ b/src/VBox/Additions/linux/drm/vbox_drv.h
|
||||
@@ -184,6 +184,9 @@
|
||||
#include <drm/ttm/ttm_placement.h>
|
||||
#include <drm/ttm/ttm_memory.h>
|
||||
#include <drm/ttm/ttm_module.h>
|
||||
+#if RTLNX_VER_MIN(5,10,0)
|
||||
+# include <drm/ttm/ttm_resource.h>
|
||||
+#endif
|
||||
|
||||
#include "vboxvideo_guest.h"
|
||||
#include "vboxvideo_vbe.h"
|
||||
@@ -453,7 +456,10 @@ int vbox_bo_create(struct drm_device *de
|
||||
int vbox_gem_create(struct drm_device *dev,
|
||||
u32 size, bool iskernel, struct drm_gem_object **obj);
|
||||
|
||||
-int vbox_bo_pin(struct vbox_bo *bo, u32 pl_flag, u64 *gpu_addr);
|
||||
+#define VBOX_MEM_TYPE_VRAM 0x1
|
||||
+#define VBOX_MEM_TYPE_SYSTEM 0x2
|
||||
+
|
||||
+int vbox_bo_pin(struct vbox_bo *bo, u32 mem_type, u64 *gpu_addr);
|
||||
int vbox_bo_unpin(struct vbox_bo *bo);
|
||||
|
||||
static inline int vbox_bo_reserve(struct vbox_bo *bo, bool no_wait)
|
||||
@@ -478,7 +484,7 @@ static inline void vbox_bo_unreserve(str
|
||||
ttm_bo_unreserve(&bo->bo);
|
||||
}
|
||||
|
||||
-void vbox_ttm_placement(struct vbox_bo *bo, int domain);
|
||||
+void vbox_ttm_placement(struct vbox_bo *bo, u32 mem_type);
|
||||
int vbox_bo_push_sysram(struct vbox_bo *bo);
|
||||
int vbox_mmap(struct file *filp, struct vm_area_struct *vma);
|
||||
|
||||
Index: b/src/VBox/Additions/linux/drm/vbox_fb.c
|
||||
===================================================================
|
||||
--- a/src/VBox/Additions/linux/drm/vbox_fb.c
|
||||
+++ b/src/VBox/Additions/linux/drm/vbox_fb.c
|
||||
@@ -295,7 +295,7 @@ static int vboxfb_create(struct drm_fb_h
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
- ret = vbox_bo_pin(bo, TTM_PL_FLAG_VRAM, NULL);
|
||||
+ ret = vbox_bo_pin(bo, VBOX_MEM_TYPE_VRAM, NULL);
|
||||
if (ret) {
|
||||
vbox_bo_unreserve(bo);
|
||||
return ret;
|
||||
Index: b/src/VBox/Additions/linux/drm/vbox_mode.c
|
||||
===================================================================
|
||||
--- a/src/VBox/Additions/linux/drm/vbox_mode.c
|
||||
+++ b/src/VBox/Additions/linux/drm/vbox_mode.c
|
||||
@@ -227,7 +227,7 @@ static int vbox_crtc_set_base(struct drm
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
- ret = vbox_bo_pin(bo, TTM_PL_FLAG_VRAM, &gpu_addr);
|
||||
+ ret = vbox_bo_pin(bo, VBOX_MEM_TYPE_VRAM, &gpu_addr);
|
||||
vbox_bo_unreserve(bo);
|
||||
if (ret)
|
||||
return ret;
|
||||
Index: b/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
===================================================================
|
||||
--- a/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
+++ b/src/VBox/Additions/linux/drm/vbox_ttm.c
|
||||
@@ -41,6 +41,7 @@
|
||||
#define PLACEMENT_FLAGS(placement) ((placement).flags)
|
||||
#endif
|
||||
|
||||
+
|
||||
static inline struct vbox_private *vbox_bdev(struct ttm_bo_device *bd)
|
||||
{
|
||||
return container_of(bd, struct vbox_private, ttm.bdev);
|
||||
@@ -125,6 +126,7 @@ static bool vbox_ttm_bo_is_vbox_bo(struc
|
||||
return false;
|
||||
}
|
||||
|
||||
+#if RTLNX_VER_MAX(5,10,0)
|
||||
static int
|
||||
vbox_bo_init_mem_type(struct ttm_bo_device *bdev, u32 type,
|
||||
struct ttm_mem_type_manager *man)
|
||||
@@ -148,6 +150,7 @@ vbox_bo_init_mem_type(struct ttm_bo_devi
|
||||
|
||||
return 0;
|
||||
}
|
||||
+#endif
|
||||
|
||||
static void
|
||||
vbox_bo_evict_flags(struct ttm_buffer_object *bo, struct ttm_placement *pl)
|
||||
@@ -157,7 +160,7 @@ vbox_bo_evict_flags(struct ttm_buffer_ob
|
||||
if (!vbox_ttm_bo_is_vbox_bo(bo))
|
||||
return;
|
||||
|
||||
- vbox_ttm_placement(vboxbo, TTM_PL_FLAG_SYSTEM);
|
||||
+ vbox_ttm_placement(vboxbo, VBOX_MEM_TYPE_SYSTEM);
|
||||
*pl = vboxbo->placement;
|
||||
}
|
||||
|
||||
@@ -167,11 +170,12 @@ static int vbox_bo_verify_access(struct
|
||||
return 0;
|
||||
}
|
||||
|
||||
+#if RTLNX_VER_MAX(5,10,0)
|
||||
static int vbox_ttm_io_mem_reserve(struct ttm_bo_device *bdev,
|
||||
struct ttm_mem_reg *mem)
|
||||
{
|
||||
- struct ttm_mem_type_manager *man = &bdev->man[mem->mem_type];
|
||||
struct vbox_private *vbox = vbox_bdev(bdev);
|
||||
+ struct ttm_mem_type_manager *man = &bdev->man[mem->mem_type];
|
||||
|
||||
mem->bus.addr = NULL;
|
||||
mem->bus.offset = 0;
|
||||
@@ -194,12 +198,53 @@ static int vbox_ttm_io_mem_reserve(struc
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
+#else
|
||||
+static int vbox_ttm_io_mem_reserve(struct ttm_bo_device *bdev,
|
||||
+ struct ttm_resource *mem)
|
||||
+{
|
||||
+ struct vbox_private *vbox = vbox_bdev(bdev);
|
||||
+ mem->bus.addr = NULL;
|
||||
+ mem->bus.offset = 0;
|
||||
+ mem->size = mem->num_pages << PAGE_SHIFT;
|
||||
+ mem->start = 0;
|
||||
+ mem->bus.is_iomem = false;
|
||||
+ switch (mem->mem_type) {
|
||||
+ case TTM_PL_SYSTEM:
|
||||
+ /* system memory */
|
||||
+ return 0;
|
||||
+ case TTM_PL_VRAM:
|
||||
+ mem->bus.offset = mem->start << PAGE_SHIFT;
|
||||
+ mem->start = pci_resource_start(vbox->dev->pdev, 0);
|
||||
+ mem->bus.is_iomem = true;
|
||||
+ break;
|
||||
+ default:
|
||||
+ return -EINVAL;
|
||||
+ }
|
||||
+ return 0;
|
||||
+}
|
||||
+#endif
|
||||
|
||||
+
|
||||
+
|
||||
+#if RTLNX_VER_MIN(5,10,0)
|
||||
+static void vbox_ttm_io_mem_free(struct ttm_bo_device *bdev,
|
||||
+ struct ttm_resource *mem)
|
||||
+{
|
||||
+}
|
||||
+#else
|
||||
static void vbox_ttm_io_mem_free(struct ttm_bo_device *bdev,
|
||||
struct ttm_mem_reg *mem)
|
||||
{
|
||||
}
|
||||
+#endif
|
||||
|
||||
+#if RTLNX_VER_MIN(5,10,0)
|
||||
+static void vbox_ttm_tt_destroy(struct ttm_bo_device *bdev, struct ttm_tt *tt)
|
||||
+{
|
||||
+ ttm_tt_fini(tt);
|
||||
+ kfree(tt);
|
||||
+}
|
||||
+#else
|
||||
static void vbox_ttm_backend_destroy(struct ttm_tt *tt)
|
||||
{
|
||||
ttm_tt_fini(tt);
|
||||
@@ -209,6 +254,7 @@ static void vbox_ttm_backend_destroy(str
|
||||
static struct ttm_backend_func vbox_tt_backend_func = {
|
||||
.destroy = &vbox_ttm_backend_destroy,
|
||||
};
|
||||
+#endif
|
||||
|
||||
#if RTLNX_VER_MAX(4,17,0) && !RTLNX_RHEL_MAJ_PREREQ(7,6) && !RTLNX_SUSE_MAJ_PREREQ(15,1) && !RTLNX_SUSE_MAJ_PREREQ(12,5) && !defined(SUSE_SLE12)
|
||||
static struct ttm_tt *vbox_ttm_tt_create(struct ttm_bo_device *bdev,
|
||||
@@ -226,7 +272,9 @@ static struct ttm_tt *vbox_ttm_tt_create
|
||||
if (!tt)
|
||||
return NULL;
|
||||
|
||||
+#if RTLNX_VER_MAX(5,10,0)
|
||||
tt->func = &vbox_tt_backend_func;
|
||||
+#endif
|
||||
#if RTLNX_VER_MAX(4,17,0) && !RTLNX_RHEL_MAJ_PREREQ(7,6) && !RTLNX_SUSE_MAJ_PREREQ(15,1) && !RTLNX_SUSE_MAJ_PREREQ(12,5) && !defined(SUSE_SLE12)
|
||||
if (ttm_tt_init(tt, bdev, size, page_flags, dummy_read_page)) {
|
||||
#else
|
||||
@@ -261,11 +309,16 @@ static void vbox_ttm_tt_unpopulate(struc
|
||||
|
||||
static struct ttm_bo_driver vbox_bo_driver = {
|
||||
.ttm_tt_create = vbox_ttm_tt_create,
|
||||
+#if RTLNX_VER_MIN(5,10,0)
|
||||
+ .ttm_tt_destroy = vbox_ttm_tt_destroy,
|
||||
+#endif
|
||||
#if RTLNX_VER_MAX(4,17,0)
|
||||
.ttm_tt_populate = vbox_ttm_tt_populate,
|
||||
.ttm_tt_unpopulate = vbox_ttm_tt_unpopulate,
|
||||
#endif
|
||||
+#if RTLNX_VER_MAX(5,10,0)
|
||||
.init_mem_type = vbox_bo_init_mem_type,
|
||||
+#endif
|
||||
#if RTLNX_VER_MIN(4,10,0) || RTLNX_RHEL_MAJ_PREREQ(7,4)
|
||||
.eviction_valuable = ttm_bo_eviction_valuable,
|
||||
#endif
|
||||
@@ -318,8 +371,13 @@ int vbox_mm_init(struct vbox_private *vb
|
||||
#endif
|
||||
}
|
||||
|
||||
+#if RTLNX_VER_MIN(5,10,0)
|
||||
+ ret = ttm_range_man_init(bdev, TTM_PL_VRAM, false,
|
||||
+ vbox->available_vram_size >> PAGE_SHIFT);
|
||||
+#else
|
||||
ret = ttm_bo_init_mm(bdev, TTM_PL_VRAM,
|
||||
vbox->available_vram_size >> PAGE_SHIFT);
|
||||
+#endif
|
||||
if (ret) {
|
||||
DRM_ERROR("Failed ttm VRAM init: %d\n", ret);
|
||||
goto err_device_release;
|
||||
@@ -359,7 +417,7 @@ void vbox_mm_fini(struct vbox_private *v
|
||||
#endif
|
||||
}
|
||||
|
||||
-void vbox_ttm_placement(struct vbox_bo *bo, int domain)
|
||||
+void vbox_ttm_placement(struct vbox_bo *bo, u32 mem_type)
|
||||
{
|
||||
u32 c = 0;
|
||||
#if RTLNX_VER_MAX(3,18,0) && !RTLNX_RHEL_MAJ_PREREQ(7,2)
|
||||
@@ -372,15 +430,36 @@ void vbox_ttm_placement(struct vbox_bo *
|
||||
bo->placement.placement = bo->placements;
|
||||
bo->placement.busy_placement = bo->placements;
|
||||
|
||||
- if (domain & TTM_PL_FLAG_VRAM)
|
||||
+ if (mem_type & VBOX_MEM_TYPE_VRAM) {
|
||||
+#if RTLNX_VER_MIN(5,10,0)
|
||||
+ bo->placements[c].mem_type = TTM_PL_VRAM;
|
||||
+ PLACEMENT_FLAGS(bo->placements[c++]) =
|
||||
+ TTM_PL_FLAG_WC | TTM_PL_FLAG_UNCACHED;
|
||||
+#else
|
||||
PLACEMENT_FLAGS(bo->placements[c++]) =
|
||||
TTM_PL_FLAG_WC | TTM_PL_FLAG_UNCACHED | TTM_PL_FLAG_VRAM;
|
||||
- if (domain & TTM_PL_FLAG_SYSTEM)
|
||||
+#endif
|
||||
+ }
|
||||
+ if (mem_type & VBOX_MEM_TYPE_SYSTEM) {
|
||||
+#if RTLNX_VER_MIN(5,10,0)
|
||||
+ bo->placements[c].mem_type = TTM_PL_SYSTEM;
|
||||
+ PLACEMENT_FLAGS(bo->placements[c++]) =
|
||||
+ TTM_PL_MASK_CACHING;
|
||||
+#else
|
||||
PLACEMENT_FLAGS(bo->placements[c++]) =
|
||||
TTM_PL_MASK_CACHING | TTM_PL_FLAG_SYSTEM;
|
||||
- if (!c)
|
||||
+#endif
|
||||
+ }
|
||||
+ if (!c) {
|
||||
+#if RTLNX_VER_MIN(5,10,0)
|
||||
+ bo->placements[c].mem_type = TTM_PL_SYSTEM;
|
||||
+ PLACEMENT_FLAGS(bo->placements[c++]) =
|
||||
+ TTM_PL_MASK_CACHING;
|
||||
+#else
|
||||
PLACEMENT_FLAGS(bo->placements[c++]) =
|
||||
TTM_PL_MASK_CACHING | TTM_PL_FLAG_SYSTEM;
|
||||
+#endif
|
||||
+ }
|
||||
|
||||
bo->placement.num_placement = c;
|
||||
bo->placement.num_busy_placement = c;
|
||||
@@ -414,7 +493,7 @@ int vbox_bo_create(struct drm_device *de
|
||||
vboxbo->bo.bdev->dev_mapping = dev->dev_mapping;
|
||||
#endif
|
||||
|
||||
- vbox_ttm_placement(vboxbo, TTM_PL_FLAG_VRAM | TTM_PL_FLAG_SYSTEM);
|
||||
+ vbox_ttm_placement(vboxbo, VBOX_MEM_TYPE_VRAM | VBOX_MEM_TYPE_SYSTEM);
|
||||
|
||||
acc_size = ttm_bo_dma_acc_size(&vbox->ttm.bdev, size,
|
||||
sizeof(struct vbox_bo));
|
||||
@@ -452,7 +531,7 @@ static inline u64 vbox_bo_gpu_offset(str
|
||||
#endif
|
||||
}
|
||||
|
||||
-int vbox_bo_pin(struct vbox_bo *bo, u32 pl_flag, u64 *gpu_addr)
|
||||
+int vbox_bo_pin(struct vbox_bo *bo, u32 mem_type, u64 *gpu_addr)
|
||||
{
|
||||
#if RTLNX_VER_MIN(4,16,0) || RTLNX_RHEL_MAJ_PREREQ(7,6) || RTLNX_SUSE_MAJ_PREREQ(15,1) || RTLNX_SUSE_MAJ_PREREQ(12,5) || defined(SUSE_SLE12)
|
||||
struct ttm_operation_ctx ctx = { false, false };
|
||||
@@ -467,7 +546,7 @@ int vbox_bo_pin(struct vbox_bo *bo, u32
|
||||
return 0;
|
||||
}
|
||||
|
||||
- vbox_ttm_placement(bo, pl_flag);
|
||||
+ vbox_ttm_placement(bo, mem_type);
|
||||
|
||||
for (i = 0; i < bo->placement.num_placement; i++)
|
||||
PLACEMENT_FLAGS(bo->placements[i]) |= TTM_PL_FLAG_NO_EVICT;
|
||||
@@ -540,7 +619,7 @@ int vbox_bo_push_sysram(struct vbox_bo *
|
||||
if (bo->kmap.virtual)
|
||||
ttm_bo_kunmap(&bo->kmap);
|
||||
|
||||
- vbox_ttm_placement(bo, TTM_PL_FLAG_SYSTEM);
|
||||
+ vbox_ttm_placement(bo, VBOX_MEM_TYPE_SYSTEM);
|
||||
|
||||
for (i = 0; i < bo->placement.num_placement; i++)
|
||||
PLACEMENT_FLAGS(bo->placements[i]) |= TTM_PL_FLAG_NO_EVICT;
|
@ -1,96 +0,0 @@
|
||||
Index: src/VBox/Runtime/r0drv/linux/memobj-r0drv-linux.c
|
||||
===================================================================
|
||||
--- a/src/VBox/Runtime/r0drv/linux/memobj-r0drv-linux.c (Revision 141658)
|
||||
+++ b/src/VBox/Runtime/r0drv/linux/memobj-r0drv-linux.c (Arbeitskopie)
|
||||
@@ -56,9 +56,12 @@
|
||||
* Whether we use alloc_vm_area (3.2+) for executable memory.
|
||||
* This is a must for 5.8+, but we enable it all the way back to 3.2.x for
|
||||
* better W^R compliance (fExecutable flag). */
|
||||
-#if RTLNX_VER_MIN(3,2,0) || defined(DOXYGEN_RUNNING)
|
||||
+#if RTLNX_VER_RANGE(3,2,0, 5,10,0) || defined(DOXYGEN_RUNNING)
|
||||
# define IPRT_USE_ALLOC_VM_AREA_FOR_EXEC
|
||||
#endif
|
||||
+#if RTLNX_VER_MIN(5,10,0) || defined(DOXYGEN_RUNNING)
|
||||
+# define IPRT_USE_APPLY_TO_PAGE_RANGE_FOR_EXEC
|
||||
+#endif
|
||||
|
||||
/*
|
||||
* 2.6.29+ kernels don't work with remap_pfn_range() anymore because
|
||||
@@ -502,7 +505,43 @@
|
||||
}
|
||||
|
||||
|
||||
+#ifdef IPRT_USE_APPLY_TO_PAGE_RANGE_FOR_EXEC
|
||||
/**
|
||||
+ * User data passed to the apply_to_page_range() callback.
|
||||
+ */
|
||||
+typedef struct LNXAPPLYPGRANGE
|
||||
+{
|
||||
+ /** Pointer to the memory object. */
|
||||
+ PRTR0MEMOBJLNX pMemLnx;
|
||||
+ /** The page protection flags to apply. */
|
||||
+ pgprot_t fPg;
|
||||
+} LNXAPPLYPGRANGE;
|
||||
+/** Pointer to the user data. */
|
||||
+typedef LNXAPPLYPGRANGE *PLNXAPPLYPGRANGE;
|
||||
+/** Pointer to the const user data. */
|
||||
+typedef const LNXAPPLYPGRANGE *PCLNXAPPLYPGRANGE;
|
||||
+
|
||||
+/**
|
||||
+ * Callback called in apply_to_page_range().
|
||||
+ *
|
||||
+ * @returns Linux status code.
|
||||
+ * @param pPte Pointer to the page table entry for the given address.
|
||||
+ * @param uAddr The address to apply the new protection to.
|
||||
+ * @param pvUser The opaque user data.
|
||||
+ */
|
||||
+static DECLCALLBACK(int) rtR0MemObjLinuxApplyPageRange(pte_t *pPte, unsigned long uAddr, void *pvUser)
|
||||
+{
|
||||
+ PCLNXAPPLYPGRANGE pArgs = (PCLNXAPPLYPGRANGE)pvUser;
|
||||
+ PRTR0MEMOBJLNX pMemLnx = pArgs->pMemLnx;
|
||||
+ uint32_t idxPg = (uAddr - (unsigned long)pMemLnx->Core.pv) >> PAGE_SHIFT;
|
||||
+
|
||||
+ set_pte(pPte, mk_pte(pMemLnx->apPages[idxPg], pArgs->fPg));
|
||||
+ return 0;
|
||||
+}
|
||||
+#endif
|
||||
+
|
||||
+
|
||||
+/**
|
||||
* Maps the allocation into ring-0.
|
||||
*
|
||||
* This will update the RTR0MEMOBJLNX::Core.pv and RTR0MEMOBJ::fMappedToRing0 members.
|
||||
@@ -584,6 +623,11 @@
|
||||
else
|
||||
# endif
|
||||
{
|
||||
+# if defined(IPRT_USE_APPLY_TO_PAGE_RANGE_FOR_EXEC)
|
||||
+ if (fExecutable)
|
||||
+ pgprot_val(fPg) |= _PAGE_NX; /* Uses RTR0MemObjProtect to clear NX when memory ready, W^X fashion. */
|
||||
+# endif
|
||||
+
|
||||
# ifdef VM_MAP
|
||||
pMemLnx->Core.pv = vmap(&pMemLnx->apPages[0], pMemLnx->cPages, VM_MAP, fPg);
|
||||
# else
|
||||
@@ -1851,6 +1895,21 @@
|
||||
preempt_enable();
|
||||
return VINF_SUCCESS;
|
||||
}
|
||||
+# elif defined(IPRT_USE_APPLY_TO_PAGE_RANGE_FOR_EXEC)
|
||||
+ PRTR0MEMOBJLNX pMemLnx = (PRTR0MEMOBJLNX)pMem;
|
||||
+ if ( pMemLnx->fExecutable
|
||||
+ && pMemLnx->fMappedToRing0)
|
||||
+ {
|
||||
+ LNXAPPLYPGRANGE Args;
|
||||
+ Args.pMemLnx = pMemLnx;
|
||||
+ Args.fPg = rtR0MemObjLinuxConvertProt(fProt, true /*fKernel*/);
|
||||
+ int rcLnx = apply_to_page_range(current->active_mm, (unsigned long)pMemLnx->Core.pv + offSub, cbSub,
|
||||
+ rtR0MemObjLinuxApplyPageRange, (void *)&Args);
|
||||
+ if (rcLnx)
|
||||
+ return VERR_NOT_SUPPORTED;
|
||||
+
|
||||
+ return VINF_SUCCESS;
|
||||
+ }
|
||||
# endif
|
||||
|
||||
NOREF(pMem);
|
@ -1,3 +1,30 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Jan 20 19:47:15 UTC 2021 - Larry Finger <Larry.Finger@gmail.com>
|
||||
|
||||
- Version update to 6.1.18 (released January 19 2021)
|
||||
|
||||
This is a maintenance release. The following items were fixed and/or added:
|
||||
|
||||
Nested VM: Fixed hangs when executing SMP nested-guests under certain conditions on Intel hosts (bug #19315, #19561)
|
||||
OCI integration: Cloud Instance parameters parsing is improved on import (bug #19156)
|
||||
Network: UDP checksum offloading in e1000 no longer produces zero checksums (bug #19930)
|
||||
Network: Fixed Host-Only Ethernet Adapter DHCP, guest os can not get IP on host resume (bug #19620)
|
||||
NAT: Fixed mss parameter handing (bug #15256)
|
||||
macOS host: Multiple optimizations for BigSur
|
||||
Audio: Fixed issues with audio playback after host goes to sleep (bug #18594)
|
||||
Documentation: Some content touch-up and table formatting fixes
|
||||
Linux host and guest: Support kernel version 5.10 (bug #20055)
|
||||
Solaris host: Fix regression breaking VGA text mode since version 6.1.0
|
||||
Guest Additions: Fixed a build failure affecting CentOS 8.2-2004 and later (bug #20091)
|
||||
Guest Additions: Fixed a build failure affecting Linux kernels 3.2.0 through 3.2.50 (bug #20006)
|
||||
Guest Additions: Fixed a VM segfault on copy with shared clipboard with X11 (bug #19226)
|
||||
Shared Folder: Fixed error with remounting on Linux guests
|
||||
|
||||
File "debug_mountsf.patch" is deleted - fixed upstream.
|
||||
File "linux-5.10-address-space-fixes.patch" is deleted - fixed upstream.
|
||||
File "linux-5.10-framebuffer-fixes.patch" is deleted - fixed upstream.
|
||||
File "linux-5.10-r0drv-memobj-fix-r0.patch" is deleted - fixed upstream.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Jan 14 19:26:59 UTC 2021 - Larry Finger <Larry.Finger@gmail.com>
|
||||
|
||||
|
@ -66,7 +66,7 @@ python3 -O -c "import sys, os, compileall; br='%{buildroot}'; compileall.compile
|
||||
|
||||
# ********* If the VB version exceeds 6.1.x, notify the libvirt maintainer!!
|
||||
Name: virtualbox%{?dash}%{?name_suffix}
|
||||
Version: 6.1.16
|
||||
Version: 6.1.18
|
||||
Release: 0
|
||||
Summary: %{package_summary}
|
||||
License: GPL-2.0-or-later
|
||||
@ -178,13 +178,8 @@ Patch135: fix-missing-includes-with-qt-5.15.patch
|
||||
Patch136: fixes_for_gcc10.patch
|
||||
# Fix for changes in GSOAP 2.8.103
|
||||
Patch137: handle_gsoap_208103.patch
|
||||
# Fixes for kernel 5.10
|
||||
Patch138: linux-5.10-r0drv-memobj-fix-r0.patch
|
||||
Patch139: linux-5.10-address-space-fixes.patch
|
||||
Patch140: linux-5.10-framebuffer-fixes.patch
|
||||
Patch138: fixes-for-5.11.patch
|
||||
Patch141: vb-6.1.16-modal-dialog-parent.patch
|
||||
Patch142: fixes-for-5.11.patch
|
||||
Patch998: debug_mountsf.patch
|
||||
Patch999: virtualbox-fix-ui-background-color.patch
|
||||
#
|
||||
|
||||
@ -493,12 +488,8 @@ This package contains the kernel-modules that VirtualBox uses to create or run v
|
||||
%patch136 -p1
|
||||
%patch137 -p1
|
||||
%patch138 -p1
|
||||
%patch139 -p1
|
||||
%patch140 -p1
|
||||
%patch141 -p1
|
||||
%patch142 -p1
|
||||
# make VB UI background colors look sane again
|
||||
%patch998 -p1
|
||||
%patch999 -p1
|
||||
|
||||
### Documents for virtualbox main package ###
|
||||
|
Loading…
Reference in New Issue
Block a user