diff -Nur vmhgfs-only.orig/driver-config.h vmhgfs-only/driver-config.h
--- vmhgfs-only.orig/driver-config.h	2008-03-04 21:57:54.000000000 +0100
+++ vmhgfs-only/driver-config.h	2008-04-22 16:48:47.000000000 +0200
@@ -21,6 +21,23 @@
 #include <linux/autoconf.h>
 #include "compat_version.h"
 
+/*
+ * I still haven't figured out why the automagic checks in Makefile.kernel
+ * don't work. They call the script vm_check_build which isn't available
+ * on any of my systems so `make` is unable to find out whether this features
+ * need to be included or not.
+ *
+ * A simple workaround is to rely on the kernel configuration as shown below.
+ * If CONFIG_EPOLL is set, we have EPOLL set, basta.
+ *
+ * by Alexander Griesser <work@tuxx-home.at>, 2008-03-14
+ */
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+#ifdef CONFIG_EPOLL
+#define VMW_HAVE_EPOLL 1
+#endif
+#endif
+
 /* We rely on Kernel Module support.  Check here. */
 #ifndef CONFIG_MODULES
 #error "No Module support in this kernel.  Please configure with CONFIG_MODULES"
diff -Nur vmhgfs-only.orig/driver.c vmhgfs-only/driver.c
--- vmhgfs-only.orig/driver.c	2008-03-04 21:57:54.000000000 +0100
+++ vmhgfs-only/driver.c	2008-04-22 21:12:13.000000000 +0200
@@ -41,8 +41,40 @@
 #define HGFS_SB_TO_COMMON(sb)             ((HgfsSuperInfo *)(sb)->s_fs_info)
 #endif
 
+/* With 2.6.19 they removed the union struct 'u' in the inode struct and moved
+ * u.generic_ip to i_private
+ * 2007-06-29 by Alexander Griesser <vmware@tuxx-home.at>
+ */
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 19)
+#define INODE_SET_II_P(inode, info) do { (inode)->i_private = (info); } while (0)
+#define INODE_GET_II_P(inode) ((HgfsInodeInfo *)(inode)->i_private)
+#else
 #define INODE_SET_II_P(inode, info) do { (inode)->u.generic_ip = (info); } while (0)
 #define INODE_GET_II_P(inode) ((HgfsInodeInfo *)(inode)->u.generic_ip)
+#endif
+
+/*
+ * 2.6.25 removed the iget() function in favour of implementing it on your
+ * own if I understood the patch comment correctly ;)
+ *
+ * by Alexander Griesser <vmware@tuxx-home.at>, 2008-04-22
+ */
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25)
+struct inode *iget(struct super_block *sb, unsigned long ino)
+{
+  struct inode *inode = iget_locked(sb, ino);
+
+  if (!inode)
+    return ERR_PTR(-ENOMEM);
+
+  if(!(inode->i_state & I_NEW))
+    iget_failed(inode);
+  else
+    unlock_new_inode(inode);
+
+  return inode;
+}
+#endif
 
 /*
  * 2.5.x kernels support nanoseconds timestamps.
@@ -760,7 +792,16 @@
    inode->i_uid = 0;   /* This is bogus, should be the mount owner. */
    inode->i_gid = 0;   /* This is bogus, should be the mount owner. */
    inode->i_rdev = 0;  /* Device nodes are not supported */
-   inode->i_blksize = HGFS_BLOCKSIZE;
+
+   /* With kernel 2.6.19 they removed i_blksize from the inode struct
+    * 2007-06-29 by Alexander Griesser <vmware@tuxx-home.at>
+    */
+   #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 19)
+     inode->i_bdev->bd_block_size = HGFS_BLOCKSIZE;
+   #else
+     inode->i_blksize = HGFS_BLOCKSIZE;
+   #endif
+
    inode->i_blocks = (attr->size + HGFS_BLOCKSIZE - 1) / HGFS_BLOCKSIZE;
    inode->i_size = attr->size;
    HGFS_SET_TIME(inode->i_atime, attr->accessTime);
@@ -873,7 +914,17 @@
    LOG(6, (KERN_DEBUG "VMware hgfs: HgfsIget: entered\n"));
 
    inode = iget(sb, ino);
