diff options
-rw-r--r-- | .SRCINFO | 4 | ||||
-rw-r--r-- | PKGBUILD | 4 | ||||
-rw-r--r-- | vmmon.patch | 102 |
3 files changed, 97 insertions, 13 deletions
@@ -1,7 +1,7 @@ pkgbase = vmware-workstation11 pkgdesc = The industry standard for running multiple operating systems as virtual machines on a single Linux PC. pkgver = 11.1.4 - pkgrel = 12 + pkgrel = 13 url = https://www.vmware.com/products/workstation-for-linux.html install = vmware-workstation.install arch = x86_64 @@ -79,7 +79,7 @@ pkgbase = vmware-workstation11 sha256sums = d7a9fbf39a0345ae2f14f7f389f30b1110f605d187e0c241e99bbb18993c250d sha256sums = 05e26d8b21d190ebabb7f693998114d9d5991d9dfb71acb4d990293a65b6b487 sha256sums = 6ce902b1dab8fc69be253abd8e79017011985eca850ff7acc7282f9ab668e35d - sha256sums = 33f9a99d5c152ace972dbe227efe17ea0a2094bed3f10dafc99c85c5af91042e + sha256sums = 3952919998d8970e31c4b5cbbfa0d1a8a91585f61ab85868b9de13d3f086f035 sha256sums = 601a5b24aa23a995a79474a57de4056d3c2a27caf3a4c079b3a271d0d1eb4083 pkgname = vmware-workstation11 @@ -16,7 +16,7 @@ pkgname=vmware-workstation11 pkgver=11.1.4 _buildver=3848939 _pkgver=${pkgver}_${_buildver} -pkgrel=12 +pkgrel=13 pkgdesc='The industry standard for running multiple operating systems as virtual machines on a single Linux PC.' arch=(x86_64) url='https://www.vmware.com/products/workstation-for-linux.html' @@ -116,7 +116,7 @@ sha256sums=( '05e26d8b21d190ebabb7f693998114d9d5991d9dfb71acb4d990293a65b6b487' '6ce902b1dab8fc69be253abd8e79017011985eca850ff7acc7282f9ab668e35d' - '33f9a99d5c152ace972dbe227efe17ea0a2094bed3f10dafc99c85c5af91042e' + '3952919998d8970e31c4b5cbbfa0d1a8a91585f61ab85868b9de13d3f086f035' '601a5b24aa23a995a79474a57de4056d3c2a27caf3a4c079b3a271d0d1eb4083' ) options=(!strip emptydirs) diff --git a/vmmon.patch b/vmmon.patch index 6fac361ec396..4f550efb0b4d 100644 --- a/vmmon.patch +++ b/vmmon.patch @@ -855,15 +855,6 @@ #endif /* __PGTBL_H__ */ --- a/vmmon/linux/driver.c +++ b/vmmon/linux/driver.c -@@ -39,6 +39,8 @@ - - #if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 16) - #error Linux before 2.6.16 is not supported -+#elif LINUX_VERSION_CODE >= KERNEL_VERSION(5, 8, 0) -+#error Linux kernels from 5.8.0 are not supported - #endif - - #include <asm/io.h> @@ -108,7 +108,11 @@ static int LinuxDriver_Close(struct inode *inode, struct file *filp); @@ -1518,3 +1509,96 @@ break; } +From 2da85cbe6d9c0bc5c7c2008748bd12e70ce0f310 Mon Sep 17 00:00:00 2001 +From: Jan Andres <jandres@gmx.net> +Date: Fri, 4 Sep 2020 10:53:10 +0200 +Subject: [PATCH] Fix NX bit handling for Linux 5.8+ + +Do not use vmap() to map the cross page, it needs to be executable and +vmap() unconditionally sets the NX bit starting with 5.8.x. + +Emulate previous behavior of vmap() by using alloc_vm_area() and +explicitly setting the PTE. +--- + vmmon-only/linux/hostif.c | 18 ++++++++++++++++++ + 1 file changed, 18 insertions(+) + +diff --git a/vmmon-only/linux/hostif.c b/vmmon-only/linux/hostif.c +index 3a48505..ec6856a 100644 +--- a/vmmon-only/linux/hostif.c ++++ b/vmmon-only/linux/hostif.c +@@ -72,6 +72,7 @@ + #endif + + #include <asm/io.h> ++#include <asm/tlbflush.h> + #include <asm/uaccess.h> + #include <linux/mc146818rtc.h> + #include <linux/capability.h> +@@ -699,7 +700,24 @@ HostIF_FastClockUnlock(int callerID) // IN + static void * + MapCrossPage(struct page *p) // IN: + { ++#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 8, 0) + return vmap(&p, 1, VM_MAP, VM_PAGE_KERNEL_EXEC); ++#else ++ /* Starting with 5.8, vmap() always sets the NX bit, but the cross ++ * page needs to be executable. */ ++ pte_t *ptes[1]; ++ struct vm_struct *area = alloc_vm_area(1UL << PAGE_SHIFT, ptes); ++ if (area == NULL) ++ return NULL; ++ ++ set_pte(ptes[0], mk_pte(p, VM_PAGE_KERNEL_EXEC)); ++ ++ preempt_disable(); ++ __flush_tlb_all(); ++ preempt_enable(); ++ ++ return area->addr; ++#endif + } + + +From c71e377757f20dc78a99d42a127124bb2c49e865 Mon Sep 17 00:00:00 2001 +From: Jan Andres <jandres@gmx.net> +Date: Fri, 4 Sep 2020 10:59:19 +0200 +Subject: [PATCH] Fix NULL pointer dereference in eventfd read call + +Starting with 5.8, the "read" function pointer in eventfd's +file_operations is NULL, "read_iter" is available instead. + +Use kernel_read() and kernel_write() instead of directly calling the +function pointers to handle this correctly. +--- + vmmon-only/linux/hostif.c | 8 ++++++++ + 1 file changed, 8 insertions(+) + +diff --git a/vmmon-only/linux/hostif.c b/vmmon-only/linux/hostif.c +index ec6856a..4a7afb1 100644 +--- a/vmmon-only/linux/hostif.c ++++ b/vmmon-only/linux/hostif.c +@@ -2588,7 +2588,11 @@ HostIF_SemaphoreWait(VMDriver *vm, // IN: + * reading no bytes (EAGAIN - non blocking fd) or sizeof(uint64). + */ + ++#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 8, 0) ++ res = kernel_read(file, (char *) &value, sizeof value, &file->f_pos); ++#else + res = file->f_op->read(file, (char *) &value, sizeof value, &file->f_pos); ++#endif + + if (res == sizeof value) { + res = MX_WAITNORMAL; +@@ -2701,7 +2705,11 @@ HostIF_SemaphoreSignal(uint64 *args) // IN: + * it be present. + */ + ++#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 8, 0) ++ res = kernel_write(file, (char *) &value, sizeof value, &file->f_pos); ++#else + res = file->f_op->write(file, (char *) &value, sizeof value, &file->f_pos); ++#endif + + if (res == sizeof value) { + res = MX_WAITNORMAL; |