Bug 130583 - [patch] emulators/open-vm-tools does not compile on 8-CURRENT
Summary: [patch] emulators/open-vm-tools does not compile on 8-CURRENT
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Martin Blapp
Depends on:
Reported: 2009-01-15 12:30 UTC by Lawrence Stewart
Modified: 2009-03-03 23:30 UTC (History)
0 users

See Also:

file.diff (1.38 KB, patch)
2009-01-15 12:30 UTC, Lawrence Stewart
no flags Details | Diff
patch-insmntque (917 bytes, text/plain; charset=US-ASCII)
2009-01-28 01:59 UTC, takahiro.kurosawa
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Lawrence Stewart freebsd_committer 2009-01-15 12:30:04 UTC
The currently used suser(9) KPI was removed a while ago. The replacement is priv_check(9).

The "a_mode" member of struct vop_access_args has been renamed to "a_accmode".

Both of these issues stop the vmhgfs and vmblock FreeBSD kernel drivers from building as part of the port build on recent 8-CURRENT.

Fix: Attached patch renames struct vop_access_args member "a_mode" to "a_accmode", and updates suser(9) calls to priv_check(9). Privs checked for are a guess based on code comments and the contents of sys/sys/priv.h and should be reviewed to make sure I picked the correct ones to check for.

I've done no other validation than to check it compiles and the modules load correctly into the kernel. I don't use the functionality of either module as far as I'm aware so I can't vouch for the correctness of my changes.

It may also be possible to indirect through a compat layer to avoid the patch altogether... not sure as I haven't investigated this at all. Probably best to go with some sort of patch though to future proof the fix.

Patch attached with submission follows:
How-To-Repeat: cd /usr/ports/emulators/open-vm-tools && make

(note the problem is also present with emulators/open-vm-tools-nox11)
Comment 1 Edwin Groothuis freebsd_committer 2009-01-15 12:30:21 UTC
Responsible Changed
From-To: freebsd-ports-bugs->mbr

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 takahiro.kurosawa 2009-01-28 01:59:23 UTC
vmhgfs (and vmblock probably) also needs the attached patch on
FreeBSD >=7.0-RELEASE.
Without the patch, the kernel crashes when vmhgfs is accessed.
I've tested it for vmhgfs on VMWare Player 2.5, but not for vmblock.
Comment 3 dfilter service freebsd_committer 2009-03-03 23:26:25 UTC
mbr         2009-03-03 23:26:15 UTC

  FreeBSD ports repository

  Modified files:
    emulators/open-vm-tools Makefile distinfo pkg-plist 
    emulators/open-vm-tools/files patch-guestd-Makefile 
  Added files:
    emulators/open-vm-tools/files patch-freebsd-8 
  Removed files:
    emulators/open-vm-tools/files optpatch-nox11 
  Upgrade the port to build 148847 from 2009.02.18.
  PR:             ports/130583
  Submitted by:   lstewart
  Reviewed by:    KUROSAWA Takahiro <takahiro.kurosawa@gmail.com>
  Revision  Changes    Path
  1.20      +13 -12    ports/emulators/open-vm-tools/Makefile
  1.5       +3 -3      ports/emulators/open-vm-tools/distinfo
  1.2       +0 -11     ports/emulators/open-vm-tools/files/optpatch-nox11 (dead)
  1.1       +54 -0     ports/emulators/open-vm-tools/files/patch-freebsd-8 (new)
  1.2       +14 -14    ports/emulators/open-vm-tools/files/patch-guestd-Makefile
  1.2       +0 -58     ports/emulators/open-vm-tools/files/patch-hgfsmounter-Makefile (dead)
  1.2       +0 -63     ports/emulators/open-vm-tools/files/patch-modules-Makefile (dead)
  1.1       +24 -0     ports/emulators/open-vm-tools/files/patch-services-Makefile (new)
  1.1       +26 -0     ports/emulators/open-vm-tools/files/patch-suspend-vm-default (new)
  1.3       +0 -40     ports/emulators/open-vm-tools/files/patch-toolbox-Makefile (dead)
  1.1       +35 -0     ports/emulators/open-vm-tools/files/patch-vmblock-fuse-Makefile (new)
  1.1       +14 -0     ports/emulators/open-vm-tools/files/patch-vmblock-fuse-block.c (new)
  1.1       +16 -0     ports/emulators/open-vm-tools/files/patch-vmblock-subr.c (new)
  1.1       +15 -0     ports/emulators/open-vm-tools/files/patch-vmhgfs-state.c (new)
  1.2       +0 -32     ports/emulators/open-vm-tools/files/patch-wiperPosix.c (dead)
  1.16      +21 -0     ports/emulators/open-vm-tools/pkg-plist
cvs-all@freebsd.org mailing list
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 4 Martin Blapp freebsd_committer 2009-03-03 23:26:58 UTC
State Changed
From-To: open->closed

Committed, thanks !