aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Gall <tom.gall@linaro.org>2014-02-21 17:35:46 -0600
committerTom Gall <tom.gall@linaro.org>2014-02-21 17:35:46 -0600
commit3b32f0d7324da0de5963841a8298994f3d94a1bb (patch)
tree6c6027601991a3d49afd5ef251f60f4ad0d6e4e4
parentde32da6aa3a9a54d3657067f7c683035be0e788a (diff)
Change aarch64.patch to fix byte order.armv8-xfce
Add defensive complete utter HACK to avoid using memcpy on aarch64 which because of memcpy's optimization will cause a SIGBUS with clc + framebuffer in the module since it won't tolerate 8 byte writes.
-rw-r--r--meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-tag-debug-shadow.patch31
-rw-r--r--meta/recipes-graphics/xorg-xserver/xserver-xorg/aarch64.patch4
-rw-r--r--meta/recipes-graphics/xorg-xserver/xserver-xorg_1.15.0.bb1
3 files changed, 34 insertions, 2 deletions
diff --git a/meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-tag-debug-shadow.patch b/meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-tag-debug-shadow.patch
new file mode 100644
index 000000000..108c2b1be
--- /dev/null
+++ b/meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-tag-debug-shadow.patch
@@ -0,0 +1,31 @@
+Index: xorg-server-1.14.4/miext/shadow/shpacked.c
+===================================================================
+--- xorg-server-1.14.4.orig/miext/shadow/shpacked.c 2013-07-26 00:19:03.000000000 -0500
++++ xorg-server-1.14.4/miext/shadow/shpacked.c 2014-02-03 18:41:33.442014329 -0600
+@@ -56,6 +56,9 @@
+ int i;
+ FbBits *winBase = NULL, *win;
+ CARD32 winSize;
++ unsigned int z, byByte, *tmpSrcPtr, *tmpDestPtr;
++ char *tmpCSrcPtr, *tmpCDestPtr;
++
+
+ fbGetDrawable(&pShadow->drawable, shaBase, shaStride, shaBpp, shaXoff,
+ shaYoff);
+@@ -99,7 +102,15 @@
+ width -= i;
+ scr += i;
+ #define PickBit(a,i) (((a) >> (i)) & 1)
+- memcpy(win, sha, i * sizeof(FbBits));
++ //fprintf(stdout,"memcpy %08llx win %08llx sha %08llx size %llx i %llx FbBits\n",win, sha, i* sizeof(FbBits),i , sizeof(FbBits));
++ //memcpy(win, sha, i * sizeof(FbBits));
++ tmpSrcPtr=(unsigned int *)sha;
++ tmpDestPtr=(unsigned int *)win; z=(i * sizeof(FbBits))/4;
++ for (; z; z--) {
++ *tmpDestPtr = *tmpSrcPtr;
++ tmpDestPtr++;
++ tmpSrcPtr++;
++ } for(byByte = (i * sizeof(FbBits))%4, tmpCDestPtr=(char *)tmpDestPtr, tmpCSrcPtr=(char*)tmpSrcPtr; byByte; byByte--) { *tmpCDestPtr = *tmpCSrcPtr; tmpCDestPtr++; tmpCSrcPtr++; }
+ sha += i;
+ }
+ shaLine += shaStride;
diff --git a/meta/recipes-graphics/xorg-xserver/xserver-xorg/aarch64.patch b/meta/recipes-graphics/xorg-xserver/xserver-xorg/aarch64.patch
index 045e24a28..99de3bbda 100644
--- a/meta/recipes-graphics/xorg-xserver/xserver-xorg/aarch64.patch
+++ b/meta/recipes-graphics/xorg-xserver/xserver-xorg/aarch64.patch
@@ -22,8 +22,8 @@ Upstream-Status: Pending
#endif /* AMD64 */
+#if defined(__aarch64__) || defined(aarch64) || defined(__aarch64)
-+#define IMAGE_BYTE_ORDER MSBFirst
-+#define BITMAP_BIT_ORDER MSBFirst
++#define IMAGE_BYTE_ORDER LSBFirst
++#define BITMAP_BIT_ORDER LSBFirst
+#define GLYPHPADBYTES 4
+/* ???? */
+#endif /* AArch64 */
diff --git a/meta/recipes-graphics/xorg-xserver/xserver-xorg_1.15.0.bb b/meta/recipes-graphics/xorg-xserver/xserver-xorg_1.15.0.bb
index a4dda4e7a..7c080838a 100644
--- a/meta/recipes-graphics/xorg-xserver/xserver-xorg_1.15.0.bb
+++ b/meta/recipes-graphics/xorg-xserver/xserver-xorg_1.15.0.bb
@@ -5,6 +5,7 @@ SRC_URI += "file://crosscompile.patch \
file://fix_open_max_preprocessor_error.patch \
file://mips64-compiler.patch \
file://aarch64.patch \
+ file://0001-tag-debug-shadow.patch \
"
SRC_URI[md5sum] = "c2ace3697b32414094cf8c597c39d7d9"