mirror of
https://git.yoctoproject.org/meta-ti
synced 2026-06-06 02:42:34 +00:00
libgles-omap3: merge in updates from arago
* ES3.x do_install fix * AM335x support And one non-arago fix: break dependency on 'initscripts' package Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
This commit is contained in:
@@ -3,9 +3,9 @@ LICENSE = "proprietary-binary"
|
||||
# 'TSPA.txt' might not be the best file to md5sum
|
||||
LIC_FILES_CHKSUM = "file://TSPA.txt;md5=c0d5d9c1e38b41677144c4e24d6ddee1"
|
||||
|
||||
PR = "r18"
|
||||
PR = "r19"
|
||||
|
||||
COMPATIBLE_MACHINE = "(omap3|ti816x)"
|
||||
COMPATIBLE_MACHINE = "(omap3|ti816x|ti33x)"
|
||||
|
||||
DEPENDS = "virtual/libx11 libxau libxdmcp"
|
||||
|
||||
@@ -29,6 +29,7 @@ ES2LOCATION ?= "${S}/gfx_rel_es2.x"
|
||||
ES3LOCATION ?= "${S}/gfx_rel_es3.x"
|
||||
ES5LOCATION ?= "${S}/gfx_rel_es5.x"
|
||||
ES6LOCATION ?= "${S}/gfx_rel_es6.x"
|
||||
ES8LOCATION ?= "${S}/gfx_rel_es8.x"
|
||||
|
||||
do_configure() {
|
||||
# Attempt to fix up the worst offenders for file permissions
|
||||
@@ -158,22 +159,28 @@ do_install () {
|
||||
|
||||
# The ES2.x, ES3.x, ES5.x and ES6.x CPUs have different SGX hardware, so we need to install multiple sets of userspace
|
||||
|
||||
install -d ${D}${libdir}/ES8.0
|
||||
install -d ${D}${libdir}/ES6.0
|
||||
install -d ${D}${libdir}/ES5.0
|
||||
install -d ${D}${libdir}/ES3.0
|
||||
install -d ${D}${libdir}/ES2.0
|
||||
|
||||
install -d ${D}${bindir}/ES8.0
|
||||
install -d ${D}${bindir}/ES6.0
|
||||
install -d ${D}${bindir}/ES5.0
|
||||
install -d ${D}${bindir}/ES3.0
|
||||
install -d ${D}${bindir}/ES2.0
|
||||
|
||||
|
||||
cp -pPR ${ES2LOCATION}/lib*${IMGPV} ${D}${libdir}/ES2.0/
|
||||
cp ${ES2LOCATION}/p[dv]* ${D}${bindir}/ES2.0/
|
||||
if [ -e ${ES2LOCATION} ] ; then
|
||||
cp -pPR ${ES2LOCATION}/lib*${IMGPV} ${D}${libdir}/ES2.0/
|
||||
cp ${ES2LOCATION}/p[dv]* ${D}${bindir}/ES2.0/
|
||||
fi
|
||||
|
||||
cp -pPR ${D}${libdir}/lib*${IMGPV} ${D}${libdir}/ES3.0/
|
||||
cp ${D}${bindir}/p[dv]* ${D}${bindir}/ES3.0
|
||||
if [ -e ${ES3LOCATION} ] ; then
|
||||
cp -pPR ${ES3LOCATION}/lib*${IMGPV} ${D}${libdir}/ES3.0/
|
||||
cp ${ES3LOCATION}/p[dv]* ${D}${bindir}/ES3.0
|
||||
fi
|
||||
|
||||
if [ -e ${ES5LOCATION} ] ; then
|
||||
cp -pPR ${ES5LOCATION}/lib*${IMGPV} ${D}${libdir}/ES5.0/
|
||||
@@ -185,6 +192,11 @@ do_install () {
|
||||
cp ${ES6LOCATION}/p[dv]* ${D}${bindir}/ES6.0/
|
||||
fi
|
||||
|
||||
if [ -e ${ES8LOCATION} ] ; then
|
||||
cp -pPR ${ES8LOCATION}/lib*${IMGPV} ${D}${libdir}/ES8.0/
|
||||
cp ${ES8LOCATION}/p[dv]* ${D}${bindir}/ES8.0/
|
||||
fi
|
||||
|
||||
rm ${D}${bindir}/ES*/*.h ${D}${bindir}/ES*/pdsasm ${D}${bindir}/pdsasm -f || true
|
||||
|
||||
install -d ${D}${prefix}/share/applications
|
||||
@@ -272,8 +284,6 @@ FILES_${PN}-x11wsegl-es8 = "${libdir}/ES8*/libpvrPVR2D_X11WSEGL.so.*"
|
||||
RRECOMMENDS_${PN}-x11wsegl = " ${PN}-x11wsegl-es2 ${PN}-x11wsegl-es3 ${PN}-x11wsegl-es5 ${PN}-x11wsegl-es6 ${PN}-x11wsegl-es8"
|
||||
|
||||
CONFFILES_${PN} = "${sysconfdir}/powervr.ini"
|
||||
# 'cputype' uses /etc/init.d/functions
|
||||
RRECOMMENDS_${PN} += "initscripts"
|
||||
|
||||
FILES_${PN} = "${sysconfdir} ${libdir}/lib*.so.* ${libdir}/ES*/* ${bindir}/pvrsrvinit ${bindir}/cputype ${bindir}/*/*"
|
||||
|
||||
|
||||
@@ -1,11 +1,17 @@
|
||||
#!/bin/sh
|
||||
. /etc/init.d/functions
|
||||
|
||||
machine_id() { # return the machine ID
|
||||
awk 'BEGIN { FS=": " } /Hardware/ \
|
||||
{ gsub(" ", "_", $2); print tolower($2) } ' </proc/cpuinfo
|
||||
}
|
||||
|
||||
if [ "$(machine_id)" = "ti8168evm" ] ; then
|
||||
echo TI816x
|
||||
elif [ "$(machine_id)" = "am335xevm" ] ; then
|
||||
echo TI33XX
|
||||
else
|
||||
devmem2 0x4800244c | \
|
||||
grep 'Read at address' | \
|
||||
sed -e 's/.*): //' | \
|
||||
sed -e 's/0x00005C00/OMAP3503/' -e 's/0x00001C00/OMAP3515/' -e 's/0x00004C00/OMAP3525/' -e 's/0x00000C00/OMAP3530/'
|
||||
sed -e 's/0x00005C00/OMAP3503/' -e 's/0x00001C00/OMAP3515/' -e 's/0x00004C00/OMAP3525/' -e 's/0x00000C00/OMAP3530/' -e 's/0x00005E00/OMAP3503/' -e 's/0x00001E00/OMAP3515/' -e 's/0x00004E00/OMAP3525/' -e 's/0x00000E00/OMAP3530/' -e 's/0x00000CC0/OMAP3530/'
|
||||
fi
|
||||
|
||||
@@ -1,6 +1,15 @@
|
||||
#!/bin/sh
|
||||
PATH=$PATH:/usr/sbin
|
||||
|
||||
# Check if an fb device is available. If not then just go ahead and
|
||||
# exit because we have no display.
|
||||
fbset > /dev/null 2>&1
|
||||
if [ "$?" == "1" ]
|
||||
then
|
||||
# looks like there is no display, so let's exit
|
||||
exit 0
|
||||
fi
|
||||
|
||||
BITSPERPIXEL="$(fbset | grep geom | awk '{print $6}')"
|
||||
YRES="$(fbset | grep geom | awk '{print $3}')"
|
||||
|
||||
@@ -28,7 +37,7 @@ if [ "$BITSPERPIXEL" = "32" ] ; then
|
||||
fi
|
||||
|
||||
# Try to enable triple buffering when there's enough VRAM
|
||||
fbset -vyres $(expr $YRES \* 3)
|
||||
fbset -vyres $(expr $YRES \* 3)
|
||||
|
||||
sgxprepare () {
|
||||
echo Starting PVR
|
||||
@@ -39,11 +48,11 @@ sgxprepare () {
|
||||
pvr_maj=`grep "pvrsrvkm$" /proc/devices | cut -b1,2,3`
|
||||
bc_maj=`grep "bc" /proc/devices | cut -b1,2,3`
|
||||
|
||||
if [ -e /dev/pvrsrvkm ] ; then
|
||||
if [ -e /dev/pvrsrvkm ] ; then
|
||||
rm -f /dev/pvrsrvkm
|
||||
fi
|
||||
|
||||
mknod /dev/pvrsrvkm c $pvr_maj 0
|
||||
mknod /dev/pvrsrvkm c $pvr_maj 0
|
||||
chmod 666 /dev/pvrsrvkm
|
||||
|
||||
touch /etc/powervr-esrev
|
||||
@@ -56,7 +65,7 @@ sgxfinish () {
|
||||
echo -n "Starting SGX fixup for"
|
||||
echo " ES${ES_REVISION}.x"
|
||||
cp -a /usr/lib/ES${ES_REVISION}.0/* /usr/lib
|
||||
cp -a /usr/bin/ES${ES_REVISION}.0/* /usr/bin
|
||||
cp -a /usr/bin/ES${ES_REVISION}.0/* /usr/bin
|
||||
echo "${ES_REVISION}" > /etc/powervr-esrev
|
||||
fi
|
||||
/usr/bin/pvrsrvinit
|
||||
@@ -72,6 +81,16 @@ case $CPUTYPE in
|
||||
|
||||
ES_REVISION="$(devmem2 0x50000014 | sed -e s:0x00010205:5: -e s:0x00010201:3: -e s:0x00010003:2: | tail -n1 | awk -F': ' '{print $2}')"
|
||||
|
||||
sgxfinish
|
||||
;;
|
||||
"TI33XX")
|
||||
sgxprepare
|
||||
|
||||
devmem2 0x44e01104 w 0x0 > /dev/null
|
||||
devmem2 0x44e00904 w 0x2 > /dev/null
|
||||
|
||||
ES_REVISION="$(devmem2 0x56000014 | sed -e s:0x00010205:8: | tail -n1 | awk -F': ' '{print $2}')"
|
||||
|
||||
sgxfinish
|
||||
;;
|
||||
"TI816x")
|
||||
@@ -89,5 +108,3 @@ case $CPUTYPE in
|
||||
echo No SGX hardware, not starting PVR
|
||||
;;
|
||||
esac
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user