2

Trying to build the VMware modules on Ubuntu-18.10 with linux-5.0.1-050001-generic

vmware-modconfig --console --install-all

Here's the whole output: https://pastebin.com/d61HGWJR


In file included from /tmp/modconfig-QBnnBd/vmmon-only/linux/hostif.c:42:
./include/linux/mm.h:52:29: note: previous definition of ‘totalram_pages’ was here
 static inline unsigned long totalram_pages(void)
                             ^~~~~~~~~~~~~~
/tmp/modconfig-QBnnBd/vmmon-only/linux/hostif.c: In function ‘HostIFReadUptimeWork’:
/tmp/modconfig-QBnnBd/vmmon-only/linux/hostif.c:1787:4: error: implicit declaration of function ‘do_gettimeofday’; did you mean ‘do_settimeofday64’? [-Werror=implicit-function-declaration]
    do_gettimeofday(&tv);
    ^~~~~~~~~~~~~~~
    do_settimeofday64
/tmp/modconfig-QBnnBd/vmmon-only/linux/hostif.c: In function ‘HostIF_MapUserMem’:
/tmp/modconfig-QBnnBd/vmmon-only/linux/hostif.c:3408:40: error: macro "access_ok" passed 3 arguments, but takes just 2
    if (!access_ok(VERIFY_WRITE, p, size)) {
                                        ^
/tmp/modconfig-QBnnBd/vmmon-only/linux/hostif.c:3408:9: error: ‘access_ok’ undeclared (first use in this function)
    if (!access_ok(VERIFY_WRITE, p, size)) {
         ^~~~~~~~~
/tmp/modconfig-QBnnBd/vmmon-only/linux/hostif.c:3408:9: note: each undeclared identifier is reported only once for each function it appears in
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:277: /tmp/modconfig-QBnnBd/vmmon-only/linux/hostif.o] Error 1
make[2]: *** Waiting for unfinished jobs....
/tmp/modconfig-QBnnBd/vmmon-only/common/task.o: warning: objtool: Task_Switch()+0x4db: indirect call found in RETPOLINE build
/tmp/modconfig-QBnnBd/vmmon-only/common/task.o: warning: objtool: .text: unexpected end of section
make[1]: *** [Makefile:1553: _module_/tmp/modconfig-QBnnBd/vmmon-only] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-5.0.1-050001-generic'
make: *** [Makefile:110: vmmon.ko] Error 2
make: Leaving directory '/tmp/modconfig-QBnnBd/vmmon-only'
make: Entering directory '/tmp/modconfig-QBnnBd/vmnet-only'
Using kernel build system.
/usr/bin/make -C /lib/modules/5.0.1-050001-generic/build/include/.. SUBDIRS=$PWD SRCROOT=$PWD/. \
  MODULEBUILDDIR= modules
make[1]: Entering directory '/usr/src/linux-headers-5.0.1-050001-generic'
Makefile:189: ================= WARNING ================
Makefile:190: 'SUBDIRS' will be removed after Linux 5.3
Makefile:191: Please use 'M=' or 'KBUILD_EXTMOD' instead
Makefile:192: ==========================================
  CC [M]  /tmp/modconfig-QBnnBd/vmnet-only/driver.o
  CC [M]  /tmp/modconfig-QBnnBd/vmnet-only/hub.o
  CC [M]  /tmp/modconfig-QBnnBd/vmnet-only/userif.o
  CC [M]  /tmp/modconfig-QBnnBd/vmnet-only/netif.o
  CC [M]  /tmp/modconfig-QBnnBd/vmnet-only/bridge.o
  CC [M]  /tmp/modconfig-QBnnBd/vmnet-only/procfs.o
  CC [M]  /tmp/modconfig-QBnnBd/vmnet-only/smac_compat.o
  CC [M]  /tmp/modconfig-QBnnBd/vmnet-only/smac.o
/tmp/modconfig-QBnnBd/vmnet-only/userif.c: In function ‘VNetUserIfMapPtr’:
/tmp/modconfig-QBnnBd/vmnet-only/userif.c:145:52: error: macro "access_ok" passed 3 arguments, but takes just 2
    if (!access_ok(VERIFY_WRITE, (void *)uAddr, size) ||
                                                    ^
/tmp/modconfig-QBnnBd/vmnet-only/userif.c:145:9: error: ‘access_ok’ undeclared (first use in this function)
    if (!access_ok(VERIFY_WRITE, (void *)uAddr, size) ||
         ^~~~~~~~~
/tmp/modconfig-QBnnBd/vmnet-only/userif.c:145:9: note: each undeclared identifier is reported only once for each function it appears in
In file included from ./include/linux/pci.h:37,
                 from /tmp/modconfig-QBnnBd/vmnet-only/compat_netdevice.h:27,
                 from /tmp/modconfig-QBnnBd/vmnet-only/netif.c:43:
./include/linux/pci_ids.h:2278: warning: "PCI_VENDOR_ID_VMWARE" redefined
 #define PCI_VENDOR_ID_VMWARE  0x15ad

In file included from /tmp/modconfig-QBnnBd/vmnet-only/net.h:38,
                 from /tmp/modconfig-QBnnBd/vmnet-only/vnetInt.h:26,
                 from /tmp/modconfig-QBnnBd/vmnet-only/netif.c:42:
/tmp/modconfig-QBnnBd/vmnet-only/vm_device_version.h:56: note: this is the location of the previous definition
 #define PCI_VENDOR_ID_VMWARE                    0x15AD

In file included from ./include/linux/pci.h:37,
                 from /tmp/modconfig-QBnnBd/vmnet-only/compat_netdevice.h:27,
                 from /tmp/modconfig-QBnnBd/vmnet-only/netif.c:43:
./include/linux/pci_ids.h:2279: warning: "PCI_DEVICE_ID_VMWARE_VMXNET3" redefined
 #define PCI_DEVICE_ID_VMWARE_VMXNET3 0x07b0

In file included from /tmp/modconfig-QBnnBd/vmnet-only/net.h:38,
                 from /tmp/modconfig-QBnnBd/vmnet-only/vnetInt.h:26,
                 from /tmp/modconfig-QBnnBd/vmnet-only/netif.c:42:
/tmp/modconfig-QBnnBd/vmnet-only/vm_device_version.h:73: note: this is the location of the previous definition
 #define PCI_DEVICE_ID_VMWARE_VMXNET3            0x07B0

  CC [M]  /tmp/modconfig-QBnnBd/vmnet-only/vnetEvent.o
make[2]: *** [scripts/Makefile.build:277: /tmp/modconfig-QBnnBd/vmnet-only/userif.o] Error 1
make[2]: *** Waiting for unfinished jobs....
In file included from /tmp/modconfig-QBnnBd/vmnet-only/net.h:38,
                 from /tmp/modconfig-QBnnBd/vmnet-only/vnetInt.h:26,
                 from /tmp/modconfig-QBnnBd/vmnet-only/bridge.c:53:
/tmp/modconfig-QBnnBd/vmnet-only/vm_device_version.h:56: warning: "PCI_VENDOR_ID_VMWARE" redefined
 #define PCI_VENDOR_ID_VMWARE                    0x15AD

In file included from ./include/linux/pci.h:37,
                 from /tmp/modconfig-QBnnBd/vmnet-only/compat_netdevice.h:27,
                 from /tmp/modconfig-QBnnBd/vmnet-only/bridge.c:52:
./include/linux/pci_ids.h:2278: note: this is the location of the previous definition
 #define PCI_VENDOR_ID_VMWARE  0x15ad

In file included from /tmp/modconfig-QBnnBd/vmnet-only/net.h:38,
                 from /tmp/modconfig-QBnnBd/vmnet-only/vnetInt.h:26,
                 from /tmp/modconfig-QBnnBd/vmnet-only/bridge.c:53:
/tmp/modconfig-QBnnBd/vmnet-only/vm_device_version.h:73: warning: "PCI_DEVICE_ID_VMWARE_VMXNET3" redefined
 #define PCI_DEVICE_ID_VMWARE_VMXNET3            0x07B0

In file included from ./include/linux/pci.h:37,
                 from /tmp/modconfig-QBnnBd/vmnet-only/compat_netdevice.h:27,
                 from /tmp/modconfig-QBnnBd/vmnet-only/bridge.c:52:
./include/linux/pci_ids.h:2279: note: this is the location of the previous definition
 #define PCI_DEVICE_ID_VMWARE_VMXNET3 0x07b0

make[1]: *** [Makefile:1553: _module_/tmp/modconfig-QBnnBd/vmnet-only] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-5.0.1-050001-generic'
make: *** [Makefile:110: vmnet.ko] Error 2
make: Leaving directory '/tmp/modconfig-QBnnBd/vmnet-only'
Unable to install all modules.  See log for details.
1

Use the patches over at github.com/mkubecek/vmware-host-modules.

You'll need to know if you're trying to install VMWare Workstation or Player, and which version. In the example below I'm assuming VMWare Workstation 15.0.1:

$ git clone https://github.com/mkubecek/vmware-host-modules
$ cd vmware-host-modules
$ git checkout workstation-15.0.1
$ make
$ sudo make install

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.