diff options
author | Koen Kooi <koen@openembedded.org> | 2010-12-05 18:32:59 +0100 |
---|---|---|
committer | Koen Kooi <koen@openembedded.org> | 2010-12-06 13:50:57 +0100 |
commit | 99ef5269e5d0814cf17572e063f6c573a162567d (patch) | |
tree | c850463010d7fcc7ba9cbd53f78385ea2f492878 /recipes/ti | |
parent | f911e1aab342970c72e44e4f340165ca7cba56a5 (diff) | |
download | openembedded-99ef5269e5d0814cf17572e063f6c573a162567d.tar.gz |
ti-local-power-manager: fix build with recent kernels
Signed-off-by: Koen Kooi <k-kooi@ti.com>
Diffstat (limited to 'recipes/ti')
-rw-r--r-- | recipes/ti/ti-local-power-manager/lpm-BKL-fix.patch | 39 | ||||
-rw-r--r-- | recipes/ti/ti-local-power-manager_1.24.02.09.bb | 2 |
2 files changed, 41 insertions, 0 deletions
diff --git a/recipes/ti/ti-local-power-manager/lpm-BKL-fix.patch b/recipes/ti/ti-local-power-manager/lpm-BKL-fix.patch new file mode 100644 index 0000000000..43bb5a9acc --- /dev/null +++ b/recipes/ti/ti-local-power-manager/lpm-BKL-fix.patch @@ -0,0 +1,39 @@ +From: Koen Kooi <k-kooi@ti.com> +Subject: Fix build with 2.6.37rcX + +--- + +--- /tmp/lpm_driver.c 2010-12-05 18:25:17.000000000 +0100 ++++ local_power_manager_linux_1_24_02_09/packages/ti/bios/power/modules/omap3530/lpm/lpm_driver.c 2010-12-05 18:30:13.000000000 +0100 +@@ -40,6 +40,7 @@ + #include <asm/semaphore.h> + #endif + #include <linux/io.h> ++#include <linux/slab.h> + + #include "lpm_driver.h" + #include "lpm_dev.h" +@@ -111,7 +112,11 @@ + + static struct file_operations lpm_fops = { + .owner = THIS_MODULE, ++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,36) + .ioctl = lpm_ioctl, ++#else ++ .unlocked_ioctl = lpm_ioctl, ++#endif + .open = lpm_open, + .release = lpm_release, + }; +@@ -244,7 +249,11 @@ + lpm->inst[i].major = MAJOR(lpm->first); + lpm->inst[i].minor = MINOR(lpm->first) + i; + INIT_LIST_HEAD(&lpm->inst[i].clients); ++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,36) + init_MUTEX(&lpm->inst[i].sem); ++#else ++ sema_init(&lpm->inst[i].sem,1); ++#endif + init_completion(&lpm->inst[i].event); + lpm_devAttrs.os_instance = (void *)&lpm->inst[i]; + LPM_init(i, &lpm->inst[i].lpm, &lpm_devAttrs); diff --git a/recipes/ti/ti-local-power-manager_1.24.02.09.bb b/recipes/ti/ti-local-power-manager_1.24.02.09.bb index 9c8b4df4e2..759561f38c 100644 --- a/recipes/ti/ti-local-power-manager_1.24.02.09.bb +++ b/recipes/ti/ti-local-power-manager_1.24.02.09.bb @@ -3,6 +3,8 @@ require ti-local-power-manager.inc PV = "1_24_02_09" PE = "1" +SRC_URI += "file://lpm-BKL-fix.patch" + SRC_URI[lpmtarball.md5sum] = "3d05453df26dfc811de04839d74c2f2b" SRC_URI[lpmtarball.sha256sum] = "7335959a6217df17289f81839e6c6948f31cc0797ebc5389edef7190ed3ea589" |