summaryrefslogtreecommitdiff
path: root/meta/recipes-graphics
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-graphics')
-rw-r--r--meta/recipes-graphics/mesa/qemugl/call_opengl_fix.patch40
-rw-r--r--meta/recipes-graphics/mesa/qemugl_git.bb2
2 files changed, 39 insertions, 3 deletions
diff --git a/meta/recipes-graphics/mesa/qemugl/call_opengl_fix.patch b/meta/recipes-graphics/mesa/qemugl/call_opengl_fix.patch
index c5e3592a7..342f49b71 100644
--- a/meta/recipes-graphics/mesa/qemugl/call_opengl_fix.patch
+++ b/meta/recipes-graphics/mesa/qemugl/call_opengl_fix.patch
@@ -16,8 +16,8 @@ Upstream-Status: Pending
Signed-off-by: Zhai Edwin <edwin.zhai@intel.com>
Index: git/opengl_client.c
===================================================================
---- git.orig/opengl_client.c 2011-09-19 19:44:51.000000000 +0800
-+++ git/opengl_client.c 2011-09-22 10:11:04.000000000 +0800
+--- git.orig/opengl_client.c 2012-02-28 15:26:28.000000000 +0800
++++ git/opengl_client.c 2012-02-28 15:29:18.000000000 +0800
@@ -1076,23 +1076,29 @@
{
#if defined(__i386__)
@@ -56,3 +56,39 @@ Index: git/opengl_client.c
__asm__ ("mov %%eax, %0"::"m"(ret));
#ifdef WIN32
__asm__ ("movl (%%esp),%%ecx;movl %%ecx,%%fs:0;addl $8,%%esp;" : : : "%ecx");
+@@ -1100,20 +1106,27 @@
+ return ret;
+ #elif defined(__x86_64__)
+ int ret;
+- __asm__ ("push %rbx");
+- __asm__ ("push %rcx");
+- __asm__ ("push %rdx");
+- __asm__ ("push %rsi");
++ long bx, cx, dx, si;
++
++ /* save registers before opengl call */
++ __asm__ ("mov %%rbx, %0"::"m"(bx));
++ __asm__ ("mov %%rcx, %0"::"m"(cx));
++ __asm__ ("mov %%rdx, %0"::"m"(dx));
++ __asm__ ("mov %%rsi, %0"::"m"(si));
++
+ __asm__ ("mov %0, %%eax"::"m"(func_number));
+ __asm__ ("mov %0, %%ebx"::"m"(pid));
+ __asm__ ("mov %0, %%rcx"::"m"(ret_string));
+ __asm__ ("mov %0, %%rdx"::"m"(args));
+ __asm__ ("mov %0, %%rsi"::"m"(args_size));
+ __asm__ ("int $0x99");
+- __asm__ ("pop %rsi");
+- __asm__ ("pop %rdx");
+- __asm__ ("pop %rcx");
+- __asm__ ("pop %rbx");
++
++ /* restore registers */
++ __asm__ ("mov %0, %%rbx"::"m"(bx));
++ __asm__ ("mov %0, %%rcx"::"m"(cx));
++ __asm__ ("mov %0, %%rdx"::"m"(dx));
++ __asm__ ("mov %0, %%rsi"::"m"(si));
++
+ __asm__ ("mov %%eax, %0"::"m"(ret));
+ return ret;
+ #else
diff --git a/meta/recipes-graphics/mesa/qemugl_git.bb b/meta/recipes-graphics/mesa/qemugl_git.bb
index e3552eceb..66f4e17be 100644
--- a/meta/recipes-graphics/mesa/qemugl_git.bb
+++ b/meta/recipes-graphics/mesa/qemugl_git.bb
@@ -18,7 +18,7 @@ S = "${WORKDIR}/git"
SRCREV = "d888bbc723c00d197d34a39b5b7448660ec1b1c0"
PV = "0.0+git${SRCPV}"
-PR = "r8"
+PR = "r9"
DEFAULT_PREFERENCE = "-1"