aboutsummaryrefslogtreecommitdiff
path: root/emulators/vmware3
diff options
context:
space:
mode:
authorMike Silbersack <silby@FreeBSD.org>2004-06-24 07:52:27 +0000
committerMike Silbersack <silby@FreeBSD.org>2004-06-24 07:52:27 +0000
commite3dd2e01d6b71182e29997ad0fb0e58073b9887e (patch)
tree05db005f453c4bc3ed66319543b0660b432dd025 /emulators/vmware3
parentcf1f2dd6ae2bbd6b0ade2bd5288747cdcf08dbb3 (diff)
downloadports-e3dd2e01d6b71182e29997ad0fb0e58073b9887e.tar.gz
ports-e3dd2e01d6b71182e29997ad0fb0e58073b9887e.zip
Update to keep up with the recent dev_t change in -current. No need for
a port revision bump, functionality is unchanged.
Notes
Notes: svn path=/head/; revision=112106
Diffstat (limited to 'emulators/vmware3')
-rw-r--r--emulators/vmware3/files/freebsd4.patch17
-rw-r--r--emulators/vmware3/files/patch-ab58
2 files changed, 62 insertions, 13 deletions
diff --git a/emulators/vmware3/files/freebsd4.patch b/emulators/vmware3/files/freebsd4.patch
index 9d2a48d9bc1b..a927f1402383 100644
--- a/emulators/vmware3/files/freebsd4.patch
+++ b/emulators/vmware3/files/freebsd4.patch
@@ -55,15 +55,16 @@
#endif
};
-@@ -364,24 +374,37 @@
+@@ -364,28 +374,37 @@
* Based on dev/streams/streams.c
*/
static int
-+#if __FreeBSD_version >= 500000
- vmmon_clone(dev_t dev, int flags, void *data, struct thread *td)
-+#else
+ #if __FreeBSD_version >= 502017
+ vmmon_clone(struct cdev *dev, int flags, void *data, struct thread *td)
+ #else
+-vmmon_clone(dev_t dev, int flags, void *data, struct thread *td)
+vmmon_clone(dev_t dev, int flags, void *data, struct proc *p)
-+#endif
+ #endif
{
int fd, error;
struct file *fp;
@@ -104,12 +105,16 @@
PROC_UNLOCK(p);
vmmon_ref_count++;
-@@ -415,7 +438,7 @@
+@@ -415,11 +438,11 @@
*----------------------------------------------------------------------
*/
static int
+ #if __FreeBSD_version >= 502017
+ FreeBSD_Driver_Open(struct cdev *dev, int oflag, int devtype, struct thread *td)
+ #else
-FreeBSD_Driver_Open(dev_t dev, int oflag, int devtype, struct thread *td)
+FreeBSD_Driver_Open(dev_t dev, int oflag, int devtype, struct proc *p)
+ #endif
{
VMFreeBSD *vmFreeBSD;
diff --git a/emulators/vmware3/files/patch-ab b/emulators/vmware3/files/patch-ab
index 37b59b98ac41..31395f22462f 100644
--- a/emulators/vmware3/files/patch-ab
+++ b/emulators/vmware3/files/patch-ab
@@ -1,6 +1,14 @@
---- vmmon-only/freebsd/driver.c.orig Sat Mar 13 04:04:55 2004
-+++ vmmon-only/freebsd/driver.c Sat Mar 13 04:07:43 2004
-@@ -163,9 +163,14 @@
+--- vmmon-only/freebsd/driver.c.orig Wed Jun 23 22:11:40 2004
++++ vmmon-only/freebsd/driver.c Wed Jun 23 22:14:46 2004
+@@ -50,6 +50,7 @@
+ #include <sys/filedesc.h>
+ #include <sys/fcntl.h>
+ #include <sys/malloc.h>
++#include <sys/module.h>
+ #include <sys/proc.h>
+ #include <sys/ioccom.h>
+ #include <sys/syslog.h>
+@@ -163,9 +164,14 @@
static struct cdevsw vmmon_cdevsw = {
#if __FreeBSD_version >= 500104
@@ -16,15 +24,51 @@
#else
/* open */ FreeBSD_Driver_Open,
/* close */ noclose,
-@@ -390,6 +395,11 @@
- fp->f_ops = &vmmon_fileops;
+@@ -224,7 +230,11 @@
+ *----------------------------------------------------------------------
+ */
+
++#if __FreeBSD_version >= 502017
++static struct cdev *vmmon_dev;
++#else
+ static dev_t vmmon_dev;
++#endif
+
+ static int
+ init_module(void)
+@@ -364,7 +374,11 @@
+ * Based on dev/streams/streams.c
+ */
+ static int
++#if __FreeBSD_version >= 502017
++vmmon_clone(struct cdev *dev, int flags, void *data, struct thread *td)
++#else
+ vmmon_clone(dev_t dev, int flags, void *data, struct thread *td)
++#endif
+ {
+ int fd, error;
+ struct file *fp;
+@@ -391,6 +405,11 @@
fp->f_type = DTYPE_VNODE;
FILEDESC_UNLOCK(p->p_fd);
-+
+
+#if __FreeBSD_version >= 501111
+ /* falloc now returns TWO references to the file, not one. */
+ fdrop(fp, td);
+#endif
-
++
PROC_LOCK(p);
td->td_dupfd = fd;
+ PROC_UNLOCK(p);
+@@ -415,7 +434,11 @@
+ *----------------------------------------------------------------------
+ */
+ static int
++#if __FreeBSD_version >= 502017
++FreeBSD_Driver_Open(struct cdev *dev, int oflag, int devtype, struct thread *td)
++#else
+ FreeBSD_Driver_Open(dev_t dev, int oflag, int devtype, struct thread *td)
++#endif
+ {
+ VMFreeBSD *vmFreeBSD;
+