~n-muench/ubuntu/saucy/open-vm-tools/open-vm-tools.fix-1175295

« back to all changes in this revision

Viewing changes to debian/patches/05-kernel-38-fixes.patch

Tags: 2012.12.26-958366-0ubuntu3
* Ubuntu-specific Changes
  - debian/rules: Added LIBS field with -lpthread.
    + Fixes package compile failure for Raring and future Ubuntu Releases.

* Items merged from Debian unstable:
  (From 2:9.2.2-893683-1 release)
  - Adding remote_fs dependency in initscript.
  - Correcting architecture fields in control.

  (From 2:9.2.2-893683-2 release)
  - Removing init order to network.

  (From 2:9.2.2-893683-4 release)
  - Removing init order to network also on start.

  (From 2:9.2.2-893683-5 release)
  - Updating to standards version 3.9.4.
  - Updating year in copyright file.
  - Prefixing patches with 4 digits for consistency.
  - Tightening diff headers in patches.
  - Dropping dpkg-source compression levels.

  (From 2:9.2.2-893683-6 release)
  - Remove all references to Daniel's old email address.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
Author: Nate Muench <NowIWillDestroyAbydos@gmail.com>
2
 
Description: Fixes building against 3.8 Kernel
3
 
 
4
 
Index: open-vm-tools.vmci-fix/modules/linux/shared/compat_mm.h
5
 
===================================================================
6
 
--- open-vm-tools.vmci-fix.orig/modules/linux/shared/compat_mm.h        2013-02-01 13:46:58.727967311 -0600
7
 
+++ open-vm-tools.vmci-fix/modules/linux/shared/compat_mm.h     2013-02-01 13:46:58.727967311 -0600
8
 
@@ -99,8 +99,18 @@
9
 
    vmtruncate(inode, size);                                                   \
10
 
    result;                                                                    \
11
 
 })
12
 
-#else
13
 
+#elif LINUX_VERSION_CODE < KERNEL_VERSION(3, 8, 0)
14
 
 #define compat_vmtruncate(inode, size) vmtruncate(inode, size)
15
 
+#else
16
 
+#define compat_vmtruncate(inode, size)                                        \
17
 
+({                                                                            \
18
 
+   result = inode_newsize_ok(inode, size);                                    \
19
 
+   if (!result)                                                               \
20
 
+   {                                                                          \
21
 
+      truncate_setsize(inode, size);                                          \
22
 
+   }                                                                          \
23
 
+   result;                                                                    \
24
 
+})
25
 
 #endif
26
 
 
27
 
 
28
 
Index: open-vm-tools.vmci-fix/modules/linux/vmci/linux/driver.c
29
 
===================================================================
30
 
--- open-vm-tools.vmci-fix.orig/modules/linux/vmci/linux/driver.c       2013-02-01 13:35:18.000000000 -0600
31
 
+++ open-vm-tools.vmci-fix/modules/linux/vmci/linux/driver.c    2013-02-01 13:48:00.264564452 -0600
32
 
@@ -128,7 +128,6 @@
33
 
    .name     = VMCI_DEVICE_NAME,
34
 
    .id_table = vmci_ids,
35
 
    .probe = vmci_probe_device,
36
 
-   .remove = __devexit_p(vmci_remove_device),
37
 
 };
38
 
 
39
 
 #if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 19)
40
 
@@ -1747,7 +1746,6 @@
41
 
  *-----------------------------------------------------------------------------
42
 
  */
43
 
 
44
 
-static int __devinit
45
 
 vmci_probe_device(struct pci_dev *pdev,           // IN: vmci PCI device
46
 
                   const struct pci_device_id *id) // IN: matching device ID
47
 
 {
48
 
@@ -1975,7 +1973,6 @@
49
 
  *-----------------------------------------------------------------------------
50
 
  */
51
 
 
52
 
-static void __devexit
53
 
 vmci_remove_device(struct pci_dev* pdev)
54
 
 {
55
 
    struct vmci_device *dev = pci_get_drvdata(pdev);