summaryrefslogtreecommitdiff
path: root/meta/packages/linux/linux-openmoko
diff options
context:
space:
mode:
authorMarcin Juszkiewicz <hrw@openedhand.com>2008-07-25 09:27:55 +0000
committerMarcin Juszkiewicz <hrw@openedhand.com>2008-07-25 09:27:55 +0000
commit86cc4b3b9168cd2449384598b71d662da837f551 (patch)
treef638c8b6428eb6680a09c0909b92845f5071b3cb /meta/packages/linux/linux-openmoko
parent6857ef42488c44e5eca4eb2f8331eae93e65c5d6 (diff)
downloadopenembedded-core-86cc4b3b9168cd2449384598b71d662da837f551.tar.gz
openembedded-core-86cc4b3b9168cd2449384598b71d662da837f551.tar.bz2
openembedded-core-86cc4b3b9168cd2449384598b71d662da837f551.zip
linux-openmoko: fix build with gcc 4.3.1
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@4946 311d38ba-8fff-0310-9ca6-ca027cbcb966
Diffstat (limited to 'meta/packages/linux/linux-openmoko')
-rw-r--r--meta/packages/linux/linux-openmoko/timespec_add_ns_avoid_udivdi3.patch20
1 files changed, 20 insertions, 0 deletions
diff --git a/meta/packages/linux/linux-openmoko/timespec_add_ns_avoid_udivdi3.patch b/meta/packages/linux/linux-openmoko/timespec_add_ns_avoid_udivdi3.patch
new file mode 100644
index 0000000000..4aba897b06
--- /dev/null
+++ b/meta/packages/linux/linux-openmoko/timespec_add_ns_avoid_udivdi3.patch
@@ -0,0 +1,20 @@
+Backport of this patch here
+
+http://www.mail-archive.com/linux-kernel@vger.kernel.org/msg270684.html
+
+Needed for 2.6.24 to compile with gcc 4.3
+Index: linux-2.6.24/include/linux/time.h
+===================================================================
+--- linux-2.6.24.orig/include/linux/time.h 2008-05-28 15:39:46.000000000 -0700
++++ linux-2.6.24/include/linux/time.h 2008-05-28 15:40:48.000000000 -0700
+@@ -173,6 +173,10 @@
+ {
+ ns += a->tv_nsec;
+ while(unlikely(ns >= NSEC_PER_SEC)) {
++ /* The following asm() prevents the compiler from
++ * optimising this loop into a modulo operation. */
++ asm("" : "+r"(ns));
++
+ ns -= NSEC_PER_SEC;
+ a->tv_sec++;
+ }