aboutsummaryrefslogtreecommitdiff
blob: 75daad33ec6a30f7ca6f197476a93f44bee12bf1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
Index: usr/src/nv/conftest.sh
===================================================================
--- usr/src/nv/conftest.sh	
+++ usr/src/nv/conftest.sh	2010-01-06 12:10:56.000000000 +0530
@@ -32,14 +32,14 @@
     # CONFIG_XEN and CONFIG_PARAVIRT are present, text_xen() treats
     # the kernel as a stand-alone kernel.
     #
-    FILE="linux/autoconf.h"
+    FILE="generated/autoconf.h"
 
     if [ -f $HEADERS/$FILE -o -f $OUTPUT/include/$FILE ]; then
         #
         # We are looking at a configured source tree; verify
         # that it's not a Xen kernel.
         #
-        echo "#include <linux/autoconf.h>
+        echo "#include <generated/autoconf.h>
         #if defined(CONFIG_XEN) && !defined(CONFIG_PARAVIRT)
         #error CONFIG_XEN defined!
         #endif
@@ -111,7 +111,12 @@
     fi
 }
 
-CONFTEST_PREAMBLE="#include <linux/autoconf.h>
+CONFTEST_PREAMBLE="#include <linux/version.h>
+    #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,33)
+    #include <generated/autoconf.h>
+    #else
+    #include <linux/autoconf.h>
+    #endif
     #if defined(CONFIG_XEN) && \
         defined(CONFIG_XEN_INTERFACE_VERSION) &&  !defined(__XEN_INTERFACE_VERSION__)
     #define __XEN_INTERFACE_VERSION__ CONFIG_XEN_INTERFACE_VERSION
@@ -1294,7 +1299,7 @@
                 echo "";
             fi
         fi
-        exit $RET
+#        exit $RET
     ;;
 
     get_uname)
@@ -1316,11 +1321,11 @@
             # tree or at headers shipped for a specific kernel.
             # Determine the kernel version using a compile check.
             #
-            FILE="linux/utsrelease.h"
+            FILE="generated/utsrelease.h"
 
             if [ -f $HEADERS/$FILE -o -f $OUTPUT/include/$FILE ]; then
                 echo "$CONFTEST_PREAMBLE
-                #include <linux/utsrelease.h>
+                #include <generated/utsrelease.h>
                 int main() {
                     printf(\"%s\", UTS_RELEASE);
                     return 0;
@@ -1375,7 +1380,7 @@
         #
         RET=1
         VERBOSE=$6
-        FILE="linux/autoconf.h"
+        FILE="generated/autoconf.h"
 
         if [ -f $HEADERS/$FILE -o -f $OUTPUT/include/$FILE ]; then
             #
@@ -1429,7 +1434,7 @@
         #
         RET=1
         VERBOSE=$6
-        FILE="linux/autoconf.h"
+        FILE="generated/autoconf.h"
 
         if [ -f $HEADERS/$FILE -o -f $OUTPUT/include/$FILE ]; then
             #
Index: usr/src/nv/nvacpi.c
===================================================================
--- usr/src/nv/nvacpi.c	
+++ usr/src/nv/nvacpi.c	2010-01-06 12:10:56.000000000 +0530
@@ -49,6 +49,10 @@
 };
 #endif
 
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 33)
+#define acpi_walk_namespace(a,b,c,d,e,f) acpi_walk_namespace(a,b,c,d,e,f,NULL)
+#endif
+
 static struct acpi_driver *nv_acpi_driver;
 static acpi_handle nvif_handle = NULL;
 static acpi_handle dsm_handle  = NULL;