-   if (inode) {
+   if (inode
+/*
+ * I don't know if checking against is_bad_inode() is really necessary given
+ * the iget() implementation above, but I prefer more over less checking
+ *
+ * by Alexander Griesser <vmware@tuxx-home.at>, 2008-04-22
+ */
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25)
+   && !is_bad_inode(inode)
+#endif   
+   ) {
       /*
        * When it creates a new VFS inode, iget() sets INODE_GET_II_P(inode) to
        * NULL. --hpreg
@@ -4109,7 +4160,12 @@
    }
 }
 
-
+/*
+ * HgfsReadInode is not needed anymore on 2.6.25
+ *
+ * by Alexander Griesser <vmware@tuxx-home.at>, 2008-04-22
+ */
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,25)
 /*
  *-----------------------------------------------------------------------------
  *
@@ -4126,7 +4182,6 @@
  *
  *-----------------------------------------------------------------------------
  */
-
 void
 HgfsReadInode(struct inode *inode) // IN/OUT: VFS inode to fill in
 {
@@ -4138,6 +4193,7 @@
     *     them --hpreg
     */
 }
+#endif
 
 
 /*
@@ -4241,8 +4297,15 @@
    /* Optional */
    clear_inode:  HgfsClearInode,
 
+/* 
+ * read_inode disappeared from struct super_operations on 2.6.25
+ *
+ * by Alexander Griesser <vmware@tuxx-home.at>, 2008-04-22
+ */
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,25)
    /* Mandatory */
    read_inode:   HgfsReadInode,
+#endif
 
    /* Optional */
    put_super:    HgfsPutSuper,
@@ -4486,7 +4549,7 @@
 	  void *rawData)
 #endif
 {
-   return get_sb_nodev(fs_type, flags, rawData, HgfsReadSuper);
+   return get_sb_nodev(fs_type, flags, rawData, HgfsReadSuper, NULL);
 }
 #endif
 #else
diff -Nur vmhgfs-only.orig/modules.order vmhgfs-only/modules.order
--- vmhgfs-only.orig/modules.order	1970-01-01 01:00:00.000000000 +0100
+++ vmhgfs-only/modules.order	2008-04-22 21:12:18.000000000 +0200
@@ -0,0 +1 @@
+kernel//root/server-tools/vmware-tools-distrib/lib/modules/source/vmhgfs-only/vmhgfs.ko
diff -Nur vmhgfs-only.orig/vm_basic_types.h vmhgfs-only/vm_basic_types.h
--- vmhgfs-only.orig/vm_basic_types.h	2008-03-04 21:57:54.000000000 +0100
+++ vmhgfs-only/vm_basic_types.h	2008-04-22 16:52:24.000000000 +0200
@@ -14,6 +14,16 @@
 #ifndef _VM_BASIC_TYPES_H_
 #define _VM_BASIC_TYPES_H_
 
+/*
+ * Since we do some kernel version checks in here, make sure to include
+ * compat_version.h.
+ * <linux/types.h> is needed for uintptr on 2.6.24
+ *
+ * by Alexander Griesser <work@tuxx-home.at>, 2008-03-14
+ */
+#include "compat_version.h"
+#include <linux/types.h>
+
 #define INCLUDE_ALLOW_USERLEVEL
 #define INCLUDE_ALLOW_VMMEXT
 #define INCLUDE_ALLOW_MODULE
@@ -153,17 +163,25 @@
 #      endif
 #   endif
 
-#   ifndef _STDINT_H
-#      ifdef VM_I386
-#         ifdef VM_X86_64
-             typedef uint64    uintptr_t;
-#         else
-             typedef uint32    uintptr_t;
+/*
+ * uintptr_t is defined since 2.6.24, so defining it here will lead to
+ * compile errors.
+ *
+ * by Alexander Griesser <work@tuxx-home.at>, 2008-03-10
+ */
+#   if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,24)
+#      ifndef _STDINT_H
+#         ifdef VM_I386
+#            ifdef VM_X86_64
+                typedef uint64    uintptr_t;
+#            else
+                typedef uint32    uintptr_t;
+#            endif
 #         endif
-#      endif
 
-#      ifdef VM_IA64
-          typedef uint64    uintptr_t;
+#         ifdef VM_IA64
+              typedef uint64    uintptr_t;
+#         endif
 #      endif
 #   endif
 #endif
