diff options
author | Jean-Marc Lenoir | 2022-04-09 15:34:50 +0200 |
---|---|---|
committer | Jean-Marc Lenoir | 2022-04-09 15:34:50 +0200 |
commit | 58259609c60ecd1dd070b4b8a1fe266c99519e88 (patch) | |
tree | a5a9f3fbb6676697700024ebbac482aaa97f9923 | |
parent | 5825073a9359e02bcfab56ecfc0a2f5d70eb58a5 (diff) | |
download | aur-58259609c60ecd1dd070b4b8a1fe266c99519e88.tar.gz |
Compatibility with Linux 5.18-rc1
-rw-r--r-- | .SRCINFO | 6 | ||||
-rw-r--r-- | PKGBUILD | 6 | ||||
-rw-r--r-- | vmmon.patch | 28 | ||||
-rw-r--r-- | vmnet.patch | 63 |
4 files changed, 97 insertions, 6 deletions
@@ -1,7 +1,7 @@ pkgbase = vmware-workstation15 pkgdesc = The industry standard for running multiple operating systems as virtual machines on a single Linux PC. pkgver = 15.5.7 - pkgrel = 7 + pkgrel = 8 url = https://www.vmware.com/products/workstation-for-linux.html install = vmware-workstation.install arch = x86_64 @@ -86,7 +86,7 @@ pkgbase = vmware-workstation15 sha256sums = fe1b1be8297f4170406f97dd1f8b385d911faf45afe19cbc0c26b8092b3ddf8d sha256sums = 10562d11d50edab9abc2b29c8948714edcb9b084f99b3766d07ddd21259e372e sha256sums = 273d4357599a3e54259c78cc49054fef8ecfd2c2eda35cbcde3a53a62777a5ac - sha256sums = ee126feeb07e36b8ba43135fbbb81d20d0bc0d30e4e00f153ecc5aa87cfcf786 - sha256sums = eb0fcc4b08d304e5a86a5aa3dac191dc7657a6fe7e8f7cc7e481310bcd264a1e + sha256sums = 0d4c178c4ab2ea9af79e92268c57822abf8e5f19882db9b2a3faf73ca6cb6202 + sha256sums = 4949a11646603e855ca60db94d6e5609cba2b4dbbc34b5bde95b363243e0cfea pkgname = vmware-workstation15 @@ -16,7 +16,7 @@ pkgname=vmware-workstation15 pkgver=15.5.7 _buildver=17171714 _pkgver=${pkgver}_${_buildver} -pkgrel=7 +pkgrel=8 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' @@ -123,8 +123,8 @@ sha256sums=( '10562d11d50edab9abc2b29c8948714edcb9b084f99b3766d07ddd21259e372e' '273d4357599a3e54259c78cc49054fef8ecfd2c2eda35cbcde3a53a62777a5ac' - 'ee126feeb07e36b8ba43135fbbb81d20d0bc0d30e4e00f153ecc5aa87cfcf786' - 'eb0fcc4b08d304e5a86a5aa3dac191dc7657a6fe7e8f7cc7e481310bcd264a1e' + '0d4c178c4ab2ea9af79e92268c57822abf8e5f19882db9b2a3faf73ca6cb6202' + '4949a11646603e855ca60db94d6e5609cba2b4dbbc34b5bde95b363243e0cfea' ) options=(!strip emptydirs) diff --git a/vmmon.patch b/vmmon.patch index 27e8fb449b08..0620eea41650 100644 --- a/vmmon.patch +++ b/vmmon.patch @@ -310,3 +310,31 @@ index 0ec30b3..b920e2d 100644 #else /* * Vmkernel's bogus __FreeBSD__ value causes gcc <stddef.h> to break. +From 16d490ae022d7fc4ca867971e20e2dcd59e6ca5a Mon Sep 17 00:00:00 2001 +From: Michal Kubecek <mkubecek@suse.cz> +Date: Mon, 4 Apr 2022 01:57:28 +0200 +Subject: [PATCH] vmmon: do not rely on HAVE_GET_KERNEL_NOFAULT + +Mainline commit 34737e269803 ("uaccess: add generic +__{get,put}_kernel_nofault") in 5.18-rc1 removes HAVE_GET_KERNEL_NOFAULT +macro as all architectures can use get_kernel_nofault() now. Check for +existence of __get_kernel_nofault() instead and add also a version check in +case it stops being a macro or is removed in the future. +--- + vmmon-only/linux/hostif.c | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/vmmon-only/linux/hostif.c b/vmmon-only/linux/hostif.c +index a21c300..b6326e9 100644 +--- a/vmmon-only/linux/hostif.c ++++ b/vmmon-only/linux/hostif.c +@@ -2436,7 +2436,8 @@ isVAReadable(VA r) // IN: + uint32 dummy; + int ret; + +-#ifdef HAVE_GET_KERNEL_NOFAULT ++#if defined(HAVE_GET_KERNEL_NOFAULT) || defined(__get_kernel_nofault) || \ ++ (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 18, 0)) + ret = get_kernel_nofault(dummy, (void *)r); + #else + { diff --git a/vmnet.patch b/vmnet.patch index cb1d33b7af56..ebe43ce40bd9 100644 --- a/vmnet.patch +++ b/vmnet.patch @@ -91,3 +91,66 @@ index 0ec30b3..b920e2d 100644 #else /* * Vmkernel's bogus __FreeBSD__ value causes gcc <stddef.h> to break. +From 409623bd4693afada659af82e823a6291f70797a Mon Sep 17 00:00:00 2001 +From: Michal Kubecek <mkubecek@suse.cz> +Date: Mon, 4 Apr 2022 02:05:17 +0200 +Subject: [PATCH] vmnet: use netif_rx() on newer kernels + +In mainline 5.18-rc1, commit baebdf48c360 ("net: dev: Makes sure netif_rx() +can be invoked in any context.") allows calling netif_rx() from any context +and commit 2655926aea9b ("net: Remove netif_rx_any_context() and +netif_rx_ni().") drops netif_rx_ni() as it is no longer needed. + +Replace calls of netif_rx_ni() in VNetBridgeReceiveFromVNet() and +VNetNetIfReceive() by netif_rx() when building against kernel 5.18 and +newer. +--- + vmnet-only/bridge.c | 2 +- + vmnet-only/compat_netdevice.h | 9 +++++++++ + vmnet-only/netif.c | 2 +- + 3 files changed, 11 insertions(+), 2 deletions(-) + +diff --git a/vmnet-only/bridge.c b/vmnet-only/bridge.c +index c84f8ee..d6bd3c4 100644 +--- a/vmnet-only/bridge.c ++++ b/vmnet-only/bridge.c +@@ -691,7 +691,7 @@ VNetBridgeReceiveFromVNet(VNetJack *this, // IN: jack + * not do it, or netif_rx_ni() will deadlock on the cli() lock --hpreg + */ + +- netif_rx_ni(clone); ++ compat_netif_rx_ni(clone); + # if LOGLEVEL >= 4 + do_gettimeofday(&vnetTime); + # endif +diff --git a/vmnet-only/compat_netdevice.h b/vmnet-only/compat_netdevice.h +index bb5001b..c6cc706 100644 +--- a/vmnet-only/compat_netdevice.h ++++ b/vmnet-only/compat_netdevice.h +@@ -343,4 +343,13 @@ typedef u32 compat_netdev_features_t; + #define compat_netif_trans_update(d) do { (d)->trans_start = jiffies; } while (0) + #endif + ++static inline int compat_netif_rx_ni(struct sk_buff *skb) ++{ ++#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 18, 0) ++ return netif_rx(skb); ++#else ++ return netif_rx_ni(skb); ++#endif ++} ++ + #endif /* __COMPAT_NETDEVICE_H__ */ +diff --git a/vmnet-only/netif.c b/vmnet-only/netif.c +index 8c3bbf8..35256a0 100644 +--- a/vmnet-only/netif.c ++++ b/vmnet-only/netif.c +@@ -345,7 +345,7 @@ VNetNetIfReceive(VNetJack *this, // IN: jack + /* send to the host interface */ + skb->dev = netIf->dev; + skb->protocol = eth_type_trans(skb, netIf->dev); +- netif_rx_ni(skb); ++ compat_netif_rx_ni(skb); + netIf->stats.rx_packets++; + + return; |