diff options
author | Marcin Juszkiewicz <hrw@openedhand.com> | 2008-07-25 09:27:55 +0000 |
---|---|---|
committer | Marcin Juszkiewicz <hrw@openedhand.com> | 2008-07-25 09:27:55 +0000 |
commit | 86cc4b3b9168cd2449384598b71d662da837f551 (patch) | |
tree | f638c8b6428eb6680a09c0909b92845f5071b3cb | |
parent | 6857ef42488c44e5eca4eb2f8331eae93e65c5d6 (diff) | |
download | poky-86cc4b3b9168cd2449384598b71d662da837f551.tar.gz |
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
-rw-r--r-- | meta/packages/linux/linux-openmoko/timespec_add_ns_avoid_udivdi3.patch | 20 | ||||
-rw-r--r-- | meta/packages/linux/linux-openmoko_2.6.24+git.bb | 5 |
2 files changed, 23 insertions, 2 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 @@ | |||
1 | Backport of this patch here | ||
2 | |||
3 | http://www.mail-archive.com/linux-kernel@vger.kernel.org/msg270684.html | ||
4 | |||
5 | Needed for 2.6.24 to compile with gcc 4.3 | ||
6 | Index: linux-2.6.24/include/linux/time.h | ||
7 | =================================================================== | ||
8 | --- linux-2.6.24.orig/include/linux/time.h 2008-05-28 15:39:46.000000000 -0700 | ||
9 | +++ linux-2.6.24/include/linux/time.h 2008-05-28 15:40:48.000000000 -0700 | ||
10 | @@ -173,6 +173,10 @@ | ||
11 | { | ||
12 | ns += a->tv_nsec; | ||
13 | while(unlikely(ns >= NSEC_PER_SEC)) { | ||
14 | + /* The following asm() prevents the compiler from | ||
15 | + * optimising this loop into a modulo operation. */ | ||
16 | + asm("" : "+r"(ns)); | ||
17 | + | ||
18 | ns -= NSEC_PER_SEC; | ||
19 | a->tv_sec++; | ||
20 | } | ||
diff --git a/meta/packages/linux/linux-openmoko_2.6.24+git.bb b/meta/packages/linux/linux-openmoko_2.6.24+git.bb index ee3203daf3..a1d573be17 100644 --- a/meta/packages/linux/linux-openmoko_2.6.24+git.bb +++ b/meta/packages/linux/linux-openmoko_2.6.24+git.bb | |||
@@ -5,9 +5,10 @@ DESCRIPTION = "Linux 2.6.x (development) kernel for FIC SmartPhones shipping w/ | |||
5 | 5 | ||
6 | PE = "1" | 6 | PE = "1" |
7 | PV = "${KERNEL_RELEASE}+git${SRCREV}" | 7 | PV = "${KERNEL_RELEASE}+git${SRCREV}" |
8 | PR = "r1" | 8 | PR = "r2" |
9 | 9 | ||
10 | SRC_URI = "git://git.openmoko.org/git/kernel.git;protocol=git;branch=stable" | 10 | SRC_URI = "git://git.openmoko.org/git/kernel.git;protocol=git;branch=stable \ |
11 | file://timespec_add_ns_avoid_udivdi3.patch;patch=1" | ||
11 | 12 | ||
12 | S = "${WORKDIR}/git" | 13 | S = "${WORKDIR}/git" |
13 | 14 | ||