aboutsummaryrefslogtreecommitdiff
path: root/board
diff options
context:
space:
mode:
authorGravatar Waldemar Brodkorb <wbx@openadk.org>2014-09-19 12:34:04 +0200
committerGravatar Thomas Petazzoni <thomas.petazzoni@free-electrons.com>2014-09-21 19:38:23 +0200
commit0713b7ff652eee839a54268a83ca1b8ea70f3fd5 (patch)
treeabdf4ac13e9a640d9056f03fce6f0021edff50a2 /board
parent40a65d5216f290aefa0925da59a1fa714e18bef4 (diff)
downloadbuildroot-0713b7ff652eee839a54268a83ca1b8ea70f3fd5.tar.gz
buildroot-0713b7ff652eee839a54268a83ca1b8ea70f3fd5.tar.bz2
qemu-sparc: use default gcc
With the kernel patch from: http://patchwork.ozlabs.org/patch/384285/ There is no problem with latest gcc anymore. Signed-off-by: Waldemar Brodkorb <wbx@openadk.org> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Diffstat (limited to 'board')
-rw-r--r--board/qemu/sparc-ss10/linux/linux-0001-sparc-memset-fix.patch50
1 files changed, 50 insertions, 0 deletions
diff --git a/board/qemu/sparc-ss10/linux/linux-0001-sparc-memset-fix.patch b/board/qemu/sparc-ss10/linux/linux-0001-sparc-memset-fix.patch
new file mode 100644
index 0000000000..022c87b3af
--- /dev/null
+++ b/board/qemu/sparc-ss10/linux/linux-0001-sparc-memset-fix.patch
@@ -0,0 +1,50 @@
+This makes memset follow the standard (instead of returning 0 on success). This
+is needed when certain versions of gcc optimizes around memset calls and assume
+that the address argument is preserved in %o0.
+
+Signed-off-by: Andreas Larsson <andreas@gaisler.com>
+
+diff -Nur linux-3.16.2.orig/arch/sparc/lib/memset.S linux-3.16.2/arch/sparc/lib/memset.S
+--- linux-3.16.2.orig/arch/sparc/lib/memset.S 2014-09-06 01:37:11.000000000 +0200
++++ linux-3.16.2/arch/sparc/lib/memset.S 2014-09-18 09:53:49.563047773 +0200
+@@ -65,6 +65,8 @@
+ .globl __memset_start, __memset_end
+ __memset_start:
+ memset:
++ mov %o0, %g1
++ mov 1, %g4
+ and %o1, 0xff, %g3
+ sll %g3, 8, %g2
+ or %g3, %g2, %g3
+@@ -89,6 +91,7 @@
+ sub %o0, %o2, %o0
+
+ __bzero:
++ clr %g4
+ mov %g0, %g3
+ 1:
+ cmp %o1, 7
+@@ -151,8 +154,8 @@
+ bne,a 8f
+ EX(stb %g3, [%o0], and %o1, 1)
+ 8:
+- retl
+- clr %o0
++ b 0f
++ nop
+ 7:
+ be 13b
+ orcc %o1, 0, %g0
+@@ -164,6 +167,12 @@
+ bne 8b
+ EX(stb %g3, [%o0 - 1], add %o1, 1)
+ 0:
++ andcc %g4, 1, %g0
++ be 5f
++ nop
++ retl
++ mov %g1, %o0
++5:
+ retl
+ clr %o0
+ __memset_end: