diff -ur vmnet-only/bridge.c vmnet-only-patched/bridge.c
--- vmnet-only/bridge.c	2008-03-04 16:42:20.000000000 -0500
+++ vmnet-only-patched/bridge.c	2008-04-20 12:40:17.000000000 -0400
@@ -102,6 +102,18 @@
                                int count, int *eof, void *data);
 
 
+// jondaley's guess/hack to make vmware compile cleanly on 2.6.25
+#if LINUX_VERSION_CODE == KERNEL_VERSION(2, 6, 25)
+static inline void sock_valbool_flag(struct sock *sk, int bit, int valbool)
+{
+  if (valbool)
+    sock_set_flag(sk, bit);
+  else
+    sock_reset_flag(sk, bit);
+}
+#endif
+
+
 /*
  *----------------------------------------------------------------------
  *
Only in vmnet-only-patched/: bridge.c~
diff -ur vmnet-only/compat_wait.h vmnet-only-patched/compat_wait.h
--- vmnet-only/compat_wait.h	2008-03-04 16:42:20.000000000 -0500
+++ vmnet-only-patched/compat_wait.h	2008-04-14 18:24:46.000000000 -0400
@@ -34,13 +34,13 @@
  * 2.4.20-wolk4.0s.
  */
 
-#if VMW_HAVE_EPOLL // {
+#ifdef VMW_HAVE_EPOLL // {
 #define compat_poll_wqueues struct poll_wqueues
 #else // } {
 #define compat_poll_wqueues poll_table
 #endif // }
 
-#if VMW_HAVE_EPOLL // {
+#ifdef VMW_HAVE_EPOLL // {
 
 /* If prototype does not match, build will abort here */
 extern void poll_initwait(compat_poll_wqueues *);
diff -ur vmnet-only/driver.c vmnet-only-patched/driver.c
--- vmnet-only/driver.c	2008-03-04 16:42:20.000000000 -0500
+++ vmnet-only-patched/driver.c	2008-04-14 18:24:46.000000000 -0400
@@ -516,14 +516,20 @@
 void
 cleanup_module(void)
 {
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 24)
    int retval;
+#endif
 
    unregister_ioctl32_handlers();
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 24)
    retval =  unregister_chrdev(VNET_MAJOR_NUMBER, "vmnet");
    if (retval != 0 ) {
       LOG(0, (KERN_WARNING "/dev/vmnet: could not unregister major device %d\n", 
 	      VNET_MAJOR_NUMBER));
    }
+#else /* >= 2.6.24 */
+   unregister_chrdev(VNET_MAJOR_NUMBER, "vmnet");
+#endif
    VNetProtoUnregister();
    VNetProc_Cleanup();
 }
diff -ur vmnet-only/Makefile.kernel vmnet-only-patched/Makefile.kernel
--- vmnet-only/Makefile.kernel	2008-03-04 16:42:20.000000000 -0500
+++ vmnet-only-patched/Makefile.kernel	2008-04-14 18:24:46.000000000 -0400
@@ -7,9 +7,10 @@
 ####
 
 vm_check_build = $(shell if $(CC) $(CPPFLAGS) $(CFLAGS) $(CFLAGS_KERNEL) \
-	$(EXTRA_CFLAGS) -Iinclude2/asm/mach-default -DKBUILD_BASENAME=\"$(DRIVER)\" \
+	$(EXTRA_CFLAGS) $(KBUILD_CPPFLAGS) $(KBUILD_CFLAGS)                    \
+	-Iinclude2/asm/mach-default -DKBUILD_BASENAME=\"$(DRIVER)\"            \
 	-Werror -S -o /dev/null -xc $(1) \
-	> /dev/null 2>&1; then echo "$(2)"; else echo "$(3)"; fi)
+	>/dev/null 2>&1 ; then echo "$(2)"; else echo "$(3)"; fi;)
 
 CC_WARNINGS := -Wall -Wstrict-prototypes 
 CC_OPTS := $(GLOBAL_DEFS) $(CC_WARNINGS) 
diff -ur vmnet-only/netif.c vmnet-only-patched/netif.c
--- vmnet-only/netif.c	2008-03-04 16:42:20.000000000 -0500
+++ vmnet-only-patched/netif.c	2008-04-14 18:24:46.000000000 -0400
@@ -295,6 +295,10 @@
    dev->watchdog_timeo = TX_TIMEOUT;
 #endif
 #endif   
