summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorJean-Marc Lenoir2024-03-01 18:47:40 +0100
committerJean-Marc Lenoir2024-03-01 18:47:40 +0100
commitd55ab52fa4939e988b6102921edf9a32bf41b5d7 (patch)
tree15ce7579693420b031b600ea1694e789f8ce7de5
parent6715187a7b26aca7cf4b0948d4699e0911f6639c (diff)
downloadaur-d55ab52fa4939e988b6102921edf9a32bf41b5d7.tar.gz
Fix compatibility with Linux 6.8-rc6
-rw-r--r--.SRCINFO6
-rw-r--r--PKGBUILD6
-rw-r--r--vmmon.patch179
-rw-r--r--vmnet.patch114
4 files changed, 293 insertions, 12 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 116963060afc..ea84c4013314 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -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 = 17
+ pkgrel = 18
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 = f8aced664a513b358f1dbbe387178bfc156aadb3f68695a7ca8a2167ac87525a
- sha256sums = 41729b3b4a827fad2ec624b0f5fbbfbfbf6512df7ef0f7103598e15bfd5b26e1
+ sha256sums = ff327a4de16d705b4337adf66eb48435c045e9aa51862112dab5c42fab542459
+ sha256sums = 6e455d89f6209aa3f5dfa3dbaed8bef8314c331aa48e4d69012ec8aaab140407
pkgname = vmware-workstation15
diff --git a/PKGBUILD b/PKGBUILD
index 4763e1d1f135..ea6e407ecf0f 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -16,7 +16,7 @@ pkgname=vmware-workstation15
pkgver=15.5.7
_buildver=17171714
_pkgver=${pkgver}_${_buildver}
-pkgrel=17
+pkgrel=18
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'
- 'f8aced664a513b358f1dbbe387178bfc156aadb3f68695a7ca8a2167ac87525a'
- '41729b3b4a827fad2ec624b0f5fbbfbfbf6512df7ef0f7103598e15bfd5b26e1'
+ 'ff327a4de16d705b4337adf66eb48435c045e9aa51862112dab5c42fab542459'
+ '6e455d89f6209aa3f5dfa3dbaed8bef8314c331aa48e4d69012ec8aaab140407'
)
options=(!strip emptydirs)
diff --git a/vmmon.patch b/vmmon.patch
index 87fc4195ac53..1ec443375812 100644
--- a/vmmon.patch
+++ b/vmmon.patch
@@ -48,6 +48,50 @@
# include <stddef.h>
#else
/*
+--- a/vmmon/linux/driver.c
++++ b/vmmon/linux/driver.c
+@@ -246,7 +246,7 @@
+ /*
+ *----------------------------------------------------------------------
+ *
+- * init_module --
++ * LinuxDriverInit --
+ *
+ * linux module entry point. Called by /sbin/insmod command
+ *
+@@ -259,7 +259,7 @@
+ */
+
+ int
+-init_module(void)
++LinuxDriverInit(void)
+ {
+ int retval;
+
+@@ -340,7 +340,7 @@
+ /*
+ *----------------------------------------------------------------------
+ *
+- * cleanup_module --
++ * LinuxDriverExit --
+ *
+ * Called by /sbin/rmmod
+ *
+@@ -349,7 +349,7 @@
+ */
+
+ void
+-cleanup_module(void)
++LinuxDriverExit(void)
+ {
+ /*
+ * XXX smp race?
+@@ -1448,3 +1448,5 @@
+ * by default (i.e., neither mkinitrd nor modprobe will accept it).
+ */
+ MODULE_INFO(supported, "external");
++module_init(LinuxDriverInit);
++module_exit(LinuxDriverExit);
--- a/vmmon/linux/hostif.c
+++ b/vmmon/linux/hostif.c
@@ -47,6 +47,8 @@
@@ -252,7 +296,7 @@
int res;
int signalFD = args[1];
uint64 value = 1; // make an eventfd happy should it be there
-@@ -2699,22 +2741,32 @@
+@@ -2699,22 +2741,36 @@
return MX_WAITERROR;
}
@@ -264,7 +308,11 @@
+ */
+ eventfd = eventfd_ctx_fileget(file);
+ if (!IS_ERR(eventfd)) {
++#if COMPAT_LINUX_VERSION_CHECK_LT(6, 8, 0)
+ eventfd_signal(eventfd, 1);
++#else
++ eventfd_signal(eventfd);
++#endif
+ fput(file);
+ return MX_WAITNORMAL;
+ }
@@ -406,3 +454,132 @@ index 3f43c62..7eaa49a 100644
+#endif /* COMPAT_LINUX_VERSION_CHECK_LT(6, 5, 0) */
+
#endif /* __PGTBL_H__ */
+From 2c6d66f3f1947384038b765c897b102ecdb18298 Mon Sep 17 00:00:00 2001
+From: Michal Kubecek <mkubecek@suse.cz>
+Date: Fri, 12 Jan 2024 08:30:33 +0100
+Subject: [PATCH] modules: fix build with -Wmissing-prototypes
+
+Mainline commit 0fcb70851fbf ("Makefile.extrawarn: turn on
+missing-prototypes globally") in 6.8-rc1 enables -Wmissing-prototypes
+globally, revealing a lot of unclean code and also some actual problems.
+This is also the case in vmmon and vmnet modules.
+
+Most of them are addressed by making functions used only within one file
+static. The missing prototype of random_get_entropy_fallback() is handled
+by including <linux/timex.h> rather than <asm/timex.h>.
+
+Finally, there are four functions in vmnet module which are actually used
+in multiple files but instead of proper declarations, their prototype is
+duplicated in vmnet-only/driver.c, risking that the two copies won't match
+(which actually happened in one case). The cleanest solution would be
+creating separate header files for them (bridge.h, netif.h, userif.h and
+vnetUserListener.h) and including them in the respective source file and
+driver.c. As the developers already handle similar cases by simply putting
+the declarations into vnetInt.h, let us do the same to keep things simple.
+---
+ vmmon-only/common/task.c | 2 +-
+ vmmon-only/common/vmx86.c | 6 +++---
+ vmmon-only/linux/driver.c | 4 ++--
+ vmmon-only/linux/hostif.c | 6 +++---
+ vmnet-only/bridge.c | 2 +-
+ vmnet-only/driver.c | 16 ++--------------
+ vmnet-only/vnetInt.h | 7 +++++++
+ 7 files changed, 19 insertions(+), 24 deletions(-)
+
+diff --git a/vmmon-only/common/task.c b/vmmon-only/common/task.c
+index 5d34cf4d..f3752069 100644
+--- a/vmmon-only/common/task.c
++++ b/vmmon-only/common/task.c
+@@ -542,7 +542,7 @@ Task_Terminate(void)
+ *-----------------------------------------------------------------------------
+ */
+
+-Selector
++static Selector
+ TaskGetFlatWriteableDataSegment(void)
+ {
+ DTR hostGDTR;
+diff --git a/vmmon-only/common/vmx86.c b/vmmon-only/common/vmx86.c
+index 86e52fb4..cf64b123 100644
+--- a/vmmon-only/common/vmx86.c
++++ b/vmmon-only/common/vmx86.c
+@@ -56,7 +56,7 @@
+ #include "x86svm.h"
+ #include "x86cpuid_asm.h"
+ #if defined(__linux__)
+-#include <asm/timex.h>
++#include <linux/timex.h>
+ #endif
+ #include "perfctr.h"
+ #include "x86vtinstr.h"
+@@ -583,7 +583,7 @@ Vmx86FreeCrossPages(VMDriver *vm)
+ *-----------------------------------------------------------------------------
+ */
+
+-void
++static void
+ Vmx86FreeVMDriver(VMDriver *vm)
+ {
+ Vmx86_Free(vm->ptRootMpns);
+@@ -616,7 +616,7 @@ Vmx86FreeVMDriver(VMDriver *vm)
+ *-----------------------------------------------------------------------------
+ */
+
+-VMDriver *
++static VMDriver *
+ Vmx86AllocVMDriver(uint32 numVCPUs)
+ {
+ VMDriver *vm = Vmx86_Calloc(1, sizeof *vm, TRUE);
+diff --git a/vmmon-only/linux/driver.c b/vmmon-only/linux/driver.c
+index 3d8b7228..ab8e2dc4 100644
+--- a/vmmon-only/linux/driver.c
++++ b/vmmon-only/linux/driver.c
+@@ -258,7 +258,7 @@ LinuxDriverInitTSCkHz(void)
+ *----------------------------------------------------------------------
+ */
+
+-int
++static int
+ LinuxDriverInit(void)
+ {
+ int retval;
+@@ -348,7 +348,7 @@ LinuxDriverInit(void)
+ *----------------------------------------------------------------------
+ */
+
+-void
++static void
+ LinuxDriverExit(void)
+ {
+ /*
+diff --git a/vmmon-only/linux/hostif.c b/vmmon-only/linux/hostif.c
+index 5d08f33a..c1e6c671 100644
+--- a/vmmon-only/linux/hostif.c
++++ b/vmmon-only/linux/hostif.c
+@@ -2997,7 +2997,7 @@ HostIF_CallOnEachCPU(void (*func)(void*), // IN: function to call
+ *-----------------------------------------------------------------------------
+ */
+
+-Bool
++static Bool
+ HostIFCheckTrackedMPN(VMDriver *vm, // IN: The VM instance
+ MPN mpn) // IN: The MPN
+ {
+@@ -3117,7 +3117,7 @@ HostIF_ReadPhysical(VMDriver *vm, // IN: The VM instance
+ *----------------------------------------------------------------------
+ */
+
+-int
++static int
+ HostIFWritePhysicalWork(MA ma, // MA to be written to
+ VA64 addr, // src data to write
+ Bool kernelBuffer, // is the buffer in kernel space?
+@@ -3276,7 +3276,7 @@ HostIF_GetCurrentPCPU(void)
+ *----------------------------------------------------------------------
+ */
+
+-int
++static int
+ HostIFStartTimer(Bool rateChanged, //IN: Did rate change?
+ unsigned int rate) //IN: current clock rate
+ {
diff --git a/vmnet.patch b/vmnet.patch
index 6978f8d8a856..3e28898e9749 100644
--- a/vmnet.patch
+++ b/vmnet.patch
@@ -54,7 +54,7 @@
# endif
--- a/vmnet/driver.c
+++ b/vmnet/driver.c
-@@ -279,7 +279,7 @@ VNetRemovePortFromList(const VNetPort *port) // IN: port to remove from list
+@@ -279,7 +279,7 @@
/*
*----------------------------------------------------------------------
*
@@ -63,7 +63,7 @@
*
* linux module entry point. Called by /sbin/insmod command.
* Initializes module and Registers this driver for a
-@@ -296,7 +296,7 @@ VNetRemovePortFromList(const VNetPort *port) // IN: port to remove from list
+@@ -296,7 +296,7 @@
*/
int
@@ -72,7 +72,7 @@
{
int retval;
-@@ -358,7 +358,7 @@ init_module(void)
+@@ -358,7 +358,7 @@
/*
*----------------------------------------------------------------------
*
@@ -81,7 +81,7 @@
*
* Called by /sbin/rmmod. Unregisters this driver for a
* vnet major #, and deinitializes the modules. The 64-bit
-@@ -375,7 +375,7 @@ init_module(void)
+@@ -375,7 +375,7 @@
*/
void
@@ -90,7 +90,7 @@
{
unregister_chrdev(VNET_MAJOR_NUMBER, "vmnet");
VNetProtoUnregister();
-@@ -1701,3 +1701,5 @@ MODULE_LICENSE("GPL v2");
+@@ -1701,3 +1701,5 @@
* by default (i.e., neither mkinitrd nor modprobe will accept it).
*/
MODULE_INFO(supported, "external");
@@ -354,3 +354,107 @@ Fixing VMWare Player on Linux when using DHCP addresses: https://www.nikhef.nl/~
if (count < n) {
n = count;
}
+From 2c6d66f3f1947384038b765c897b102ecdb18298 Mon Sep 17 00:00:00 2001
+From: Michal Kubecek <mkubecek@suse.cz>
+Date: Fri, 12 Jan 2024 08:30:33 +0100
+Subject: [PATCH] modules: fix build with -Wmissing-prototypes
+
+Mainline commit 0fcb70851fbf ("Makefile.extrawarn: turn on
+missing-prototypes globally") in 6.8-rc1 enables -Wmissing-prototypes
+globally, revealing a lot of unclean code and also some actual problems.
+This is also the case in vmmon and vmnet modules.
+
+Most of them are addressed by making functions used only within one file
+static. The missing prototype of random_get_entropy_fallback() is handled
+by including <linux/timex.h> rather than <asm/timex.h>.
+
+Finally, there are four functions in vmnet module which are actually used
+in multiple files but instead of proper declarations, their prototype is
+duplicated in vmnet-only/driver.c, risking that the two copies won't match
+(which actually happened in one case). The cleanest solution would be
+creating separate header files for them (bridge.h, netif.h, userif.h and
+vnetUserListener.h) and including them in the respective source file and
+driver.c. As the developers already handle similar cases by simply putting
+the declarations into vnetInt.h, let us do the same to keep things simple.
+---
+ vmmon-only/common/task.c | 2 +-
+ vmmon-only/common/vmx86.c | 6 +++---
+ vmmon-only/linux/driver.c | 4 ++--
+ vmmon-only/linux/hostif.c | 6 +++---
+ vmnet-only/bridge.c | 2 +-
+ vmnet-only/driver.c | 16 ++--------------
+ vmnet-only/vnetInt.h | 7 +++++++
+ 7 files changed, 19 insertions(+), 24 deletions(-)
+
+diff --git a/vmnet-only/bridge.c b/vmnet-only/bridge.c
+index b604a25d..4c139570 100644
+--- a/vmnet-only/bridge.c
++++ b/vmnet-only/bridge.c
+@@ -1405,7 +1405,7 @@ VNetBridgeComputeHeaderPos(struct sk_buff *skb) // IN: buffer to examine
+ *----------------------------------------------------------------------
+ */
+
+-void
++static void
+ VNetBridgeSendLargePacket(struct sk_buff *skb, // IN: packet to split
+ VNetBridge *bridge) // IN: bridge
+ {
+diff --git a/vmnet-only/driver.c b/vmnet-only/driver.c
+index f314ff2e..fe5923d8 100644
+--- a/vmnet-only/driver.c
++++ b/vmnet-only/driver.c
+@@ -50,18 +50,6 @@
+
+ #include "vmnetInt.h"
+
+-/*
+- * Initialization and creation routines from other files.
+- * Putting them here reduces the need for so many header files.
+- */
+-
+-extern int VNetUserIf_Create(VNetPort **ret);
+-extern int VNetNetIf_Create(char *devName, VNetPort **ret, int hubNum);
+-extern int VNetBridge_Create(char *devName, uint32 flags, VNetJack *hubJack,
+- VNetPort **ret);
+-extern int VNetUserListener_Create(uint32 classMask, VNetJack *hubJack, VNetPort **ret);
+-
+-
+ /*
+ * Structure for cycle detection of host interfaces. This
+ * struct is only used by VNetCycleDetectIf().
+@@ -295,7 +283,7 @@ VNetRemovePortFromList(const VNetPort *port) // IN: port to remove from list
+ *----------------------------------------------------------------------
+ */
+
+-int
++static int
+ LinuxDriverInit(void)
+ {
+ int retval;
+@@ -374,7 +362,7 @@ vmnet_init_module(void)
+ *----------------------------------------------------------------------
+ */
+
+-void
++static void
+ LinuxDriverExit(void)
+ {
+ unregister_chrdev(VNET_MAJOR_NUMBER, "vmnet");
+diff --git a/vmnet-only/vnetInt.h b/vmnet-only/vnetInt.h
+index f6a90a13..e76dcf5c 100644
+--- a/vmnet-only/vnetInt.h
++++ b/vmnet-only/vnetInt.h
+@@ -218,6 +218,13 @@ extern int VNetProc_Init(void);
+
+ extern void VNetProc_Cleanup(void);
+
++int VNetNetIf_Create(char *devName, VNetPort **ret, int hubNum);
++int VNetUserIf_Create(VNetPort **ret);
++int VNetBridge_Create(const char *devName, uint32 flags, VNetJack *hubJack,
++ VNetPort **ret);
++int VNetUserListener_Create(uint32 classMask, VNetJack *hubJack,
++ VNetPort **port);
++
+
+ /*
+ *----------------------------------------------------------------------