summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVadim Kuznetsov <vadimk@gentoo.org>2012-01-06 14:30:38 +0000
committerVadim Kuznetsov <vadimk@gentoo.org>2012-01-06 14:30:38 +0000
commit96a95078f76e25a2e1a9bd4435dbad70a2d535c0 (patch)
treef14611961166c4edb6fe0958410f635eb1976627 /app-emulation/vmware-modules
parentBased on 3.1.7 + genpatches-3.1-10 + grsecurity-2.2.2-3.1.7-201201032037 (diff)
downloadgentoo-2-96a95078f76e25a2e1a9bd4435dbad70a2d535c0.tar.gz
gentoo-2-96a95078f76e25a2e1a9bd4435dbad70a2d535c0.tar.bz2
gentoo-2-96a95078f76e25a2e1a9bd4435dbad70a2d535c0.zip
added patch for 3.2 kernel
(Portage version: 2.1.10.44/cvs/Linux x86_64)
Diffstat (limited to 'app-emulation/vmware-modules')
-rw-r--r--app-emulation/vmware-modules/ChangeLog8
-rw-r--r--app-emulation/vmware-modules/files/264-3.2.0.patch93
-rw-r--r--app-emulation/vmware-modules/vmware-modules-264.1.ebuild5
3 files changed, 102 insertions, 4 deletions
diff --git a/app-emulation/vmware-modules/ChangeLog b/app-emulation/vmware-modules/ChangeLog
index 8e43c6a954ba..fe9907338397 100644
--- a/app-emulation/vmware-modules/ChangeLog
+++ b/app-emulation/vmware-modules/ChangeLog
@@ -1,6 +1,10 @@
# ChangeLog for app-emulation/vmware-modules
-# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/vmware-modules/ChangeLog,v 1.84 2011/12/05 16:06:08 vadimk Exp $
+# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/app-emulation/vmware-modules/ChangeLog,v 1.85 2012/01/06 14:30:38 vadimk Exp $
+
+ 06 Jan 2012; Vadim Kuznetsov <vadimk@gentoo.org> +files/264-3.2.0.patch,
+ vmware-modules-264.1.ebuild:
+ added patch for 3.2 kernel
05 Dec 2011; Vadim Kuznetsov <vadimk@gentoo.org>
-files/1.0.0.25-autoconf-generated.patch,
diff --git a/app-emulation/vmware-modules/files/264-3.2.0.patch b/app-emulation/vmware-modules/files/264-3.2.0.patch
new file mode 100644
index 000000000000..60a0be288765
--- /dev/null
+++ b/app-emulation/vmware-modules/files/264-3.2.0.patch
@@ -0,0 +1,93 @@
+diff --git a/vmmon-only/linux/iommu.c b/vmmon-only/linux/iommu.c
+index c692c2d..e8b6099 100644
+--- a/vmmon-only/linux/iommu.c
++++ b/vmmon-only/linux/iommu.c
+@@ -42,6 +42,12 @@
+ #define PCI_BDF_SLOTFUNC(bdf) PCI_DEVFN(PCI_SLOT(bdf), PCI_FUNC(bdf))
+ #define PCI_BDF_BUS(bdf) (((bdf) >> 8) & 0xff)
+
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 2, 0)
++#include <linux/pci.h>
++#define iommu_found() iommu_present(&pci_bus_type)
++#define iommu_domain_alloc() iommu_domain_alloc(&pci_bus_type)
++#endif
++
+ typedef struct PassthruDevice {
+ uint32 bdf;
+ struct pci_dev *pdev;
+diff --git a/vmnet-only/filter.c b/vmnet-only/filter.c
+index 491add5..74f7a3b 100644
+--- a/vmnet-only/filter.c
++++ b/vmnet-only/filter.c
+@@ -40,6 +40,10 @@
+ #include "vnetInt.h"
+ #include "vmnetInt.h"
+
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 2, 0)
++#include <linux/export.h>
++#endif
++
+ // VNet_FilterLogPacket.action for dropped packets
+ #define VNET_FILTER_ACTION_DRP (1)
+ #define VNET_FILTER_ACTION_DRP_SHORT (2)
+diff --git a/vmnet-only/netif.c b/vmnet-only/netif.c
+index 4bdb643..540301c 100644
+--- a/vmnet-only/netif.c
++++ b/vmnet-only/netif.c
+@@ -62,7 +62,9 @@ static int VNetNetifClose(struct net_device *dev);
+ static int VNetNetifStartXmit(struct sk_buff *skb, struct net_device *dev);
+ static struct net_device_stats *VNetNetifGetStats(struct net_device *dev);
+ static int VNetNetifSetMAC(struct net_device *dev, void *addr);
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 2, 0)
+ static void VNetNetifSetMulticast(struct net_device *dev);
++#endif
+ #if 0
+ static void VNetNetifTxTimeout(struct net_device *dev);
+ #endif
+@@ -131,7 +133,9 @@ VNetNetIfSetup(struct net_device *dev) // IN:
+ .ndo_stop = VNetNetifClose,
+ .ndo_get_stats = VNetNetifGetStats,
+ .ndo_set_mac_address = VNetNetifSetMAC,
++#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 2, 0)
+ .ndo_set_multicast_list = VNetNetifSetMulticast,
++#endif
+ /*
+ * We cannot stuck... If someone will report problems under
+ * low memory conditions or some such, we should enable it.
+@@ -612,11 +616,12 @@ VNetNetifSetMAC(struct net_device *dev, // IN:
+ *----------------------------------------------------------------------
+ */
+
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 2, 0)
+ void
+ VNetNetifSetMulticast(struct net_device *dev) // IN: unused
+ {
+ }
+-
++#endif
+
+ /*
+ *----------------------------------------------------------------------
+diff --git a/vmnet-only/userif.c b/vmnet-only/userif.c
+index 541187b..77e0089 100644
+--- a/vmnet-only/userif.c
++++ b/vmnet-only/userif.c
+@@ -517,10 +517,18 @@ VNetCsumCopyDatagram(const struct sk_buff *skb, // IN: skb to copy
+ unsigned int tmpCsum;
+ const void *vaddr;
+
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 2, 0)
++ vaddr = kmap(skb_frag_page(frag));
++#else
+ vaddr = kmap(frag->page);
++#endif
+ tmpCsum = csum_and_copy_to_user(vaddr + frag->page_offset,
+ curr, frag->size, 0, &err);
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 2, 0)
++ kunmap(skb_frag_page(frag));
++#else
+ kunmap(frag->page);
++#endif
+ if (err) {
+ return err;
+ }
diff --git a/app-emulation/vmware-modules/vmware-modules-264.1.ebuild b/app-emulation/vmware-modules/vmware-modules-264.1.ebuild
index e09b4adec72b..a35a17403423 100644
--- a/app-emulation/vmware-modules/vmware-modules-264.1.ebuild
+++ b/app-emulation/vmware-modules/vmware-modules-264.1.ebuild
@@ -1,6 +1,6 @@
-# Copyright 1999-2011 Gentoo Foundation
+# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/vmware-modules/vmware-modules-264.1.ebuild,v 1.1 2011/12/03 20:04:15 vadimk Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-emulation/vmware-modules/vmware-modules-264.1.ebuild,v 1.2 2012/01/06 14:30:38 vadimk Exp $
EAPI="2"
@@ -63,6 +63,7 @@ src_prepare() {
epatch "${FILESDIR}/${PV_MAJOR}-makefile-include.patch"
epatch "${FILESDIR}/${PV_MAJOR}-jobserver.patch"
epatch "${FILESDIR}/${PV_MAJOR}-netdevice.patch"
+ epatch "${FILESDIR}/${PV_MAJOR}-3.2.0.patch"
}
src_install() {