+
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 24)
+   dev->nd_net = &init_net;
+#endif
    
    if (register_netdev(dev) != 0) {
       LOG(0, (KERN_NOTICE "%s: could not register network device\n", devName));
diff -ur vmnet-only/sk_alloc.c vmnet-only-patched/sk_alloc.c
--- vmnet-only/sk_alloc.c	2008-03-04 16:42:20.000000000 -0500
+++ vmnet-only-patched/sk_alloc.c	2008-04-14 18:24:46.000000000 -0400
@@ -4,6 +4,7 @@
  */
 
 #include <net/sock.h>
+#include <linux/version.h>
 
 static struct proto test_proto = {
    .name     = "TEST",
@@ -12,5 +13,9 @@
 struct sock * 
 vmware_sk_alloc(void)
 {
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 24)
    return sk_alloc(PF_NETLINK, 0, &test_proto, 1);
+#else
+   return sk_alloc(&init_net, PF_NETLINK, 0, &test_proto);
+#endif
 }
diff -ur vmnet-only/vm_basic_types.h vmnet-only-patched/vm_basic_types.h
--- vmnet-only/vm_basic_types.h	2008-03-04 16:42:20.000000000 -0500
+++ vmnet-only-patched/vm_basic_types.h	2008-04-14 18:24:46.000000000 -0400
@@ -154,6 +154,8 @@
 #   endif
 
 #   ifndef _STDINT_H
+#      include <linux/version.h>
+#      if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 24)
 #      ifdef VM_I386
 #         ifdef VM_X86_64
              typedef uint64    uintptr_t;
@@ -166,6 +168,7 @@
           typedef uint64    uintptr_t;
 #      endif
 #   endif
+#   endif
 #endif
 
 
@@ -259,6 +262,7 @@
 #define MAX_UINT64 (CONST64U(0xffffffffffffffff))
 
 
+#include <linux/types.h>
 typedef uintptr_t VA;
 typedef uintptr_t VPN;
 
diff -ur vmnet-only/vmnetInt.h vmnet-only-patched/vmnetInt.h
--- vmnet-only/vmnetInt.h	2008-03-04 16:42:20.000000000 -0500
+++ vmnet-only-patched/vmnetInt.h	2008-04-14 18:24:46.000000000 -0400
@@ -35,7 +35,11 @@
 
 #ifdef VMW_HAVE_SK_ALLOC_WITH_PROTO
 extern struct proto vmnet_proto;
-#   define compat_sk_alloc(_pri) sk_alloc(PF_NETLINK, _pri, &vmnet_proto, 1)
+#   if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 24)
+#       define compat_sk_alloc(_pri) sk_alloc(PF_NETLINK, _pri, &vmnet_proto, 1)
+#   else
+#       define compat_sk_alloc(_pri) sk_alloc(&init_net, PF_NETLINK, _pri, &vmnet_proto)
+#   endif
 #elif defined(KERNEL_2_5_5)
 #   define compat_sk_alloc(_pri) sk_alloc(PF_NETLINK, _pri, 1, NULL)
 #else
diff -ur vmnet-only/vnetInt.h vmnet-only-patched/vnetInt.h
--- vmnet-only/vnetInt.h	2008-03-04 16:42:20.000000000 -0500
+++ vmnet-only-patched/vnetInt.h	2008-04-14 18:24:46.000000000 -0400
@@ -29,11 +29,15 @@
     compat_skb_set_network_header(skb, sizeof (struct ethhdr)),  \
     dev_queue_xmit(skb)                                   \
   )
-#ifdef KERNEL_2_3_15
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 3, 15)
 #  define dev_lock_list()		read_lock(&dev_base_lock)
 #  define dev_unlock_list()		read_unlock(&dev_base_lock)
+# if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 24)
+#  define DEV_GET(x)                    __dev_get_by_name(&init_net, x)
+# else /* <= 2.6.24 */
 #  define DEV_GET(x)                    __dev_get_by_name(x)
-#else
+# endif
+#else  /* <= 2.3.15 */
 #  define DEV_GET(x)			dev_get(x)
 #endif
 
