Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 462666 - app-emulation/vmware-modules - .../work/vmblock-only/linux/inode.c:138:32: error: incompatible types when assigning to type ‘kgid_t’ from type ‘int’
Summary: app-emulation/vmware-modules - .../work/vmblock-only/linux/inode.c:138:32: er...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: All Linux
: Normal normal with 4 votes (vote)
Assignee: Gentoo VMWare Bug Squashers [disabled]
URL:
Whiteboard:
Keywords: PATCH
: 498520 506584 508734 518400 521408 521872 525158 (view as bug list)
Depends on:
Blocks:
 
Reported: 2013-03-22 09:03 UTC by Yvan Royon
Modified: 2015-08-25 16:16 UTC (History)
25 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
vmblock, vmci and vsock patch for USER_NS (271-userns.patch,1.49 KB, patch)
2013-03-22 09:07 UTC, Yvan Royon
Details | Diff
Kernel configuration for sys-kernel/gentoo-sources-3.10.7 (.config,81.19 KB, text/plain)
2013-10-06 11:45 UTC, Pavol Dilung
Details
app-emulation/vmware-modules-271.2-r1 ebuild that applies 271-userns.patch for gentoo-sources 3.8.0 and above (vmware-modules-271.2-r1.ebuild,2.19 KB, text/plain)
2013-10-06 11:48 UTC, Pavol Dilung
Details
Patch to inode.c (inode_patch.patch,604 bytes, patch)
2014-04-26 16:48 UTC, Harris Landgarten
Details | Diff
patch to get vmblock to modprobe (279-getname.patch,533 bytes, patch)
2014-04-26 17:14 UTC, Harris Landgarten
Details | Diff
vmware-3.11.patch (vmware-3.11.patch,2.43 KB, patch)
2014-04-29 03:05 UTC, Harris Landgarten
Details | Diff
279-312.patch (279-312.patch,1.19 KB, patch)
2014-04-29 03:05 UTC, Harris Landgarten
Details | Diff
more patches for 3.15.x (vmware-modules.tar.gz,22.39 KB, application/x-gtar-compressed)
2014-08-06 17:43 UTC, Alex Dubenetsky
Details
Patches to compile on 3.14.0 (kernel_3.14.0_patches.tar.gz,1.05 KB, application/x-gtar-compressed)
2014-09-14 11:39 UTC, T-Dawg
Details
vmware-modules ebuild 279.3-r3 & patch for 3.19/4.0 (vmware-modules.tar.bz2,32.78 KB, application/octet-stream)
2015-05-10 21:54 UTC, Alex Dubenetsky
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Yvan Royon 2013-03-22 09:03:02 UTC
I only tried those versions:
- sys-kernel/gentoo-sources-3.8.0 with CONFIG_USER_NS=y
- app-emulation/vmware-modules-271.2 (latest in Portage)

vmware-modules fails to compile:

[...]
error: incompatible types when assigning to type 'kgid_t' from type 'int'


Reproducible: Always
Comment 1 Yvan Royon 2013-03-22 09:07:49 UTC
Created attachment 342888 [details, diff]
vmblock, vmci and vsock patch for USER_NS

Basic patch to get vmware-modules to compile.

