summaryrefslogtreecommitdiff
path: root/recipes/ti/files/lpm-device-create-and-semaphore-include-fix.patch
diff options
context:
space:
mode:
Diffstat (limited to 'recipes/ti/files/lpm-device-create-and-semaphore-include-fix.patch')
-rw-r--r--recipes/ti/files/lpm-device-create-and-semaphore-include-fix.patch121
1 files changed, 121 insertions, 0 deletions
diff --git a/recipes/ti/files/lpm-device-create-and-semaphore-include-fix.patch b/recipes/ti/files/lpm-device-create-and-semaphore-include-fix.patch
new file mode 100644
index 0000000000..a3bc2b14a6
--- /dev/null
+++ b/recipes/ti/files/lpm-device-create-and-semaphore-include-fix.patch
@@ -0,0 +1,121 @@
+diff -uNr codec_engine_2_21/cetools/packages/ti/bios/power/modules/omap3530/lpm/lpm_driver.c codec_engine_2_21_fix/cetools/packages/ti/bios/power/modules/omap3530/lpm/lpm_driver.c
+--- codec_engine_2_21/cetools/packages/ti/bios/power/modules/omap3530/lpm/lpm_driver.c 2008-11-05 00:18:39.000000000 +0000
++++ codec_engine_2_21_fix/cetools/packages/ti/bios/power/modules/omap3530/lpm/lpm_driver.c 2009-02-13 00:16:50.000000000 +0000
+@@ -225,6 +225,9 @@
+ .os_wait = lpm_os_wait,
+ .os_trace = lpm_os_trace,
+ };
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,27)
++ char lpm_tempDeviceCreateName[50];
++#endif
+
+ TRACE(KERN_ALERT "lpm.ko: + lpm_init\n");
+
+@@ -286,9 +289,16 @@
+ MKDEV(lpm->inst[i].major, lpm->inst[i].minor),
+ NULL, "lpm%d", lpm->inst[i].minor);
+ #else
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,27)
++ sprintf(lpm_tempDeviceCreateName, "lpm%d", lpm->inst[i].minor);
++ device_create(lpm->lpm_class, NULL,
++ MKDEV(lpm->inst[i].major, lpm->inst[i].minor),
++ NULL, lpm_tempDeviceCreateName);
++#else
+ device_create(lpm->lpm_class, NULL,
+ MKDEV(lpm->inst[i].major, lpm->inst[i].minor),
+ "lpm%d", lpm->inst[i].minor);
++#endif /* LINUX_VERSION */
+ #endif
+ }
+
+diff -uNr codec_engine_2_21/cetools/packages/ti/bios/power/modules/omap2530/lpm/lpm_driver.c codec_engine_2_21_fix/cetools/packages/ti/bios/power/modules/omap2530/lpm/lpm_driver.c
+--- codec_engine_2_21/cetools/packages/ti/bios/power/modules/omap2530/lpm/lpm_driver.c 2008-11-05 00:18:39.000000000 +0000
++++ codec_engine_2_21_fix/cetools/packages/ti/bios/power/modules/omap2530/lpm/lpm_driver.c 2009-02-13 00:16:50.000000000 +0000
+@@ -225,6 +225,9 @@
+ .os_wait = lpm_os_wait,
+ .os_trace = lpm_os_trace,
+ };
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,27)
++ char lpm_tempDeviceCreateName[50];
++#endif
+
+ TRACE(KERN_ALERT "lpm.ko: + lpm_init\n");
+
+@@ -286,9 +289,16 @@
+ MKDEV(lpm->inst[i].major, lpm->inst[i].minor),
+ NULL, "lpm%d", lpm->inst[i].minor);
+ #else
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,27)
++ sprintf(lpm_tempDeviceCreateName, "lpm%d", lpm->inst[i].minor);
++ device_create(lpm->lpm_class, NULL,
++ MKDEV(lpm->inst[i].major, lpm->inst[i].minor),
++ NULL, lpm_tempDeviceCreateName);
++#else
+ device_create(lpm->lpm_class, NULL,
+ MKDEV(lpm->inst[i].major, lpm->inst[i].minor),
+ "lpm%d", lpm->inst[i].minor);
++#endif /* LINUX_VERSION */
+ #endif
+ }
+
+diff -uNr codec_engine_2_21/cetools/packages/ti/bios/power/modules/dm357/lpm/lpm_driver.c codec_engine_2_21_fix/cetools/packages/ti/bios/power/modules/dm357/lpm/lpm_driver.c
+--- codec_engine_2_21/cetools/packages/ti/bios/power/modules/dm357/lpm/lpm_driver.c 2008-11-05 00:18:39.000000000 +0000
++++ codec_engine_2_21_fix/cetools/packages/ti/bios/power/modules/dm357/lpm/lpm_driver.c 2009-02-13 00:16:50.000000000 +0000
+@@ -225,6 +225,9 @@
+ .os_wait = lpm_os_wait,
+ .os_trace = lpm_os_trace,
+ };
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,27)
++ char lpm_tempDeviceCreateName[50];
++#endif
+
+ TRACE(KERN_ALERT "lpm.ko: + lpm_init\n");
+
+@@ -286,9 +289,16 @@
+ MKDEV(lpm->inst[i].major, lpm->inst[i].minor),
+ NULL, "lpm%d", lpm->inst[i].minor);
+ #else
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,27)
++ sprintf(lpm_tempDeviceCreateName, "lpm%d", lpm->inst[i].minor);
++ device_create(lpm->lpm_class, NULL,
++ MKDEV(lpm->inst[i].major, lpm->inst[i].minor),
++ NULL, lpm_tempDeviceCreateName);
++#else
+ device_create(lpm->lpm_class, NULL,
+ MKDEV(lpm->inst[i].major, lpm->inst[i].minor),
+ "lpm%d", lpm->inst[i].minor);
++#endif /* LINUX_VERSION */
+ #endif
+ }
+
+diff -uNr codec_engine_2_21/cetools/packages/ti/bios/power/modules/dm6446/lpm/lpm_driver.c codec_engine_2_21_fix/cetools/packages/ti/bios/power/modules/dm6446/lpm/lpm_driver.c
+--- codec_engine_2_21/cetools/packages/ti/bios/power/modules/dm6446/lpm/lpm_driver.c 2008-11-05 00:18:39.000000000 +0000
++++ codec_engine_2_21_fix/cetools/packages/ti/bios/power/modules/dm6446/lpm/lpm_driver.c 2009-02-13 00:16:50.000000000 +0000
+@@ -225,6 +225,9 @@
+ .os_wait = lpm_os_wait,
+ .os_trace = lpm_os_trace,
+ };
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,27)
++ char lpm_tempDeviceCreateName[50];
++#endif
+
+ TRACE(KERN_ALERT "lpm.ko: + lpm_init\n");
+
+@@ -286,9 +289,16 @@
+ MKDEV(lpm->inst[i].major, lpm->inst[i].minor),
+ NULL, "lpm%d", lpm->inst[i].minor);
+ #else
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,27)
++ sprintf(lpm_tempDeviceCreateName, "lpm%d", lpm->inst[i].minor);
++ device_create(lpm->lpm_class, NULL,
++ MKDEV(lpm->inst[i].major, lpm->inst[i].minor),
++ NULL, lpm_tempDeviceCreateName);
++#else
+ device_create(lpm->lpm_class, NULL,
+ MKDEV(lpm->inst[i].major, lpm->inst[i].minor),
+ "lpm%d", lpm->inst[i].minor);
++#endif /* LINUX_VERSION */
+ #endif
+ }
+
+