From d1a7ed7845f6a7b0bc1bd8cf907cc804aa5f4689 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Adam=20Go=C5=82=C4=99biowski?= Date: Sun, 31 Jan 2010 13:41:47 +0000 Subject: [PATCH] - new; buildfix for kernels 2.6.31+ Changed files: VMware-server-linux-2.6.31.patch -> 1.1 --- VMware-server-linux-2.6.31.patch | 39 ++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 VMware-server-linux-2.6.31.patch diff --git a/VMware-server-linux-2.6.31.patch b/VMware-server-linux-2.6.31.patch new file mode 100644 index 0000000..a9682ff --- /dev/null +++ b/VMware-server-linux-2.6.31.patch @@ -0,0 +1,39 @@ +patch from: http://communities.vmware.com/thread/231812 + +diff -Naur ./vmnet-only/netif.c.org ./vmnet-only/netif.c +--- ./vmnet-only/netif.c.org 2009-10-22 09:55:41.937580511 +0200 ++++ ./vmnet-only/netif.c 2009-10-22 09:55:41.937580511 +0200 +@@ -194,10 +194,25 @@ + *---------------------------------------------------------------------- + */ + ++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 30) ++static const struct net_device_ops vnet_netdev_ops = { ++ .ndo_init = VNetNetifProbe, ++ .ndo_open = VNetNetifOpen, ++ .ndo_start_xmit = VNetNetifStartXmit, ++ .ndo_stop = VNetNetifClose, ++ .ndo_get_stats = VNetNetifGetStats, ++ .ndo_set_mac_address = VNetNetifSetMAC, ++ .ndo_set_multicast_list = VNetNetifSetMulticast, ++}; ++#endif ++ + static void + VNetNetIfSetup(struct net_device *dev) // IN: + { + ether_setup(dev); // turns on IFF_BROADCAST, IFF_MULTICAST ++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 30) ++ dev->netdev_ops = &vnet_netdev_ops; ++#else + dev->init = VNetNetifProbe; + dev->open = VNetNetifOpen; + dev->hard_start_xmit = VNetNetifStartXmit; +@@ -205,6 +220,7 @@ + dev->get_stats = VNetNetifGetStats; + dev->set_mac_address = VNetNetifSetMAC; + dev->set_multicast_list = VNetNetifSetMulticast; ++#endif + #ifdef KERNEL_2_3_43 + /* + * We cannot stuck... If someone will report problems under -- 2.43.0