omap3-sgx-modules 1.4.14.2616: start updating it for 2.6.37
authorKoen Kooi <k-kooi@ti.com>
Tue, 23 Nov 2010 14:05:42 +0000 (15:05 +0100)
committerKoen Kooi <koen@openembedded.org>
Tue, 23 Nov 2010 14:05:42 +0000 (15:05 +0100)
Signed-off-by: Koen Kooi <k-kooi@ti.com>
recipes/powervr-drivers/omap3-sgx-modules/update.patch [new file with mode: 0644]
recipes/powervr-drivers/omap3-sgx-modules_1.4.14.2616.bb

diff --git a/recipes/powervr-drivers/omap3-sgx-modules/update.patch b/recipes/powervr-drivers/omap3-sgx-modules/update.patch
new file mode 100644 (file)
index 0000000..08ede82
--- /dev/null
@@ -0,0 +1,47 @@
+From: Koen Kooi <k-kooi@ti.com>
+Subject: omap3-sgx-modules: make it build with recent kernels
+
+This patch fixes 2 problems:
+
+1) use of omap_rev_*_*() to get ES revision, the patch adding that to the kernel was rejected
+2) removal of .ioctl from struct file_operations for BKL restructuring
+
+Signed-off-by: Koen Kooi <k-kooi@ti.com>
+
+--- /tmp/bc_cat.c      2010-11-23 14:38:14.000000000 +0100
++++ GFX_Linux_KM/services4/3rdparty/bufferclass_ti/bc_cat.c    2010-11-23 14:47:12.000000000 +0100
+@@ -28,6 +28,7 @@
+ #include <linux/kernel.h>
+ #include <linux/module.h>
+ #include <linux/fs.h>
++#include <linux/version.h>
+ #include <asm/uaccess.h>
+ #include <asm/io.h>
+ #include <img_defs.h>
+@@ -121,8 +122,15 @@
+ static struct file_operations bc_cat_fops = {
+     .open =  bc_open,
+     .release = bc_release,
+-    .ioctl = bc_ioctl,
+-    .mmap =  bc_mmap,
++#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,36)
++      .ioctl = bc_ioctl,
++#else
++      .unlocked_ioctl = bc_ioctl,
++#ifdef CONFIG_COMPAT
++    .compat_ioctl = bc_ioctl,
++#endif
++#endif
++      .mmap =  bc_mmap,
+ };
+@@ -492,7 +500,7 @@
+ #ifdef PLAT_TI8168  
+    width_align = 8;
+ #else
+-   width_align = cpu_is_omap3530() && omap_rev_lt_3_0() ? 32 : 8;   
++   width_align = cpu_is_omap3530() && omap_rev() < OMAP3430_REV_ES3_0 ? 32 : 8;   
+ #endif    
+     major = register_chrdev(0, DEVNAME, &bc_cat_fops);
index 481b504..dd56357 100644 (file)
@@ -14,6 +14,7 @@ BINFILE := "Graphics_SDK_setuplinux_${SGXPV}.bin"
 
 SRC_URI = "http://software-dl.ti.com/dsps/dsps_public_sw/sdo_sb/targetcontent/gfxsdk/${SGXPV}/exports/Graphics_SDK_setuplinux_${SGXPV}.bin \
            file://0002-Compile-fixes-for-recent-kernels.patch \
+           file://update.patch \
 "
 
 SRC_URI[md5sum] = "a027002dcd7164df467b1a315788d5fd"
@@ -23,7 +24,7 @@ S = "${WORKDIR}/Graphics_SDK_${SGXPV}/GFX_Linux_KM"
 
 inherit module
 
-MACHINE_KERNEL_PR_append = "f"
+MACHINE_KERNEL_PR_append = "g"
 
 PVRBUILD = "release"