It works for me just like it worked without USER_NS.
I did not try running vmware from inside a user namespace.
Comment 2 Alexandre 2013-04-30 17:56:14 UTC
patch seems to work with sys-kernel/gentoo-sources-3.9.0 too
Comment 3 Sven 2013-08-27 18:02:00 UTC
Same error with kernel 3.10. Add the patch to portage please?
Comment 4 Sven 2013-09-04 17:52:35 UTC
A 271-3.10.0.patch has been added to the vmware-modules ebuild. And this issue still exists? What is going on?
Comment 5 Pavol Dilung 2013-10-06 11:34:31 UTC
ortage 2.2.1 (default/linux/amd64/13.0, gcc-4.7.3, glibc-2.15-r3, 3.10.7-gentoo-r1 x86_64)
=================================================================
System uname: Linux-3.10.7-gentoo-r1-x86_64-Intel-R-_Core-TM-_i7-2620M_CPU_@_2.70GHz-with-gentoo-2.2
KiB Mem:     3924628 total,    494308 free
KiB Swap:    1949812 total,   1858728 free
Timestamp of tree: Sun, 06 Oct 2013 10:15:01 +0000
ld GNU ld (GNU Binutils) 2.23.1
app-shells/bash:          4.2_p45
dev-java/java-config:     2.1.12-r1
dev-lang/python:          2.7.5-r2, 3.2.5-r2
dev-util/cmake:           2.8.10.2-r2
dev-util/pkgconfig:       0.28
sys-apps/baselayout:      2.2
sys-apps/openrc:          0.11.8
sys-apps/sandbox:         2.6-r1
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.9.6-r3, 1.11.6, 1.12.6, 1.13.4
sys-devel/binutils:       2.23.1
sys-devel/gcc:            4.6.3, 4.7.3-r1
sys-devel/gcc-config:     1.7.3
sys-devel/libtool:        2.4.2
sys-devel/make:           3.82-r4
sys-kernel/linux-headers: 3.9 (virtual/os-headers)
sys-libs/glibc:           2.15-r3
Repositories: gentoo sunrise x-portage
ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -fomit-frame-pointer -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt /var/lib/hsqldb"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/splash /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-march=native -fomit-frame-pointer -O2 -pipe"
DISTDIR="/var/portage/distfiles"
FCFLAGS="-march=native -fomit-frame-pointer -O2 -pipe"
FEATURES="assume-digests binpkg-logs cgroup clean-logs collision-protect config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync metadata-transfer news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync"
FFLAGS="-march=native -fomit-frame-pointer -O2 -pipe"
GENTOO_MIRRORS="ftp://mirror.switch.ch/mirror/gentoo/ http://mirror.gentoo.sk/pub ftp://gentoo.mirror.web4u.cz/ http://distfiles.gentoo.org http://www.ibiblio.org/pub/Linux/distributions/gentoo"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j4"
PKGDIR="/var/portage/packages"
PORTAGE_COMPRESS="xz"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/var/lib/layman/sunrise /usr/local/portage"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="a52 aac acl acpi aim alsa amd64 bash-completion bcmath berkdb bidi blas bzip2 cairo caps cddb cdinstall cdparanoia cdr cli cracklib cscope ctype curl curlwrappers cxx dbm dbus dri dv dvd dvdr dvdread encode exif expat ffmpeg fftw firefox flac flatfile fltk foomaticdb fortran freewnn ftp gd gdbm gif ginac glut gmp gpm gtk gtkhtml guile howl iconv icq ieee1394 imagemagick inifile jabber javascript jbig jikes jpeg jpeg2k lapack lcms lesstif libcaca libedit libnotify libwww lzma mad maildir memlimit mhash mime mmap mmx mng modules mp3 mpeg mplayer mudflap multilib musepack musicbrainz ncurses nls nocd nptl nsplugin offensive ogg old-linux openal opengl openmp openxer pam pcmcia pcntl pcre pdf perl plotutils png posix ppds python rdesktop readline recode scanner session sharedext sharedmem shorten simplexml slang slp sockets source speex spell sse sse2 startup-notification sysvipc szip tcpd threads tidy tiff tokenizer truetype unicode usb vcd verbose vhosts videos vim-syntax vorbis wifi wmf x264 xcomposite xface xine xinerama xml xmlrpc xpm xscreensaver xsl xv xvid zlib" ABI_X86="64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="alias authz_host authz_owner authz_user autoindex dir env ext_filter filter info log_config logio mime mime_magic negotiation rewrite setenvif status unique_id userdir vhost_alias auth_digest" APACHE2_MPMS="worker" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="adc65 agfa_cl20 aox barbie canon casio_qv clicksmart310 digigr8 digita dimagev dimera3500 directory enigma13 fuji gsmart300 hp215 iclick jamcam jd11 jl2005a kodak_dc120 kodak_dc210 kodak_dc240 kodak_dc3200 kodak_ez200 konica konica_qm150 largan lg_gsm mars mustek panasonic_coolshot panasonic_dc1000 panasonic_dc1580 panasonic_l 859 pccam300 pccam600 polaroid_pdc320 polaroid_pdc640 polaroid_pdc700 ptp2 ricoh ricoh_g3 samsung sierra sipix_blink sipix_blink2 sipix_web2 smal sonix sony_dscf1 sony_dscf55 soundvision spca50x sq905 stv0674 stv0680 sx330z template topfield toshiba_pdrm11" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="evdev keyboard mouse synaptics" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="nlpsolver pdfimport scripting-beanshell scripting-javascript wiki-publisher presenter-console presenter-minimizer" LINGUAS="en sk" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_2" QEMU_SOFTMMU_TARGETS="i386 x86_64 sparc sparc64" QEMU_USER_TARGETS="i386 x86_64 sparc sparc32plus sparc64" RUBY_TARGETS="ruby19 ruby20" USERLAND="GNU" VIDEO_CARDS="intel i965" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON
Comment 6 Pavol Dilung 2013-10-06 11:44:18 UTC
(In reply to Pavol Dilung from comment #5)
> ortage 2.2.1 (default/linux/amd64/13.0, gcc-4.7.3, glibc-2.15-r3,
> 3.10.7-gentoo-r1 x86_64)
> =================================================================
> System uname:
> Linux-3.10.7-gentoo-r1-x86_64-Intel-R-_Core-TM-_i7-2620M_CPU_@_2.70GHz-with-
> gentoo-2.2
> KiB Mem:     3924628 total,    494308 free
> KiB Swap:    1949812 total,   1858728 free
> Timestamp of tree: Sun, 06 Oct 2013 10:15:01 +0000
> ld GNU ld (GNU Binutils) 2.23.1
> app-shells/bash:          4.2_p45
> dev-java/java-config:     2.1.12-r1
> dev-lang/python:          2.7.5-r2, 3.2.5-r2
> dev-util/cmake:           2.8.10.2-r2
> dev-util/pkgconfig:       0.28
> sys-apps/baselayout:      2.2
> sys-apps/openrc:          0.11.8
> sys-apps/sandbox:         2.6-r1
> sys-devel/autoconf:       2.13, 2.69
> sys-devel/automake:       1.9.6-r3, 1.11.6, 1.12.6, 1.13.4
> sys-devel/binutils:       2.23.1
> sys-devel/gcc:            4.6.3, 4.7.3-r1
> sys-devel/gcc-config:     1.7.3
> sys-devel/libtool:        2.4.2
> sys-devel/make:           3.82-r4
> sys-kernel/linux-headers: 3.9 (virtual/os-headers)
> sys-libs/glibc:           2.15-r3
> Repositories: gentoo sunrise x-portage
> ACCEPT_KEYWORDS="amd64"
> ACCEPT_LICENSE="*"
> CBUILD="x86_64-pc-linux-gnu"
> CFLAGS="-march=native -fomit-frame-pointer -O2 -pipe"
> CHOST="x86_64-pc-linux-gnu"
> CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt /var/lib/hsqldb"
> CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d
> /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild
> /etc/sandbox.d /etc/splash /etc/terminfo /etc/texmf/language.dat.d
> /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
> CXXFLAGS="-march=native -fomit-frame-pointer -O2 -pipe"
> DISTDIR="/var/portage/distfiles"
> FCFLAGS="-march=native -fomit-frame-pointer -O2 -pipe"
> FEATURES="assume-digests binpkg-logs cgroup clean-logs collision-protect
> config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync
> metadata-transfer news parallel-fetch preserve-libs protect-owned sandbox
> sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch
> userpriv usersandbox usersync"
> FFLAGS="-march=native -fomit-frame-pointer -O2 -pipe"
> GENTOO_MIRRORS="ftp://mirror.switch.ch/mirror/gentoo/
> http://mirror.gentoo.sk/pub ftp://gentoo.mirror.web4u.cz/
> http://distfiles.gentoo.org
> http://www.ibiblio.org/pub/Linux/distributions/gentoo"
> LDFLAGS="-Wl,-O1 -Wl,--as-needed"
> MAKEOPTS="-j4"
> PKGDIR="/var/portage/packages"
> PORTAGE_COMPRESS="xz"
> PORTAGE_CONFIGROOT="/"
> PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times
> --omit-dir-times --compress --force --whole-file --delete --stats
> --human-readable --timeout=180 --exclude=/distfiles --exclude=/local
> --exclude=/packages"
> PORTAGE_TMPDIR="/var/tmp"
> PORTDIR="/usr/portage"
> PORTDIR_OVERLAY="/var/lib/layman/sunrise /usr/local/portage"
> SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
> USE="a52 aac acl acpi aim alsa amd64 bash-completion bcmath berkdb bidi blas
> bzip2 cairo caps cddb cdinstall cdparanoia cdr cli cracklib cscope ctype
> curl curlwrappers cxx dbm dbus dri dv dvd dvdr dvdread encode exif expat
> ffmpeg fftw firefox flac flatfile fltk foomaticdb fortran freewnn ftp gd
> gdbm gif ginac glut gmp gpm gtk gtkhtml guile howl iconv icq ieee1394
> imagemagick inifile jabber javascript jbig jikes jpeg jpeg2k lapack lcms
> lesstif libcaca libedit libnotify libwww lzma mad maildir memlimit mhash
> mime mmap mmx mng modules mp3 mpeg mplayer mudflap multilib musepack
> musicbrainz ncurses nls nocd nptl nsplugin offensive ogg old-linux openal
> opengl openmp openxer pam pcmcia pcntl pcre pdf perl plotutils png posix
> ppds python rdesktop readline recode scanner session sharedext sharedmem
> shorten simplexml slang slp sockets source speex spell sse sse2
> startup-notification sysvipc szip tcpd threads tidy tiff tokenizer truetype
> unicode usb vcd verbose vhosts videos vim-syntax vorbis wifi wmf x264
> xcomposite xface xine xinerama xml xmlrpc xpm xscreensaver xsl xv xvid zlib"
> ABI_X86="64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106
> cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0
> intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci"
> APACHE2_MODULES="alias authz_host authz_owner authz_user autoindex dir env
> ext_filter filter info log_config logio mime mime_magic negotiation rewrite
> setenvif status unique_id userdir vhost_alias auth_digest"
> APACHE2_MPMS="worker" CALLIGRA_FEATURES="kexi words flow plan sheets stage
> tables krita karbon braindump author" CAMERAS="adc65 agfa_cl20 aox barbie
> canon casio_qv clicksmart310 digigr8 digita dimagev dimera3500 directory
> enigma13 fuji gsmart300 hp215 iclick jamcam jd11 jl2005a kodak_dc120
> kodak_dc210 kodak_dc240 kodak_dc3200 kodak_ez200 konica konica_qm150 largan
> lg_gsm mars mustek panasonic_coolshot panasonic_dc1000 panasonic_dc1580
> panasonic_l 859 pccam300 pccam600 polaroid_pdc320 polaroid_pdc640
> polaroid_pdc700 ptp2 ricoh ricoh_g3 samsung sierra sipix_blink sipix_blink2
> sipix_web2 smal sonix sony_dscf1 sony_dscf55 soundvision spca50x sq905
> stv0674 stv0680 sx330z template topfield toshiba_pdrm11"
> COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog"
> ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin
> garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle
> oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx"
> INPUT_DEVICES="evdev keyboard mouse synaptics" KERNEL="linux"
> LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb
> ncurses text" LIBREOFFICE_EXTENSIONS="nlpsolver pdfimport
> scripting-beanshell scripting-javascript wiki-publisher presenter-console
> presenter-minimizer" LINGUAS="en sk" OFFICE_IMPLEMENTATION="libreoffice"
> PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7"
> PYTHON_TARGETS="python2_7 python3_2" QEMU_SOFTMMU_TARGETS="i386 x86_64 sparc
> sparc64" QEMU_USER_TARGETS="i386 x86_64 sparc sparc32plus sparc64"
> RUBY_TARGETS="ruby19 ruby20" USERLAND="GNU" VIDEO_CARDS="intel i965"
> XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p
> iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark
> dhcpmac delude chaos account"
> Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL,
> PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS,
> USE_PYTHON

I can confirm that:
- app-emulation/vmware-modules-271.2 (latest in Portage)
fails to compile without 271-userns.patch regardless of whether CONFIG_USER_NS setting is enabled or not in sys-kernel/gentoo-sources-3.10.0 (attached is my kernel configuration for further details).

I have to compile vmware-modules with and without setting CONFIG_USER_NS while CONFIG_NAMESPACES has been always set.

Attached is also an ebuilld that applies this patch.

BR

Pali
Comment 7 Pavol Dilung 2013-10-06 11:45:51 UTC
Created attachment 360218 [details]
Kernel configuration for sys-kernel/gentoo-sources-3.10.7
Comment 8 Pavol Dilung 2013-10-06 11:48:38 UTC
Created attachment 360220 [details]
app-emulation/vmware-modules-271.2-r1 ebuild that applies 271-userns.patch for gentoo-sources 3.8.0 and above
Comment 9 MaratIK 2013-10-23 17:39:05 UTC
patch and ebuild works fine for me
Comment 10 Tianon 2013-11-09 10:42:25 UTC
I think it's worth noting that vmware-modules-279.1.ebuild invokes epatch_user, so /etc/portage/patches is sufficient for applying this patch (which I have verified locally).
Comment 11 Sergey Morozov 2014-01-10 12:48:13 UTC
I have successfully compiled a vmware-modules with this patch (with NFIG_USER_NS=y and gentoo-sources-3.10.25). Please add it to the portage tree.
Comment 12 Sergey Morozov 2014-01-14 10:34:13 UTC
Vmblock driver is not working properly. Filesystem in the guest constantly crashing.
Comment 13 Jeroen Roovers (RETIRED) gentoo-dev 2014-04-26 16:14:05 UTC
*** Bug 508734 has been marked as a duplicate of this bug. ***
Comment 14 Jeroen Roovers (RETIRED) gentoo-dev 2014-04-26 16:14:29 UTC
*** Bug 506584 has been marked as a duplicate of this bug. ***
Comment 15 Jeroen Roovers (RETIRED) gentoo-dev 2014-04-26 16:14:38 UTC
*** Bug 498520 has been marked as a duplicate of this bug. ***
Comment 16 Harris Landgarten 2014-04-26 16:48:59 UTC
Created attachment 375780 [details, diff]
Patch to inode.c

This patch allows vmblock to build. It still will not modprobe because of getname errors.
Comment 17 Harris Landgarten 2014-04-26 17:14:49 UTC
Created attachment 375786 [details, diff]
patch to get vmblock to modprobe

patch to control.c so vmblock modprobes
Comment 18 Zhu Sha Zang 2014-04-29 02:45:25 UTC
Hey Harris, forgive me for this question, but how apply this patches? Can you teach us?

Regards
Comment 19 Harris Landgarten 2014-04-29 03:05:08 UTC
Created attachment 375996 [details, diff]
vmware-3.11.patch
Comment 20 Harris Landgarten 2014-04-29 03:05:38 UTC
Created attachment 375998 [details, diff]
279-312.patch
Comment 21 Harris Landgarten 2014-04-29 03:09:50 UTC
create /etc/portage/patches/app-emulation/vmware-modules/

in that directory put the following 4 patches:

vmware-3.11.patch
279-312.patch
inode_patch.patch
279-getname.patch

I uploaded all 4 patches to this bug.

Then just emerge vmware-modules and you should be good.
Comment 22 Zhu Sha Zang 2014-04-29 04:00:49 UTC
Hi, this 4 patches should work using vmware-modules-279.2 against kernel 3.13.11?

Because, now I see a new error:

Regards
Comment 23 Zhu Sha Zang 2014-04-29 04:03:22 UTC
Sorry, I was unable to attach.

>> Emerging (1 of 1) app-emulation/vmware-modules-279.2::gentoo
 * Determining the location of the kernel source code
 * Found kernel source directory:
 *     /usr/src/linux
 * Found sources for kernel version:
 *     3.13.11-gentoo-blackhammer
 * Checking for suitable kernel configuration options...                                                                                                                                                                                                                        [ ok ]
 * Checking for suitable kernel configuration options...                                                                                                                                                                                                                        [ ok ]
>>> Unpacking source...
>>> Source unpacked in /var/tmp/portage/app-emulation/vmware-modules-279.2/work
>>> Preparing source in /var/tmp/portage/app-emulation/vmware-modules-279.2/work ...
 * Applying 279-makefile-kernel-dir.patch ...                                                                                                                                                                                                                                   [ ok ]
 * Applying 279-makefile-include.patch ...                                                                                                                                                                                                                                      [ ok ]
 * Applying 279-netdevice.patch ...                                                                                                                                                                                                                                             [ ok ]
 * Applying 279-apic.patch ...                                                                                                                                                                                                                                                  [ ok ]
 * Applying 279-putname.patch ...                                                                                                                                                                                                                                               [ ok ]
 * Applying 279-vmblock.patch ...                                                                                                                                                                                                                                               [ ok ]
 * Applying user patches from /etc/portage/patches//app-emulation/vmware-modules ...
 *   279-312.patch ...                                                                                                                                                                                                                                                          [ ok ]
 *   279-getname.patch ...                                                                                                                                                                                                                                                      [ ok ]
 *   inode_patch.patch ...                                                                                                                                                                                                                                                      [ ok ]
 *   vmware-3.11.patch ...                                                                                                                                                                                                                                                      [ ok ]
 * Done with patching
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/app-emulation/vmware-modules-279.2/work ...
>>> Source configured.
>>> Compiling source in /var/tmp/portage/app-emulation/vmware-modules-279.2/work ...
 * Preparing vmblock module
make -j1 HOSTCC=x86_64-pc-linux-gnu-gcc CROSS_COMPILE=x86_64-pc-linux-gnu- 'LDFLAGS=-m elf_x86_64' auto-build KERNEL_DIR=/usr/src/linux KBUILD_OUTPUT=/usr/src/linux 
Using 2.6.x kernel build system.
make -C /usr/src/linux SUBDIRS=$PWD SRCROOT=$PWD/. \
  MODULEBUILDDIR= modules
make[1]: Entering directory '/usr/src/linux-3.13.11-gentoo'
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/linux/filesystem.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/linux/dentry.o
/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/linux/dentry.c:38:4: warning: initialization from incompatible pointer type [enabled by default]
    .d_revalidate = DentryOpRevalidate,
    ^
/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/linux/dentry.c:38:4: warning: (near initialization for ‘LinkDentryOps.d_revalidate’) [enabled by default]
/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/linux/dentry.c: In function ‘DentryOpRevalidate’:
/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/linux/dentry.c:104:7: warning: passing argument 2 of ‘actualDentry->d_op->d_revalidate’ makes integer from pointer without a cast [enabled by default]
       return actualDentry->d_op->d_revalidate(actualDentry, nd);
       ^
/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/linux/dentry.c:104:7: note: expected ‘unsigned int’ but argument is of type ‘struct nameidata *’
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/linux/stubs.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/linux/file.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/linux/block.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/linux/inode.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/linux/super.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/linux/module.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/linux/control.o
  LD [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/vmblock.o
  Building modules, stage 2.
  MODPOST 1 modules
  CC      /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/vmblock.mod.o
  LD [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only/vmblock.ko
make[1]: Leaving directory '/usr/src/linux-3.13.11-gentoo'
make -C $PWD SRCROOT=$PWD/. \
  MODULEBUILDDIR= postbuild
make[1]: Entering directory '/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only'
make[1]: 'postbuild' is up to date.
make[1]: Leaving directory '/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmblock-only'
cp -f vmblock.ko ./../vmblock.o
 * Preparing vmmon module
make -j1 HOSTCC=x86_64-pc-linux-gnu-gcc CROSS_COMPILE=x86_64-pc-linux-gnu- 'LDFLAGS=-m elf_x86_64' auto-build KERNEL_DIR=/usr/src/linux KBUILD_OUTPUT=/usr/src/linux 
Using 2.6.x kernel build system.
make -C /usr/src/linux SUBDIRS=$PWD SRCROOT=$PWD/. \
  MODULEBUILDDIR= modules
make[1]: Entering directory '/usr/src/linux-3.13.11-gentoo'
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only/linux/driverLog.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only/linux/driver.o
/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only/linux/driver.c:1342:1: warning: always_inline function might not be inlinable [-Wattributes]
 LinuxDriverSyncReadTSCs(uint64 *delta) // OUT: TSC max - TSC min
 ^
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only/linux/hostif.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only/common/apic.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only/common/memtrack.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only/common/vmx86.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only/common/cpuid.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only/common/task.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only/common/hashFunc.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only/common/comport.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only/common/phystrack.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only/vmcore/moduleloop.o
  LD [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only/vmmon.o
  Building modules, stage 2.
  MODPOST 1 modules
  CC      /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only/vmmon.mod.o
  LD [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only/vmmon.ko
make[1]: Leaving directory '/usr/src/linux-3.13.11-gentoo'
make -C $PWD SRCROOT=$PWD/. \
  MODULEBUILDDIR= postbuild
make[1]: Entering directory '/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only'
make[1]: 'postbuild' is up to date.
make[1]: Leaving directory '/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmmon-only'
cp -f vmmon.ko ./../vmmon.o
 * Preparing vmnet module
make -j1 HOSTCC=x86_64-pc-linux-gnu-gcc CROSS_COMPILE=x86_64-pc-linux-gnu- 'LDFLAGS=-m elf_x86_64' auto-build KERNEL_DIR=/usr/src/linux KBUILD_OUTPUT=/usr/src/linux 
Using 2.6.x kernel build system.
make -C /usr/src/linux SUBDIRS=$PWD SRCROOT=$PWD/. \
  MODULEBUILDDIR= modules
make[1]: Entering directory '/usr/src/linux-3.13.11-gentoo'
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmnet-only/driver.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmnet-only/hub.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmnet-only/userif.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmnet-only/netif.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmnet-only/bridge.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmnet-only/filter.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmnet-only/procfs.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmnet-only/smac_compat.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmnet-only/smac.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmnet-only/vnetEvent.o
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmnet-only/vnetUserListener.o
  LD [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmnet-only/vmnet.o
  Building modules, stage 2.
  MODPOST 1 modules
  CC      /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmnet-only/vmnet.mod.o
  LD [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmnet-only/vmnet.ko
make[1]: Leaving directory '/usr/src/linux-3.13.11-gentoo'
make -C $PWD SRCROOT=$PWD/. \
  MODULEBUILDDIR= postbuild
make[1]: Entering directory '/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmnet-only'
make[1]: 'postbuild' is up to date.
make[1]: Leaving directory '/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmnet-only'
cp -f vmnet.ko ./../vmnet.o
 * Preparing vmci module
make -j1 HOSTCC=x86_64-pc-linux-gnu-gcc CROSS_COMPILE=x86_64-pc-linux-gnu- 'LDFLAGS=-m elf_x86_64' auto-build KERNEL_DIR=/usr/src/linux KBUILD_OUTPUT=/usr/src/linux 
Using 2.6.x kernel build system.
make -C /usr/src/linux SUBDIRS=$PWD SRCROOT=$PWD/. \
  MODULEBUILDDIR= modules
make[1]: Entering directory '/usr/src/linux-3.13.11-gentoo'
  CC [M]  /var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmci-only/linux/driver.o
/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmci-only/linux/driver.c: In function ‘LinuxDriver_Ioctl’:
/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmci-only/linux/driver.c:740:12: error: incompatible types when assigning to type ‘VMCIHostUser’ from type ‘kuid_t’
       user = current_uid();
            ^
/usr/src/linux-3.13.11-gentoo/scripts/Makefile.build:308: recipe for target '/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmci-only/linux/driver.o' failed
make[3]: *** [/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmci-only/linux/driver.o] Error 1
/usr/src/linux-3.13.11-gentoo/Makefile:1249: recipe for target '_module_/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmci-only' failed
make[2]: *** [_module_/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmci-only] Error 2
Makefile:133: recipe for target 'sub-make' failed
make[1]: *** [sub-make] Error 2
make[1]: Leaving directory '/usr/src/linux-3.13.11-gentoo'
Makefile:130: recipe for target 'vmci.ko' failed
make: *** [vmci.ko] Error 2
 * ERROR: app-emulation/vmware-modules-279.2::gentoo failed (compile phase):
 *   emake failed
 * 
 * If you need support, post the output of `emerge --info '=app-emulation/vmware-modules-279.2::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=app-emulation/vmware-modules-279.2::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/app-emulation/vmware-modules-279.2/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/app-emulation/vmware-modules-279.2/temp/environment'.
 * Working directory: '/var/tmp/portage/app-emulation/vmware-modules-279.2/work/vmci-only'
 * S: '/var/tmp/portage/app-emulation/vmware-modules-279.2/work'

>>> Failed to emerge app-emulation/vmware-modules-279.2, Log file:

>>>  '/var/tmp/portage/app-emulation/vmware-modules-279.2/temp/build.log'
 * 
 * The following package has failed to build or install:
 * 
 *  (app-emulation/vmware-modules-279.2:0/0::gentoo, ebuild scheduled for merge), Log file:
 *   '/var/tmp/portage/app-emulation/vmware-modules-279.2/temp/build.log'
 *
Comment 24 Harris Landgarten 2014-04-29 11:43:07 UTC
I am using gentoo-sources-3.14.2 and using vmci and vsock from the kernel with 

-vmci and -vsock use flags

If you are going to use vmci from ebuild must need another patch
Comment 25 Zhu Sha Zang 2014-04-29 15:05:27 UTC
Using vmsi and vmsock from kernel worked.

Thank you.
Comment 26 Michael Rowell 2014-07-22 19:59:44 UTC
Same issue, with USE="-vmci -vsock", kernel 3.15.6 and vmware-modules-279.2, patches 279-312.patch and vmware-3.11.patch would not apply cleanly, but with only the inode patch and vmblock-modprobe patch I ran into #507664.

Removing patches from here and using 4 patches from #507664 as described there resulted in clean build and install.
Comment 27 Jeroen Roovers (RETIRED) gentoo-dev 2014-07-29 10:40:49 UTC
*** Bug 518400 has been marked as a duplicate of this bug. ***
Comment 28 Alex Dubenetsky 2014-08-06 17:43:30 UTC
Created attachment 382404 [details]
more patches for 3.15.x

A new set of patches to build modules against kernel 3.15.x
Also a new ebuild provided.
* tested with vanilla-sources-3.15.5, USE="vsosk vmci", "CONFIG_VMWARE_VMCI is not set" @ x86_64-pc-linux-gnu
Comment 29 Anton Bolshakov 2014-08-07 03:16:54 UTC
(In reply to Alex Dubenetsky from comment #28)
> Created attachment 382404 [details]
> more patches for 3.15.x

Thank you. Tested and and works
Comment 30 Harris Landgarten 2014-08-07 03:32:51 UTC
please add quotes around the mode=660 udev rules as in

mode="660"

Otherwise errors are generated on boot at least by systemd.

Aug 06 22:57:15 harrisl-desktop systemd-udevd[226]: invalid key/value pair in file /lib64/udev/rules.d/60-vmware.rules on line 1,starting at character 32 (' ')
Aug 06 22:57:15 harrisl-desktop systemd-udevd[226]: invalid key/value pair in file /lib64/udev/rules.d/60-vmware.rules on line 2,starting at character 36 (' ')
Aug 06 22:57:15 harrisl-desktop systemd-udevd[226]: invalid key/value pair in file /lib64/udev/rules.d/60-vmware.rules on line 3,starting at character 32 (' ')
Aug 06 22:57:15 harrisl-desktop systemd-udevd[226]: invalid key/value pair in file /lib64/udev/rules.d/60-vmware.rules on line 4,starting at character 32 (' ')
Comment 31 Jeroen Roovers (RETIRED) gentoo-dev 2014-09-02 18:12:24 UTC
*** Bug 521408 has been marked as a duplicate of this bug. ***
Comment 32 Jeroen Roovers (RETIRED) gentoo-dev 2014-09-02 18:13:32 UTC
*** Bug 521872 has been marked as a duplicate of this bug. ***
Comment 33 risq 2014-09-06 19:52:31 UTC
(In reply to Alex Dubenetsky from comment #28)
> Created attachment 382404 [details]
> more patches for 3.15.x
> 
> A new set of patches to build modules against kernel 3.15.x
> Also a new ebuild provided.
> * tested with vanilla-sources-3.15.5, USE="vsosk vmci", "CONFIG_VMWARE_VMCI
> is not set" @ x86_64-pc-linux-gnu

i used those patches against 3.16.0-gentoo kernel. they still work, thx a lot
Comment 34 T-Dawg 2014-09-14 11:39:42 UTC
Created attachment 384722 [details]
Patches to compile on 3.14.0

These patches allow a clean and working build on kernel 3.14.0. Later versions are unconfirmed.
Comment 35 Nathan 2014-10-01 19:32:45 UTC
I am on 3.14.14, I tried the patches from Harris Landgarten but got some errors compiling vmware-modules.

I wiped the patches from the /etc/portage/patches/app-emulation/vmware-modules and only used the patches supplied in the zipfile in T-Dawgs post "Patches to compile on 3.14.0" 

This allowed vmware-modules to patch fully with the 2 files in that zip file.

I do not use kernel enabled features.
Comment 36 Jeroen Roovers (RETIRED) gentoo-dev 2014-10-13 06:21:16 UTC
*** Bug 525158 has been marked as a duplicate of this bug. ***
Comment 37 Evan Teran 2014-10-14 21:20:46 UTC
Please try the official vmware overlay. I've checked in updated ebuilds and patches which should apply and build cleanly for 3.10 - 3.17 kernels. And am working with the ebuild maintainer to get them into the mainline once they have been tested enough.

(Also, remember to remove any user patches you have in /etc/portage/patches since the ebuild is intended to compile cleanly as is).
Comment 38 Michele Testa 2014-10-20 09:08:17 UTC
(In reply to Nathan from comment #35)
> I am on 3.14.14, I tried the patches from Harris Landgarten but got some
> errors compiling vmware-modules.
> 
> I wiped the patches from the
> /etc/portage/patches/app-emulation/vmware-modules and only used the patches
> supplied in the zipfile in T-Dawgs post "Patches to compile on 3.14.0" 
> 
> This allowed vmware-modules to patch fully with the 2 files in that zip file.
> 
> I do not use kernel enabled features.

Thanks Nathan & Harris Landgarten,

I have successfully compiled with your hint. These are the steps:

1) create the directory:
  /etc/portage/patches/app-emulation/vmware-modules-279.3

2) download in it the patches supplied in the zipfile kernel_3.14.0_patches.tar.gz (in T-Dawgs post "Patches to compile on 3.14.0")

3) unzip the tar and move the files:
  fix_kuid_t.patch
  fix_unknown_symbol_getname.patch
into the directory created at step 1.

4) emerge -uav app-emulation/vmware-modules and enjoy your compiling.
Comment 39 Andrea (Ben) Benini 2014-10-20 21:55:16 UTC
Kernel 3.14.14.
# uname -a
Linux 3.14.14-gentoo #8 SMP Sun Oct 19 00:20:48 CEST 2014 x86_64 Intel(R) Core(TM)2 Duo CPU E4500 @ 2.20GHz GenuineIntel GNU/Linux

I have solved with two patches and a new ebuild, here's credit and source:
http://k53sv.blogspot.it/2014/04/app-emulationvmware-modules-2792gentoo.html

Files needs to be converted from pastebin weird CR+LF with dos2unix utility, after that  I can emerge vmware-modules without troubles.
Comment 40 Harris Landgarten 2014-10-20 23:20:14 UTC
for those interested the newest vmware-modules for the vmware overlay with workstation-10.3 and kernel-3.17 compile, install and work without any patches.

I use vmci and vsock from the kernel btw.

The only problems are with the udev rules created. mode=660 needs to be mode="660" or systemd reports the rules invalid.
Comment 41 Alex Dubenetsky 2014-11-02 17:47:16 UTC
(In reply to Harris Landgarten from comment #40)
> for those interested the newest vmware-modules for the vmware overlay with
> workstation-10.3 and kernel-3.17 compile, install and work without any
> patches.
> 
> I use vmci and vsock from the kernel btw.

Thank you, Harris.

I found some issues related to 279.3-r1.

1. It's fragile to customized CFLAGS/CXXFLAGS. (At least for x86/amd64 arches.) Flags are known that it won't compile, any of: "-msse -msse2 -msse3 -mssse3 -msse4.1 -msse4.2 -mf16c -mpclmul". Flags are known that it will compile, all of: "-O2 -pipe -g0 -mmmx -msse2avx -mrdrnd -mfsgsbase -mfpmath=sse". Tested with "-march=corei7". In case of bad flags are used, the error is "/var/tmp/portage/app-emulation/vmware-modules-279.3-r1/work/vmmon-only/linux/driver.c:1252:4: error: too many arguments to function ‘smp_call_function’".
There is a kind of a patch to fix it here: https://github.com/zlbruce/overlay/blob/master/app-emulation/vmware-modules/files/279-smp_call_3arg.patch . It looks like a workaround, because the original code has vmmon-only/autoconf/smpcall.c [for checking the number of ‘smp_call_function’ arguments] which is called from vmmon-only/Makefile.kernel or Makefile.normal but for some reasons it is not working properly (at least for some C*FLAGS, as is mentioned above, what is also strange...) Anyway... could you add this patch?

> The only problems are with the udev rules created. mode=660 needs to be
> mode="660" or systemd reports the rules invalid.

2. I don't use systemd... In openrc, vmware's (player) start script believes that the name of VMCI module is only could be 'vmci', while for a kernel version it is 'vmw_vmci'. Could you add the next code to "src_install()":
use vmci || ( dodir "/etc/modprobe.d/" && echo "alias vmci vmw_vmci" > "${D}/etc/modprobe.d/vmci.conf" )
(Maybe needed some adjustment for systemd. Like "use vmci || use systemd || (...")

I use vanilla-sources-3.17*, vmware-player and openrc.
Comment 42 Konstantin Münning 2014-12-24 13:39:11 UTC
(In reply to Yvan Royon from comment #1)
> Created attachment 342888 [details, diff] [details, diff]
> vmblock, vmci and vsock patch for USER_NS
> 
> Basic patch to get vmware-modules to compile.
> 
> It works for me just like it worked without USER_NS.
> I did not try running vmware from inside a user namespace.

Interestingly this patch is not needed on x86_64 but on i686 it is necessary. gcc (4.8.3) does not like the int assignment to kgid_t on 32 bit. This has nothing to do with USER_NS so I would suggest to add the patch and apply it for i686 systems.
Comment 43 Garth 2015-01-25 06:30:18 UTC
(In reply to Alex Dubenetsky from comment #41)
> (In reply to Harris Landgarten from comment #40)
> > for those interested the newest vmware-modules for the vmware overlay with
> > workstation-10.3 and kernel-3.17 compile, install and work without any
> > patches.
> > 
> > I use vmci and vsock from the kernel btw.
> 
> Thank you, Harris.
> 
> I found some issues related to 279.3-r1.
> 
> 1. It's fragile to customized CFLAGS/CXXFLAGS. (At least for x86/amd64
> arches.) Flags are known that it won't compile, any of: "-msse -msse2 -msse3
> -mssse3 -msse4.1 -msse4.2 -mf16c -mpclmul". Flags are known that it will
> compile, all of: "-O2 -pipe -g0 -mmmx -msse2avx -mrdrnd -mfsgsbase
> -mfpmath=sse". Tested with "-march=corei7". In case of bad flags are used,
> the error is
> "/var/tmp/portage/app-emulation/vmware-modules-279.3-r1/work/vmmon-only/
> linux/driver.c:1252:4: error: too many arguments to function
> ‘smp_call_function’".
> There is a kind of a patch to fix it here:
> https://github.com/zlbruce/overlay/blob/master/app-emulation/vmware-modules/
> files/279-smp_call_3arg.patch . It looks like a workaround, because the
> original code has vmmon-only/autoconf/smpcall.c [for checking the number of
> ‘smp_call_function’ arguments] which is called from
> vmmon-only/Makefile.kernel or Makefile.normal but for some reasons it is not
> working properly (at least for some C*FLAGS, as is mentioned above, what is
> also strange...) Anyway... could you add this patch?
> 
> > The only problems are with the udev rules created. mode=660 needs to be
> > mode="660" or systemd reports the rules invalid.
> 
> 2. I don't use systemd... In openrc, vmware's (player) start script believes
> that the name of VMCI module is only could be 'vmci', while for a kernel
> version it is 'vmw_vmci'. Could you add the next code to "src_install()":
> use vmci || ( dodir "/etc/modprobe.d/" && echo "alias vmci vmw_vmci" >
> "${D}/etc/modprobe.d/vmci.conf" )
> (Maybe needed some adjustment for systemd. Like "use vmci || use systemd ||
> (...")
> 
> I use vanilla-sources-3.17*, vmware-player and openrc.

I can confirm that at least the -msse4.1 CFLAGS causes the problem:
"/var/tmp/portage/app-emulation/vmware-modules-279.3-r1/work/vmmon-only/linux/driver.c:1252:4: error: too many arguments to function ‘smp_call_function’".

From what I found out, the flag -mpreferred-stack-boundary=3 gets defined somewhere (I'm not sure where), which causes:
/var/tmp/portage/app-emulation/vmware-modules-304.0/work/vmmon-only/./autoconf/smpcall.c:1:0: error: -mpreferred-stack-boundary=3 is not between 4 and 12
, which in turn prevents the makefile from adding -DVMW_HAVE_SMP_CALL_3ARG, which cause the previously mentionned failure with recent kernels.

Instead of the patch mentionned, a better workaround would be to have the ebuild filter the flags mentionned in comment 41.
Comment 44 Konstantin Münning 2015-04-04 19:09:41 UTC
I just stumbled upon this error and as it happened only on one of two machines with otherwise identical versions I investigated a bit. For kernels up to 3.12 (maybe 3.13 as well but I haven't checked) the problem is triggered by the kernel config option CONFIG_UIDGID_STRICT_TYPE_CHECKS which changes the definition of kgid_t from bare int to a struct. So the easiest fix would be to disable this option and vmblock will compile as expected.

For kernels 3.14 and up this option is not present anymore and kgid_t has a fixed struct definition. So to patch it for all these kernel versions the assignment should depend on the config option like this:

#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 14, 0)
inode->i_uid.val = inode->i_gid.val = 0;
#else
#ifdef CONFIG_UIDGID_STRICT_TYPE_CHECKS
inode->i_uid.val = inode->i_gid.val = 0;
#else
inode->i_uid = inode->i_gid = 0;
#endif
#endif

Better solutions are welcome.
Comment 45 Alex Dubenetsky 2015-05-10 21:54:36 UTC
Created attachment 403018 [details]
vmware-modules ebuild 279.3-r3 & patch for 3.19/4.0

The patch for kernel 3.19+/4.0+ + ebuild. Fixes namei & iter issues.
(Taken here: https://github.com/mrpdaemon/mrpdaemon-gentoo-config/tree/master/hosts/soothsayer/patches/app-emulation/vmware-modules-279.3)
Comment 46 Andrea (Ben) Benini 2015-07-05 22:28:05 UTC
@Alex: You Rock !
Your attach is fine for me. After 4-5 days of struggling with it I have compiled and installed vmware-modules, maybe it's not that clean but at least it works. Here are my steps:
- bunzipped your latest attach into /usr/local/portage/app-emulation (my local portage)
- recompiled my kernel with VMCI and VSOCKETS enabled. I have never done that before but with this hack this is necessary
- after the reboot I have installed vmware-modules with USE="-vmci -vsock" flag sets (USE="-vmci -vsock" emerge vmware-modules) because now these are provided by the kernel itself.
I personally don't like this solution that much but I'm fine with it, this is my primary working workstation so I really need to have vmware up and running

Kernel 4.x for me on AMD64 i7 machine.
~# uname -a
Linux ben 4.0.5-gentoo #8 SMP Mon Jul 6 00:11:51 CEST 2015 x86_64 Intel(R) Core(TM) i7-2600 CPU @ 3.40GHz GenuineIntel GNU/Linux

If someone of the devs want to have a look at my config or want to suggest something to try I can do some tests if you're interested. This bug is quite old and probably everyone with a desktop machine and vmware is locked without vmware-modules. Just drop me a note

Ben
Comment 47 Evan Teran 2015-07-11 04:45:29 UTC
The latest official vmware overlay has had the version bumped.

I have built the sources for vmware-modules-{271,279,304} on stock kernels 3.10 - 4.0, and associated vmware-workstation-{9,10,11} ebuilds.

Please give those a try and let me know if you have any issues.

Thanks
Comment 48 Harris Landgarten 2015-07-11 18:06:07 UTC
Using kernel-4.1.2 I replaced the versions in my personal overlay with the ones in vmware-overlay with no issues. I am still using kernel based vmci and vsock.
Comment 49 Nathan 2015-08-24 18:07:40 UTC
I have tried with vmci and vmsock but both fail on vmblock.                                                                          

Here is the bottom half of the build file showing the errors.
/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/linux/filesystem.c:325:21: warning: unused variable 'actualNd' [-Wunused-variable]
/usr/src/linux-4.0.5-gentoo/scripts/Makefile.build:258: recipe for target '/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/linux/file.o' failed
make[3]: *** [/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/linux/file.o] Error 1
/usr/src/linux-4.0.5-gentoo/scripts/Makefile.build:258: recipe for target '/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/linux/filesystem.o' failed
make[3]: *** [/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/linux/filesystem.o] Error 1
/usr/src/linux-4.0.5-gentoo/Makefile:1390: recipe for target '_module_/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only' failed
make[2]: *** [_module_/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only] Error 2
make[2]: Leaving directory '/usr/src/linux-4.0.5-gentoo'
Makefile:145: recipe for target 'sub-make' failed
make[1]: *** [sub-make] Error 2
make[1]: Leaving directory '/usr/src/linux-4.0.5-gentoo'
Makefile:130: recipe for target 'vmblock.ko' failed
make: *** [vmblock.ko] Error 2
 * ERROR: app-emulation/vmware-modules-279.3::gentoo failed (compile phase):
 *   emake failed
 * 
 * If you need support, post the output of `emerge --info '=app-emulation/vmware-modules-279.3::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=app-emulation/vmware-modules-279.3::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/app-emulation/vmware-modules-279.3/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/app-emulation/vmware-modules-279.3/temp/environment'.
 * Working directory: '/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only'
 * S: '/var/tmp/portage/app-emulation/vmware-modules-279.3/work'
 * !!! User patches were applied to this build!
Comment 50 Nathan 2015-08-24 18:10:29 UTC
I need to clear up my comment ...

I tried with and without kernel vmci and vsock.  looks like the patch is applying but for some reason in all the times I have had to fight this vmblock always has issues.
Comment 51 Nathan 2015-08-24 19:16:40 UTC
localhost files # emerge --info '=app-emulation/vmware-modules-279.3::gentoo'
Portage 2.2.20.1 (python 3.4.1-final-0, default/linux/amd64/13.0/desktop/kde, gcc-4.8.4, glibc-2.20-r2, 4.0.5-gentoo x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-4.0.5-gentoo-x86_64-Intel-R-_Core-TM-_i7_CPU_860_@_2.80GHz-with-gentoo-2.2
KiB Mem:     8234356 total,   6753716 free
KiB Swap:    8388604 total,   8388604 free
Timestamp of repository gentoo: Mon, 24 Aug 2015 15:30:01 +0000
sh bash 4.3_p39
ld GNU ld (Gentoo 2.24 p1.4) 2.24
app-shells/bash:          4.3_p39::gentoo
dev-java/java-config:     2.2.0::gentoo
dev-lang/perl:            5.20.2::gentoo
dev-lang/python:          2.7.9-r1::gentoo, 3.4.1::gentoo
dev-util/cmake:           3.2.2::gentoo
dev-util/pkgconfig:       0.28-r2::gentoo
sys-apps/baselayout:      2.2::gentoo
sys-apps/openrc:          0.17::gentoo
sys-apps/sandbox:         2.6-r1::gentoo
sys-devel/autoconf:       2.13::gentoo, 2.69::gentoo
sys-devel/automake:       1.11.6-r1::gentoo, 1.13.4::gentoo, 1.15::gentoo
sys-devel/binutils:       2.24-r3::gentoo
sys-devel/gcc:            4.8.4::gentoo
sys-devel/gcc-config:     1.7.3::gentoo
sys-devel/libtool:        2.4.6::gentoo
sys-devel/make:           4.1-r1::gentoo
sys-kernel/linux-headers: 3.18::gentoo (virtual/os-headers)
sys-libs/glibc:           2.20-r2::gentoo
Repositories:

gentoo
    location: /usr/portage
    sync-type: rsync
    sync-uri: rsync://rsync.gentoo.org/gentoo-portage
    priority: -1000

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=corei7 -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-march=corei7 -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j9"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
USE="64bit X a52 aac acl acpi alsa amd64 berkdb bindist bluetooth branding bzip2 cairo cdda cdr cli consolekit cracklib crypt cups cxx dbus declarative dri dts dvd dvdr emboss encode exif fam fat firefox flac fortran gdbm gif glamor gpm gtk iconv icu ipv6 jpeg kde kipi lcms ldap libnotify mad mmx mmxext mng modules mp3 mp4 mpeg multilib ncurses nepomuk nls nptl nsplugin nvidia ogg opengl openmp ovftool pam pango pcre pdf perl phonon plasma png policykit ppds qt3support qt4 readline sdl seccomp semantic-desktop session soprano spell sqlite sse sse2 ssl startup-notification static-libs svg tcpd tiff truetype udev udisks unicode upower usb vim-pager vim-syntax vix vmware-tools vorbis wxwidgets x264 xcb xcomposite xinerama xml xorg xscreensaver xv xvid zlib" ABI_X86="64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="mmx mmxext sse sse2" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_4" RUBY_TARGETS="ruby19 ruby20" USERLAND="GNU" VIDEO_CARDS="nvidia" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON

=================================================================
                        Package Settings
=================================================================

app-emulation/vmware-modules-279.3::gentoo was built with the following:
USE="vmci vsock -pax_kernel" ABI_X86="64"
Comment 52 Evan Teran 2015-08-24 19:35:33 UTC
@nathan,

are you using the official overlay? The version in portage is not (and has not been) in a working state for quite a while. But there has been a lot of activity in the overlay to ensure that it works for vmware 9,10,11 for kernels 3.19 - 4.0.

If you aren't, please use the overlay, it should work.

If you are using the overlay, please be sure to NOT use any extra patches. They should not be necessary at all. The overlay should "just work".

Let me know, and we'll go from there :-).
Comment 53 Nathan 2015-08-24 19:43:16 UTC
I have been using the patches from here.  Not sure how to 'use the overlay' you mention, but ill give it a try if I can have some instructions or a link to some.

I did find that certain patches are not applying...I think the dentry patch is not applying plus others.



----------------------------------------------------
>>> Unpacking source...
>>> Source unpacked in /var/tmp/portage/app-emulation/vmware-modules-279.3/work
>>> Preparing source in /var/tmp/portage/app-emulation/vmware-modules-279.3/work ...
 [32;01m*[0m Applying 279-makefile-kernel-dir.patch ...

 [32;01m*[0m Applying 279-makefile-include.patch ...

 [32;01m*[0m Applying 279-netdevice.patch ...

 [32;01m*[0m Applying 279-apic.patch ...

 [32;01m*[0m Applying 279-putname.patch ...

 [32;01m*[0m Applying 279-vmblock.patch ...

 [32;01m*[0m Applying 279-filldir.patch ...

 [32;01m*[0m Applying 279-vfsfollowlink.patch ...

 [32;01m*[0m Applying user patches from /etc/portage/patches//app-emulation/vmware-modules ...
 [32;01m*[0m Done with patching


----------------------------------------------------
patch list in ebuild.  
    epatch "${FILESDIR}/${PV_MAJOR}-makefile-kernel-dir.patch"
    epatch "${FILESDIR}/${PV_MAJOR}-makefile-include.patch"
    epatch "${FILESDIR}/${PV_MAJOR}-netdevice.patch"
    use pax_kernel && epatch "${FILESDIR}/279-hardened.patch"
    epatch "${FILESDIR}/${PV_MAJOR}-apic.patch"
    kernel_is ge 3 7 0 && epatch "${FILESDIR}/${PV_MAJOR}-putname.patch"
    kernel_is ge 3 10 0 && epatch "${FILESDIR}/${PV_MAJOR}-vmblock.patch"
    kernel_is ge 3 10 0 && epatch "${FILESDIR}/${PV_MAJOR}-3.10-00-userns.patch"
    kernel_is ge 3 10 0 && epatch "${FILESDIR}/${PV_MAJOR}-3.10-01-getname.patch"
    kernel_is ge 3 10 0 && epatch "${FILESDIR}/${PV_MAJOR}-3.10-03-deprecated.patch"
    kernel_is ge 3 10 0 && epatch "${FILESDIR}/${PV_MAJOR}-3.10-04-dentry.patch"
    kernel_is ge 3 10 0 && epatch "${FILESDIR}/${PV_MAJOR}-3.10-05-inode.patch"
    kernel_is ge 3 11 0 && epatch "${FILESDIR}/${PV_MAJOR}-filldir.patch"
    kernel_is ge 3 15 0 && epatch "${FILESDIR}/${PV_MAJOR}-3.15-00-readlink.patch"
    kernel_is ge 3 15 0 && epatch "${FILESDIR}/${PV_MAJOR}-3.15-01-vsock.patch"
    kernel_is ge 3 17 0 && epatch "${FILESDIR}/${PV_MAJOR}-3.17-00-netdev.patch"
    kernel_is ge 3 19 0 && epatch "${FILESDIR}/${PV_MAJOR}-3.19-namei-iter.patch"
Comment 54 Nathan 2015-08-24 19:44:49 UTC
I have been using Comment 38's process.
Comment 55 Evan Teran 2015-08-24 19:46:25 UTC
It's pretty simple if you use layman

    emerge layman
    emerge -a vmware

Remove all the 3rd party patches from the /etc/portage/patches/app-emulation/...

Then you just emerge as usual.
Comment 56 Evan Teran 2015-08-24 19:49:28 UTC
Bah, it's:

    layman -a vmware

NOT

    emerge -a vmware
Comment 57 Nathan 2015-08-24 20:06:31 UTC
emerge layman     - worked
layman -a vmware - failed
emerge -L        - worked
layman -a vmware - worked 

localhost patches # layman -a vmware  - a second time

 * Adding overlay,...
 * Repository 'vmware' was already installed

 * CLI: Errors occurred processing action add
 * Repository 'vmware' was already installed


emerge vmware-modules      -- still fails...cant paste all but here are some highlights..



 * IMPORTANT: 10 news items need reading for repository 'gentoo'.
 * Use eselect news read to view new items.

Calculating dependencies... done!

>>> Verifying ebuild manifests

>>> Emerging (1 of 1) app-emulation/vmware-modules-279.3::gentoo
 * Determining the location of the kernel source code
 * Found kernel source directory:
 *     /usr/src/linux
 * Found kernel object directory:
 *     /lib/modules/4.0.5-gentoo/build
 * Found sources for kernel version:
 *     4.0.5-gentoo
 * Checking for suitable kernel configuration options...                                                                                                                                                                                                                [ ok ]
 * Checking for suitable kernel configuration options...                                                                                                                                                                                                                [ ok ]
>>> Unpacking source...
>>> Source unpacked in /var/tmp/portage/app-emulation/vmware-modules-279.3/work
>>> Preparing source in /var/tmp/portage/app-emulation/vmware-modules-279.3/work ...
 * Applying 279-makefile-kernel-dir.patch ...                                                                                                                                                                                                                           [ ok ]
 * Applying 279-makefile-include.patch ...                                                                                                                                                                                                                              [ ok ]
 * Applying 279-netdevice.patch ...                                                                                                                                                                                                                                     [ ok ]
 * Applying 279-apic.patch ...                                                                                                                                                                                                                                          [ ok ]
 * Applying 279-putname.patch ...                                                                                                                                                                                                                                       [ ok ]
 * Applying 279-vmblock.patch ...                                                                                                                                                                                                                                       [ ok ]
 * Applying 279-filldir.patch ...                                                                                                                                                                                                                                       [ ok ]
 * Applying 279-vfsfollowlink.patch ...                                                                                                                                                                                                                                 [ ok ]
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/app-emulation/vmware-modules-279.3/work ...
>>> Source configured.
>>> Compiling source in /var/tmp/portage/app-emulation/vmware-modules-279.3/work ...
 * Preparing vmblock module
make -j9 HOSTCC=x86_64-pc-linux-gnu-gcc CROSS_COMPILE=x86_64-pc-linux-gnu- 'LDFLAGS=-m elf_x86_64' auto-build KERNEL_DIR=/usr/src/linux KBUILD_OUTPUT=/lib/modules/4.0.5-gentoo/build 
Using 2.6.x kernel build system.
make -C /lib/modules/4.0.5-gentoo/build SUBDIRS=$PWD SRCROOT=$PWD/. \
  MODULEBUILDDIR= modules


==== cut out here could not paste all ========

In file included from /usr/src/linux-4.0.5-gentoo/include/linux/kernel.h:13:0,
                 from /usr/src/linux-4.0.5-gentoo/include/linux/list.h:8,
                 from /usr/src/linux-4.0.5-gentoo/include/linux/module.h:9,
                 from /var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/linux/control.c:27:
/usr/src/linux-4.0.5-gentoo/include/linux/printk.h:103:0: note: this is the location of the previous definition
 #define DEPRECATED "[Deprecated]: "
 ^
In file included from /var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/linux/vmblockInt.h:41:0,
                 from /var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/linux/module.c:32:
/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/./shared/vm_assert.h:259:0: warning: "DEPRECATED" redefined [enabled by default]
    #define DEPRECATED(_fix) do {} while (0)
 ^
In file included from /usr/src/linux-4.0.5-gentoo/include/linux/kernel.h:13:0,
                 from /usr/src/linux-4.0.5-gentoo/include/linux/list.h:8,
                 from /usr/src/linux-4.0.5-gentoo/include/linux/module.h:9,
                 from /var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/linux/module.c:28:
/usr/src/linux-4.0.5-gentoo/include/linux/printk.h:103:0: note: this is the location of the previous definition
 #define DEPRECATED "[Deprecated]: "
 ^
/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/linux/file.c: In function 'FileOpOpen':
/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/linux/file.c:95:18: error: 'struct file' has no member named 'f_dentry'
    if (actualFile->f_dentry && inode == actualFile->f_dentry->d_inode) {
                  ^
/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/linux/file.c:95:51: error: 'struct file' has no member named 'f_dentry'
    if (actualFile->f_dentry && inode == actualFile->f_dentry->d_inode) {
                                                   ^
/usr/src/linux-4.0.5-gentoo/scripts/Makefile.build:258: recipe for target '/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/linux/file.o' failed
make[3]: *** [/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/linux/file.o] Error 1
/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/linux/control.c: In function 'ExecuteBlockOp':
/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only/linux/control.c:282:9: warning: assignment from incompatible pointer type [enabled by default]
    name = getname(buf);
         ^
/usr/src/linux-4.0.5-gentoo/Makefile:1390: recipe for target '_module_/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only' failed
make[2]: *** [_module_/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only] Error 2
make[2]: Leaving directory '/usr/src/linux-4.0.5-gentoo'
Makefile:145: recipe for target 'sub-make' failed
make[1]: *** [sub-make] Error 2
make[1]: Leaving directory '/usr/src/linux-4.0.5-gentoo'
Makefile:130: recipe for target 'vmblock.ko' failed
make: *** [vmblock.ko] Error 2
 * ERROR: app-emulation/vmware-modules-279.3::gentoo failed (compile phase):
 *   emake failed
 * 
 * If you need support, post the output of `emerge --info '=app-emulation/vmware-modules-279.3::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=app-emulation/vmware-modules-279.3::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/app-emulation/vmware-modules-279.3/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/app-emulation/vmware-modules-279.3/temp/environment'.
 * Working directory: '/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only'
 * S: '/var/tmp/portage/app-emulation/vmware-modules-279.3/work'

>>> Failed to emerge app-emulation/vmware-modules-279.3, Log file:

>>>  '/var/tmp/portage/app-emulation/vmware-modules-279.3/temp/build.log'

 * Messages for package app-emulation/vmware-modules-279.3:

 * ERROR: app-emulation/vmware-modules-279.3::gentoo failed (compile phase):
 *   emake failed
 * 
 * If you need support, post the output of `emerge --info '=app-emulation/vmware-modules-279.3::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=app-emulation/vmware-modules-279.3::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/app-emulation/vmware-modules-279.3/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/app-emulation/vmware-modules-279.3/temp/environment'.
 * Working directory: '/var/tmp/portage/app-emulation/vmware-modules-279.3/work/vmblock-only'
 * S: '/var/tmp/portage/app-emulation/vmware-modules-279.3/work'
Comment 58 Nathan 2015-08-24 20:08:34 UTC
still looks to be skipping several of those patches...I see no mention of patching the dentry patch, plus a few others
Comment 59 Nathan 2015-08-24 20:15:04 UTC
New emerge --info from the layman update.


localhost ~ # emerge --info '=app-emulation/vmware-modules-279.3::gentoo'
Portage 2.2.20.1 (python 3.4.1-final-0, default/linux/amd64/13.0/desktop/kde, gcc-4.8.4, glibc-2.20-r2, 4.0.5-gentoo x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-4.0.5-gentoo-x86_64-Intel-R-_Core-TM-_i7_CPU_860_@_2.80GHz-with-gentoo-2.2
KiB Mem:     8234356 total,   5767956 free
KiB Swap:    8388604 total,   8388604 free
Timestamp of repository gentoo: Mon, 24 Aug 2015 15:30:01 +0000
sh bash 4.3_p39
ld GNU ld (Gentoo 2.24 p1.4) 2.24
app-shells/bash:          4.3_p39::gentoo
dev-java/java-config:     2.2.0::gentoo
dev-lang/perl:            5.20.2::gentoo
dev-lang/python:          2.7.9-r1::gentoo, 3.4.1::gentoo
dev-util/cmake:           3.2.2::gentoo
dev-util/pkgconfig:       0.28-r2::gentoo
sys-apps/baselayout:      2.2::gentoo
sys-apps/openrc:          0.17::gentoo
sys-apps/sandbox:         2.6-r1::gentoo
sys-devel/autoconf:       2.13::gentoo, 2.69::gentoo
sys-devel/automake:       1.11.6-r1::gentoo, 1.13.4::gentoo, 1.15::gentoo                                                                                                                                                                                                      
sys-devel/binutils:       2.24-r3::gentoo                                                                                                                                                                                                                                      
sys-devel/gcc:            4.8.4::gentoo                                                                                                                                                                                                                                        
sys-devel/gcc-config:     1.7.3::gentoo                                                                                                                                                                                                                                        
sys-devel/libtool:        2.4.6::gentoo
sys-devel/make:           4.1-r1::gentoo
sys-kernel/linux-headers: 3.18::gentoo (virtual/os-headers)
sys-libs/glibc:           2.20-r2::gentoo
Repositories:

gentoo
    location: /usr/portage
    sync-type: rsync
    sync-uri: rsync://rsync.gentoo.org/gentoo-portage
    priority: -1000

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=corei7 -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-march=corei7 -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j9"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
USE="64bit X a52 aac acl acpi alsa amd64 berkdb bindist bluetooth branding bzip2 cairo cdda cdr cli consolekit cracklib crypt cups cxx dbus declarative dri dts dvd dvdr emboss encode exif fam fat firefox flac fortran gdbm gif glamor gpm gtk iconv icu ipv6 jpeg kde kipi lcms ldap libnotify mad mmx mmxext mng modules mp3 mp4 mpeg multilib ncurses nepomuk nls nptl nsplugin nvidia ogg opengl openmp ovftool pam pango pcre pdf perl phonon plasma png policykit ppds qt3support qt4 readline sdl seccomp semantic-desktop session soprano spell sqlite sse sse2 ssl startup-notification static-libs svg tcpd tiff truetype udev udisks unicode upower usb vim-pager vim-syntax vix vmware-tools vorbis wxwidgets x264 xcb xcomposite xinerama xml xorg xscreensaver xv xvid zlib" ABI_X86="64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="mmx mmxext sse sse2" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_4" RUBY_TARGETS="ruby19 ruby20" USERLAND="GNU" VIDEO_CARDS="nvidia" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON

=================================================================
                        Package Settings
=================================================================

app-emulation/vmware-modules-279.3::gentoo was built with the following:
USE="vmci vsock -pax_kernel" ABI_X86="64"
Comment 60 Evan Teran 2015-08-24 20:42:35 UTC
Looks like it's still using the in tree version, please make sure you have also unmasked the versions in the overlay. Sopmething like this will probably work:

/etc/portage/package.keywords

    =app-emulation/vmware-workstation-10* ~amd64
    =app-emulation/vmware-modules-279* ~amd64
Comment 61 Nathan 2015-08-24 21:58:50 UTC
keywords existed.

Had to add this to make.conf to get portage to use the overlay.
source /var/lib/layman/make.conf

Once I did that it wanted to pull in version 11 of workstation, so I did 
emerge =app-emulation/vmware-workstation-10.0.6.2700073

this pulled in vmware-modules-279.6 and it installed all the way through correctly.

Thanks.  using the layman overlay was much easier and looks like it will be maintained for next time. :)

so, here is all the steps I took

rm -rf /etc/portage/patch/app-emulation
emerge layman
layman -L
layman -a vmware
echo "source /var/lib/layman/make.conf"
emerge =app-emulation/vmware-workstation-10.0.6.2700073
Comment 62 Evan Teran 2015-08-25 00:32:15 UTC
If it was trying to pull in workstation 11, then you're keywords are probably a bit too generous. Either way, glad that you got it working.
Comment 63 Andrea (Ben) Benini 2015-08-25 07:35:57 UTC
I'm currently using a portage overlay ("vmware") for vmware-modules but I'm a little bit scared for my next emerge rsync because after reading some activity on these bugs I don't have a clear picture of what is happening with this package.
What are the specs for having vmware-modules working with the latest 4.x kernel ? Are VMCI and VSOCK required on the kernel for it ? What about the USE flag ? are "-vmci -vsock" required ?

Can someone please recap the current state ?

Thanks
Ben
Comment 64 Harris Landgarten 2015-08-25 15:24:20 UTC
the versions in the overlay work fine with 4.1 without any patches. There will need to be a patch for 4.2 when it is released and I will post one when I get it working. From what I have seen there are solutions to the 4.2 issues on the net.

As far as vsock and vmci I alway use the versions in the kernel. Why would you not. The kernel maintainers make sure they work.
Comment 65 Evan Teran 2015-08-25 16:16:32 UTC
@Andrea,

Kernels 3.19 - 4.0 are fully supported. 4.1 will work if you use the in kernel vmci/vsock and 'USE="-vmci -vsock"'

@Harris,

I agree that it's more ideal to use in kernel modules, since they keep they nice and up to date. But some people choose not to. So it is worth noting that the vmware provided vmci and vsock modules do not compile on kernels >= 4.1.

I do not predict many issues with patching to get 4.1,4.2 working correctly, it just has not been a prority since 4.0.x is the latest stable in the portage.