aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/powervr-drivers
diff options
context:
space:
mode:
authorKoen Kooi <koen@openembedded.org>2009-11-16 11:45:21 +0100
committerKoen Kooi <koen@openembedded.org>2009-11-18 10:13:52 +0100
commit19a9dfbb29d677c5cfd8b1d5af9d16409fa4bde8 (patch)
treed0052816cbfd2e72888d70f22337805bac729f68 /recipes/powervr-drivers
parente4e52ba358c094952ec868d32524a26dfa4bae89 (diff)
downloadopenembedded-19a9dfbb29d677c5cfd8b1d5af9d16409fa4bde8.tar.gz
libgles-omap, omap3-sgx-modules: add SDK 3.01.00.02/1.4.14.2514 release
Diffstat (limited to 'recipes/powervr-drivers')
-rwxr-xr-xrecipes/powervr-drivers/libgles-omap3-3.01.00.02/rc.pvr58
-rw-r--r--recipes/powervr-drivers/libgles-omap3.inc5
-rw-r--r--recipes/powervr-drivers/libgles-omap3_3.01.00.02.bb30
-rw-r--r--recipes/powervr-drivers/omap3-sgx-modules_1.4.14.2514.bb33
4 files changed, 122 insertions, 4 deletions
diff --git a/recipes/powervr-drivers/libgles-omap3-3.01.00.02/rc.pvr b/recipes/powervr-drivers/libgles-omap3-3.01.00.02/rc.pvr
new file mode 100755
index 0000000000..1b3c274593
--- /dev/null
+++ b/recipes/powervr-drivers/libgles-omap3-3.01.00.02/rc.pvr
@@ -0,0 +1,58 @@
+#!/bin/sh
+
+CPUTYPE="$(cputype)"
+
+if [ "$1" = "" ]; then
+ echo PVR-INIT: Please use start, stop, or restart.
+ exit 1
+fi
+
+if [ "$1" = "stop" -o "$1" = "restart" ]; then
+ echo Stopping PVR
+ #rmmod bc_example
+ rmmod omaplfb 2>/dev/null
+ rmmod pvrsrvkm 2>/dev/null
+fi
+
+if [ "$1" = "stop" ]; then
+ exit 0
+fi
+
+if [ $CPUTYPE = "OMAP3530" ]; then
+ echo Starting PVR
+ insmod $(busybox find /lib/modules/$(uname -r) -name "pvrsrvkm.ko")
+ #modprobe bc_example
+ modprobe omaplfb
+
+ pvr_maj=`grep "pvrsrvkm$" /proc/devices | cut -b1,2,3`
+
+ if [ -e /dev/pvrsrvkm ] ; then
+ rm -f /dev/pvrsrvkm
+ fi
+
+ mknod /dev/pvrsrvkm c $pvr_maj 0
+ chmod 666 /dev/pvrsrvkm
+
+ touch /etc/powervr-esrev
+
+ SAVED_ESREVISION="$(cat /etc/powervr-esrev)"
+ ES_REVISION="$(cat /proc/cpuinfo | grep "CPU revision" | awk -F: '{print $2}')"
+
+ if [ "${ES_REVISION}" != "${SAVED_ESREVISION}" ] ; then
+ echo -n "Starting SGX fixup for"
+ if [ "${ES_REVISION}" = " 3" ] ; then
+ echo " ES3.x"
+ cp -a /usr/lib/ES3.0/* /usr/lib
+ cp -a /usr/bin/ES3.0/* /usr/bin
+ else
+ echo "ES 2.x"
+ cp -a /usr/lib/ES2.0/* /usr/lib
+ cp -a /usr/bin/ES2.0/* /usr/bin
+ fi
+ echo "${ES_REVISION}" > /etc/powervr-esrev
+ fi
+ /usr/bin/pvrsrvinit
+else
+ echo No SGX hardware, not starting PVR
+fi
+
diff --git a/recipes/powervr-drivers/libgles-omap3.inc b/recipes/powervr-drivers/libgles-omap3.inc
index 79dcf59dd0..208da9e052 100644
--- a/recipes/powervr-drivers/libgles-omap3.inc
+++ b/recipes/powervr-drivers/libgles-omap3.inc
@@ -89,10 +89,7 @@ do_install () {
install -m 0755 ${WORKDIR}/cputype ${D}${bindir}/
cp -pP ${BINLOCATION}/*_test ${D}${bindir}/
- cp -pP ${BINLOCATION}/gl2info ${D}${bindir}/
- cp -pP ${BINLOCATION}/gles1test1 ${D}${bindir}/
- cp -pP ${BINLOCATION}/gles1_texture_stream ${D}${bindir}/
- cp -pP ${BINLOCATION}/gles2test1 ${D}${bindir}/
+ cp -pP ${BINLOCATION}/gl* ${D}${bindir}/
cp -pP ${BINLOCATION}/p[dv]* ${D}${bindir}/
cp -pP ${BINLOCATION}/xgles1test1 ${D}${bindir}/
diff --git a/recipes/powervr-drivers/libgles-omap3_3.01.00.02.bb b/recipes/powervr-drivers/libgles-omap3_3.01.00.02.bb
new file mode 100644
index 0000000000..7d5af472cf
--- /dev/null
+++ b/recipes/powervr-drivers/libgles-omap3_3.01.00.02.bb
@@ -0,0 +1,30 @@
+BINLOCATION = "${S}/gfx_rel_es3.x"
+
+require libgles-omap3.inc
+
+DEFAULT_PREFERENCE = "-1"
+# download required binary distribution from:
+# http://software-dl.ti.com/dsps/forms/export.html?prod_no=/OMAP35x_Graphics_SDK_setuplinux_3_01_00_02.bin
+
+SGXPV = "3_01_00_02"
+IMGPV = "1.4.14.2514"
+BINFILE := "OMAP35x_Graphics_SDK_setuplinux_${SGXPV}.bin"
+
+# The ES2.x and ES3.x CPUs have different SGX hardware, so we need to install 2 sets of userspace
+do_install_append() {
+ install -d ${D}${libdir}/ES3.0
+ install -d ${D}${libdir}/ES2.0
+ install -d ${D}${bindir}/ES3.0
+ install -d ${D}${bindir}/ES2.0
+
+ cp ${S}/gfx_rel_es2.x/lib* ${D}${libdir}/ES2.0/
+ cp ${S}/gfx_rel_es2.x//p[dv]* ${D}${bindir}/ES2.0/
+
+ cp ${D}${libdir}/lib*${IMGPV} ${D}${libdir}/ES3.0/
+ cp ${D}${bindir}/p[dv]* ${D}${bindir}/ES3.0
+}
+
+# Quality control is really poor on these SDKs, so hack around the latest madness:
+FILES_${PN} += "${libdir}/*.so "
+FILES_${PN}-dev = "${includedir}"
+
diff --git a/recipes/powervr-drivers/omap3-sgx-modules_1.4.14.2514.bb b/recipes/powervr-drivers/omap3-sgx-modules_1.4.14.2514.bb
new file mode 100644
index 0000000000..9da9a478f8
--- /dev/null
+++ b/recipes/powervr-drivers/omap3-sgx-modules_1.4.14.2514.bb
@@ -0,0 +1,33 @@
+DESCRIPTION = "Kernel drivers for the PowerVR SGX chipset found in the omap3 SoCs"
+LICENSE = "GPLv2"
+
+DEFAULT_PREFERENCE = "-1"
+
+require ../ti/ti-dspbios.inc
+
+# download required binary distribution from:
+# http://software-dl.ti.com/dsps/forms/export.html?prod_no=/OMAP35x_Graphics_SDK_setuplinux_3_01_00_02.bin
+
+SGXPV = "3_01_00_02"
+IMGPV = "1.4.14.2514"
+BINFILE := "OMAP35x_Graphics_SDK_setuplinux_${SGXPV}.bin"
+
+SRC_URI = "file://OMAP35x_Graphics_SDK_setuplinux_${SGXPV}.bin"
+
+S = "${WORKDIR}/OMAP35x_Graphics_SDK_${SGXPV}/GFX_Linux_KM"
+
+inherit module
+
+PVRBUILD = "release"
+
+INHIBIT_PACKAGE_STRIP = "1"
+
+MAKE_TARGETS = " BUILD=${PVRBUILD}"
+
+do_install() {
+ mkdir -p ${D}/lib/modules/${KERNEL_VERSION}/kernel/drivers/gpu/pvr
+ cp ${S}/pvrsrvkm.ko \
+ ${S}/services4/3rdparty/dc_omap3430_linux/omaplfb.ko \
+ ${S}/services4/3rdparty/bufferclass_ti/bufferclass_ti.ko \
+ ${D}/lib/modules/${KERNEL_VERSION}/kernel/drivers/gpu/pvr
+}